committed by
GitHub
parent
616c313f82
commit
30e1318dd7
@@ -74,15 +74,15 @@ pub fn run_zinit(base_dirs: &BaseDirs, run_type: RunType) -> Result<()> {
|
|||||||
.unwrap_or_else(|_| base_dirs.home_dir().join(".zinit"))
|
.unwrap_or_else(|_| base_dirs.home_dir().join(".zinit"))
|
||||||
.exists();
|
.exists();
|
||||||
|
|
||||||
let zplug_exists = env::var("ZPLUG_HOME")
|
let zplugin_exists = env::var("ZPLUG_HOME")
|
||||||
.map(PathBuf::from)
|
.map(PathBuf::from)
|
||||||
.unwrap_or_else(|_| base_dirs.home_dir().join("zplug"))
|
.unwrap_or_else(|_| base_dirs.home_dir().join(".zplugin"))
|
||||||
.exists();
|
.exists();
|
||||||
|
|
||||||
// Check whether this is a pre- or post- renaming installation
|
// Check whether this is a pre- or post- renaming installation
|
||||||
let zcommand = if zinit_exists {
|
let zcommand = if zinit_exists {
|
||||||
"zinit"
|
"zinit"
|
||||||
} else if zplug_exists {
|
} else if zplugin_exists {
|
||||||
"zplugin"
|
"zplugin"
|
||||||
} else {
|
} else {
|
||||||
return Err(SkipStep.into());
|
return Err(SkipStep.into());
|
||||||
|
|||||||
Reference in New Issue
Block a user