Use short SHA in start message
This commit is contained in:
parent
75752eb13e
commit
97ea5eb448
2 changed files with 6 additions and 4 deletions
6
build.rs
6
build.rs
|
@ -1,8 +1,10 @@
|
||||||
use std::error::Error;
|
use std::error::Error;
|
||||||
|
|
||||||
use vergen::{vergen, Config};
|
use vergen::{vergen, Config, ShaKind};
|
||||||
|
|
||||||
fn main() -> Result<(), Box<dyn Error>> {
|
fn main() -> Result<(), Box<dyn Error>> {
|
||||||
vergen(Config::default())?;
|
let mut config = Config::default();
|
||||||
|
*config.git_mut().sha_kind_mut() = ShaKind::Short;
|
||||||
|
vergen(config)?;
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
|
@ -244,8 +244,8 @@ fn print_preamble_and_warnings(args: &CliArgs) -> Result<(), Box<dyn Error>> {
|
||||||
" ",
|
" ",
|
||||||
env!("CARGO_PKG_VERSION"),
|
env!("CARGO_PKG_VERSION"),
|
||||||
" (",
|
" (",
|
||||||
env!("VERGEN_GIT_SHA"),
|
env!("VERGEN_GIT_SHA_SHORT"),
|
||||||
") ",
|
")",
|
||||||
" Copyright (C) 2021 ",
|
" Copyright (C) 2021 ",
|
||||||
env!("CARGO_PKG_AUTHORS"),
|
env!("CARGO_PKG_AUTHORS"),
|
||||||
"\n\n",
|
"\n\n",
|
||||||
|
|
Loading…
Reference in a new issue