aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorromkatv <roman.perepelitsa@gmail.com>2019-12-17 21:41:13 +0300
committerromkatv <roman.perepelitsa@gmail.com>2019-12-17 21:41:13 +0300
commit553bf08a74aa77d9810743c2b52d5a331066317c (patch)
treeff5fa893873a18ae8f1b82482690f5ab5ea77648
parent541646c12e51d5b22f74e530c4ee6c65a6c2ee43 (diff)
nag users to restart iTerm2 after installing fonts
-rwxr-xr-xinternal/wizard.zsh15
1 files changed, 11 insertions, 4 deletions
diff --git a/internal/wizard.zsh b/internal/wizard.zsh
index 516b1f58..857e111c 100755
--- a/internal/wizard.zsh
+++ b/internal/wizard.zsh
@@ -350,10 +350,17 @@ function install_font() {
print -P ""
print -P "Please %Brestart iTerm2%b for the changes to take effect."
print -P ""
- flowing +c -i 5 " 1. Click" "%BiTerm2 → Quit iTerm2%b" or press "%B⌘ Q%b."
- flowing +c -i 5 " 2. Open %BiTerm2%b."
- print -P ""
- exit 69
+ while true; do
+ flowing +c -i 5 " 1. Click" "%BiTerm2 → Quit iTerm2%b" or press "%B⌘ Q%b."
+ flowing +c -i 5 " 2. Open %BiTerm2%b."
+ print -P ""
+ local key=
+ read -k key${(%):-"?%BWill you restart iTerm2 before proceeding? [yN]: %b" || quit -c
+ [[ $key = (y|Y) ]] && exit 69
+ print -P ""
+ print -P "It's important to %Brestart iTerm2%b for the changes to take effect."
+ print -P ""
+ done
;;
esac
}