mise use --env env ...
will create a new mise.env.toml
file even if .mise.env.toml
already exists
#4210
Unanswered
sgtsquiggs
asked this question in
Troubleshooting and bug reports
Replies: 3 comments 1 reply
-
This seems like a simple test case to be written and validated on |
Beta Was this translation helpful? Give feedback.
0 replies
-
bisecting pointed me towards 8f31a33#diff-e72bf1e82a503ec391103eaae7f25e7329430d3f558c1e73f2bebfd3d2097e00L188-R189 this might be a sufficient fix diff --git a/src/cli/use.rs b/src/cli/use.rs
index 6cce6a30..bf0530c6 100644
--- a/src/cli/use.rs
+++ b/src/cli/use.rs
@@ -185,9 +185,7 @@ impl Use {
fn get_config_file(&self) -> Result<Box<dyn ConfigFile>> {
let cwd = env::current_dir()?;
- let path = if let Some(env) = &*env::MISE_ENV {
- config_file_from_dir(&cwd.join(format!("mise.{env}.toml")))
- } else if self.global || env::in_home_dir() {
+ let path = if self.global || env::in_home_dir() {
MISE_GLOBAL_CONFIG_FILE.clone()
} else if let Some(env) = &self.env {
let p = cwd.join(format!(".mise.{env}.toml")); |
Beta Was this translation helpful? Give feedback.
1 reply
-
Should be fixed with 2025.1.16 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Reproduce:
doctor:
Beta Was this translation helpful? Give feedback.
All reactions