mirror of
https://github.com/dani-garcia/vaultwarden.git
synced 2025-09-11 03:05:58 +03:00
Remove references to "bwrs"
The only remaining one is getting the version of the web vault, which requires coordinating with the web vault patching.
This commit is contained in:
10
src/main.rs
10
src/main.rs
@@ -76,16 +76,18 @@ const HELP: &str = "\
|
||||
-v, --version Prints the app version
|
||||
";
|
||||
|
||||
pub const VERSION: Option<&str> = option_env!("VW_VERSION");
|
||||
|
||||
fn parse_args() {
|
||||
const NO_VERSION: &str = "(Version info from Git not present)";
|
||||
let mut pargs = pico_args::Arguments::from_env();
|
||||
let version = VERSION.unwrap_or("(Version info from Git not present)");
|
||||
|
||||
if pargs.contains(["-h", "--help"]) {
|
||||
println!("vaultwarden {}", option_env!("BWRS_VERSION").unwrap_or(NO_VERSION));
|
||||
println!("vaultwarden {}", version);
|
||||
print!("{}", HELP);
|
||||
exit(0);
|
||||
} else if pargs.contains(["-v", "--version"]) {
|
||||
println!("vaultwarden {}", option_env!("BWRS_VERSION").unwrap_or(NO_VERSION));
|
||||
println!("vaultwarden {}", version);
|
||||
exit(0);
|
||||
}
|
||||
}
|
||||
@@ -94,7 +96,7 @@ fn launch_info() {
|
||||
println!("/--------------------------------------------------------------------\\");
|
||||
println!("| Starting Vaultwarden |");
|
||||
|
||||
if let Some(version) = option_env!("BWRS_VERSION") {
|
||||
if let Some(version) = VERSION {
|
||||
println!("|{:^68}|", format!("Version {}", version));
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user