mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-25 14:07:58 +00:00
08d6640a6c
* version info with built-time obtained git hash * clippy * rerun-if-changed properly and handle git command failing * cargo fmt
17 lines
334 B
Rust
17 lines
334 B
Rust
use clap::Parser as ClapParser;
|
|
|
|
/// Prints version information
|
|
#[derive(Debug, ClapParser)]
|
|
pub struct Opts {}
|
|
|
|
pub fn run(_opts: Opts) -> color_eyre::Result<()> {
|
|
let git_hash = env!("GIT_HASH");
|
|
println!(
|
|
"{} {}-{}",
|
|
clap::crate_name!(),
|
|
clap::crate_version!(),
|
|
git_hash
|
|
);
|
|
Ok(())
|
|
}
|