Skip to content

Commit a35f557

Browse files
chore(deps): bump regex from 1.11.1 to 1.12.2 (#8)
Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Mark Jaquith <mark@jaquith.me>
1 parent abb1db1 commit a35f557

File tree

3 files changed

+8
-11
lines changed

3 files changed

+8
-11
lines changed

Cargo.lock

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ path = "src/main.rs"
2727
[dependencies]
2828
anyhow = "1.0.98"
2929
clap = { version = "4.5.36", features = ["derive"] }
30-
regex = "1.11.1"
30+
regex = "1.12.2"
3131
serde = { version = "1.0.219", features = ["derive"] }
3232
shell-escape = "0.1.5"
3333
tempfile = "3.19.1"

src/config.rs

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,8 @@ pub fn load_app_config() -> Result<AppConfig> {
4646
.map_or_else(|_| PathBuf::from("."), PathBuf::from)
4747
.join(".config");
4848
#[cfg(not(target_os = "macos"))]
49-
let base = std::env::var("XDG_CONFIG_HOME")
50-
.map(PathBuf::from)
51-
.unwrap_or_else(|_| PathBuf::from("."));
49+
let base =
50+
std::env::var("XDG_CONFIG_HOME").map_or_else(|_| PathBuf::from("."), PathBuf::from);
5251
base.join("cmdy").join("cmdy.toml")
5352
};
5453
if config_path.is_file() {
@@ -81,9 +80,7 @@ pub fn determine_config_directory(cli_dir_flag: &Option<PathBuf>) -> Result<Path
8180
.map_or_else(|_| PathBuf::from("."), PathBuf::from)
8281
.join(".config");
8382
#[cfg(not(target_os = "macos"))]
84-
let base = std::env::var("XDG_CONFIG_HOME")
85-
.map(PathBuf::from)
86-
.unwrap_or_else(|_| PathBuf::from("."));
83+
let base = std::env::var("XDG_CONFIG_HOME").map_or_else(|_| PathBuf::from("."), PathBuf::from);
8784
let path = base.join("cmdy").join("commands");
8885
Ok(path)
8986
}

0 commit comments

Comments
 (0)