--version talks about API version too

This commit is contained in:
Nadja Reitzenstein 2022-05-14 15:36:32 +02:00
parent d591daa884
commit c435f76d08
3 changed files with 7 additions and 3 deletions

View File

@ -51,7 +51,7 @@ impl bootstrap::Server for BootCap {
let _guard = span.enter();
let mut builder = result.get();
builder.set_name("bffhd");
builder.set_release(crate::RELEASE_STRING);
builder.set_release(crate::env::VERSION);
Promise::ok(())
}

View File

@ -76,7 +76,7 @@ pub static RESOURCES: OnceCell<ResourcesHandle> = OnceCell::new();
impl Diflouroborane {
pub fn new(config: Config) -> anyhow::Result<Self> {
logging::init(&config.logging);
tracing::info!(version = VERSION_STRING, "Starting BFFH");
tracing::info!(version = env::VERSION, "Starting BFFH");
let span = tracing::info_span!("setup");
let _guard = span.enter();

View File

@ -11,7 +11,11 @@ fn main() -> anyhow::Result<()> {
// values for the name, description and version are pulled from `Cargo.toml`.
let matches = Command::new(clap::crate_name!())
.version(clap::crate_version!())
.long_version(diflouroborane::VERSION_STRING)
.long_version(&*format!("Diflouroborane {version}
\t Implementing API {apiver}",
version=diflouroborane::env::VERSION,
apiver="0.3")
)
.about(clap::crate_description!())
.arg(
Arg::new("config")