introduce rust
This commit is contained in:
12
src/cmd/version.rs
Normal file
12
src/cmd/version.rs
Normal file
@ -0,0 +1,12 @@
|
||||
pub fn run() {
|
||||
println!("{}", version_string());
|
||||
}
|
||||
|
||||
pub fn version_string() -> String {
|
||||
format!(
|
||||
"Direktil {} v{} (git commit {})",
|
||||
env!("CARGO_PKG_NAME"),
|
||||
env!("CARGO_PKG_VERSION"),
|
||||
env!("GIT_COMMIT")
|
||||
)
|
||||
}
|
Reference in New Issue
Block a user