Upgrade oh-my-zsh (fix #215)
This commit is contained in:
@@ -65,7 +65,6 @@ Just run `topgrade`. It will run the following steps:
|
|||||||
* Check if the following paths are tracked by Git. If so, pull them:
|
* Check if the following paths are tracked by Git. If so, pull them:
|
||||||
* ~/.emacs.d (Should work whether you use [Spacemacs](http://spacemacs.org/) or a custom configuration)
|
* ~/.emacs.d (Should work whether you use [Spacemacs](http://spacemacs.org/) or a custom configuration)
|
||||||
* ~/.zshrc
|
* ~/.zshrc
|
||||||
* [~/.oh-my-zsh](https://github.com/robbyrussell/oh-my-zsh)
|
|
||||||
* ~/.tmux
|
* ~/.tmux
|
||||||
* ~/.config/fish
|
* ~/.config/fish
|
||||||
* ~/.config/nvim
|
* ~/.config/nvim
|
||||||
@@ -76,6 +75,7 @@ Just run `topgrade`. It will run the following steps:
|
|||||||
* Powershell Profile
|
* Powershell Profile
|
||||||
* Custom defined paths
|
* Custom defined paths
|
||||||
* **Unix**: Run [zplug](https://github.com/zplug/zplug) update
|
* **Unix**: Run [zplug](https://github.com/zplug/zplug) update
|
||||||
|
* **Unix**: Run [oh-my-zsh](https://github.com/robbyrussell/oh-my-zsh) update
|
||||||
* **Unix**: Run [fisher](https://github.com/jorgebucaran/fisher)
|
* **Unix**: Run [fisher](https://github.com/jorgebucaran/fisher)
|
||||||
* **Unix**: Upgrade tmux plugins with [TPM](https://github.com/tmux-plugins/tpm). *Note*: Do not use
|
* **Unix**: Upgrade tmux plugins with [TPM](https://github.com/tmux-plugins/tpm). *Note*: Do not use
|
||||||
the `-b` flag in your configuration as suggested by the TPM readme.
|
the `-b` flag in your configuration as suggested by the TPM readme.
|
||||||
|
|||||||
@@ -224,7 +224,6 @@ fn run() -> Result<(), Error> {
|
|||||||
#[cfg(unix)]
|
#[cfg(unix)]
|
||||||
{
|
{
|
||||||
git_repos.insert(base_dirs.home_dir().join(".zshrc"));
|
git_repos.insert(base_dirs.home_dir().join(".zshrc"));
|
||||||
git_repos.insert(base_dirs.home_dir().join(".oh-my-zsh"));
|
|
||||||
git_repos.insert(base_dirs.home_dir().join(".tmux"));
|
git_repos.insert(base_dirs.home_dir().join(".tmux"));
|
||||||
git_repos.insert(base_dirs.home_dir().join(".config/fish"));
|
git_repos.insert(base_dirs.home_dir().join(".config/fish"));
|
||||||
git_repos.insert(base_dirs.config_dir().join("openbox"));
|
git_repos.insert(base_dirs.config_dir().join("openbox"));
|
||||||
@@ -267,6 +266,12 @@ fn run() -> Result<(), Error> {
|
|||||||
|| unix::run_zplug(&base_dirs, run_type),
|
|| unix::run_zplug(&base_dirs, run_type),
|
||||||
config.no_retry(),
|
config.no_retry(),
|
||||||
)?;
|
)?;
|
||||||
|
execute(
|
||||||
|
&mut report,
|
||||||
|
"oh-my-zsh",
|
||||||
|
|| unix::run_oh_my_zsh(run_type),
|
||||||
|
config.no_retry(),
|
||||||
|
)?;
|
||||||
execute(
|
execute(
|
||||||
&mut report,
|
&mut report,
|
||||||
"fisher",
|
"fisher",
|
||||||
|
|||||||
@@ -26,6 +26,14 @@ pub fn run_zplug(base_dirs: &BaseDirs, run_type: RunType) -> Result<(), Error> {
|
|||||||
run_type.execute(zsh).args(&["-c", cmd.as_str()]).check_run()
|
run_type.execute(zsh).args(&["-c", cmd.as_str()]).check_run()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn run_oh_my_zsh(run_type: RunType) -> Result<(), Error> {
|
||||||
|
let upgrade = require("upgrade_oh_my_zsh")?;
|
||||||
|
|
||||||
|
print_separator("oh-my-zsh");
|
||||||
|
|
||||||
|
run_type.execute(upgrade).check_run()
|
||||||
|
}
|
||||||
|
|
||||||
pub fn run_fisher(base_dirs: &BaseDirs, run_type: RunType) -> Result<(), Error> {
|
pub fn run_fisher(base_dirs: &BaseDirs, run_type: RunType) -> Result<(), Error> {
|
||||||
let fish = require("fish")?;
|
let fish = require("fish")?;
|
||||||
base_dirs
|
base_dirs
|
||||||
|
|||||||
Reference in New Issue
Block a user