is it "an str" (ess-tee-arh) or "a str" (stir)?
This commit is contained in:
parent
043e0972c5
commit
afa2bb8784
1 changed files with 3 additions and 3 deletions
|
@ -24,11 +24,11 @@ static CLAP_VERSION: OnceCell<String> = OnceCell::new();
|
|||
static CLAP_LONG_VERSION: OnceCell<String> = OnceCell::new();
|
||||
|
||||
/// Sets [`CLAP_VERSION`] to be the version defined in Cargo.toml, prefixed with a v (e.g. "v0.3.1"), then returns it as
|
||||
/// a String.
|
||||
/// an str.
|
||||
pub fn clap_version() -> &'static str { CLAP_VERSION.get_or_init(|| String::from("v") + VERSION.unwrap_or("???")) }
|
||||
|
||||
/// Sets [`CLAP_LONG_VERSION`] to be similar to [`CLAP_VERSION`], followed by the chosen backend in parentheses (e.g.
|
||||
/// "v0.3.1 (XDG-Mime backend)"), then returns it as a String.
|
||||
/// Sets [`CLAP_LONG_VERSION`] to be similar to [`CLAP_VERSION`], followed by the chosen backend and abbreviated git
|
||||
/// commit hash in parentheses (e.g. "v0.3.6 (XDG-Mime backend, commit #043e097)"), then returns it as an str.
|
||||
pub fn clap_long_version() -> &'static str {
|
||||
CLAP_LONG_VERSION.get_or_init(|| {
|
||||
format!(
|
||||
|
|
Loading…
Reference in a new issue