X-Git-Url: https://git.r.bdr.sh/rbdr/blog/blobdiff_plain/d620665f6b2e1ae5db4c98a09e35bd63133ae87f..b17907faf8d9693cef94a6048d802bd4ced9102f:/src/command/version.rs?ds=sidebyside diff --git a/src/command/version.rs b/src/command/version.rs index fae7596..94eb92e 100644 --- a/src/command/version.rs +++ b/src/command/version.rs @@ -1,3 +1,4 @@ +use crate::configuration::Configuration; use std::io::Result; pub struct Version; @@ -13,9 +14,10 @@ impl super::Command for Version { vec![] } - fn execute(&self, input: Option<&String>) -> Result<()> { - println!("Version: {:?}!", input); - return Ok(()) + fn execute(&self, _: Option<&String>, _: &Configuration, _: &str) -> Result<()> { + let version = env!("CARGO_PKG_VERSION"); + println!("{version}"); + Ok(()) } fn after_dependencies(&self) -> Vec> {