summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
Diffstat (limited to 'tools')
-rw-r--r--tools/check_for_upgrade.sh2
-rwxr-xr-xtools/upgrade.sh10
2 files changed, 7 insertions, 5 deletions
diff --git a/tools/check_for_upgrade.sh b/tools/check_for_upgrade.sh
index 17925af8b..d0ceba92d 100644
--- a/tools/check_for_upgrade.sh
+++ b/tools/check_for_upgrade.sh
@@ -24,7 +24,7 @@ function update_last_updated_file() {
}
function update_ohmyzsh() {
- ZSH="$ZSH" zsh -f "$ZSH/tools/upgrade.sh"
+ ZSH="$ZSH" zsh -f "$ZSH/tools/upgrade.sh" --interactive
update_last_updated_file
}
diff --git a/tools/upgrade.sh b/tools/upgrade.sh
index 0e4c368bc..cfd424527 100755
--- a/tools/upgrade.sh
+++ b/tools/upgrade.sh
@@ -70,10 +70,12 @@ if git pull --rebase --stat origin master; then
message="Hooray! Oh My Zsh has been updated!"
# Display changelog with less if available, otherwise just print it to the terminal
- if (( $+commands[less] )); then
- "$ZSH/tools/changelog.sh" HEAD "$last_commit" --text | command less -R
- else
- "$ZSH/tools/changelog.sh" HEAD "$last_commit"
+ if [[ "$1" = --interactive ]]; then
+ if (( $+commands[less] )); then
+ "$ZSH/tools/changelog.sh" HEAD "$last_commit" --text | LESS= command less -R
+ else
+ "$ZSH/tools/changelog.sh" HEAD "$last_commit"
+ fi
fi
fi