Skip to content

Commit 3f8d369

Browse files
committed
Updated update.sh and install.zsh scripts to enhance user feedback with emoji indicators in echo statements.
1 parent 2f6221f commit 3f8d369

File tree

2 files changed

+27
-27
lines changed

2 files changed

+27
-27
lines changed

.vim/update.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,14 +43,14 @@ dir=~/.dotfiles/.vim/bundle
4343

4444
if [ -d "$dir" -a -z "$1" ]; then
4545
if which trash &>/dev/null; then
46-
echo " Moving old bundle dir to trash"
46+
echo "🗑️ Moving old bundle dir to trash"
4747
trash "$dir"
4848
elif which gio &>/dev/null; then
49-
echo " Moving old bundle dir to trash"
49+
echo "🗑️ Moving old bundle dir to trash"
5050
gio trash "$dir"
5151
else
5252
temp="$(mktemp -d)"
53-
echo " Moving old bundle dir to $temp"
53+
echo "📁 Moving old bundle dir to $temp"
5454
mv "$dir" "$temp"
5555
fi
5656
fi
@@ -70,7 +70,7 @@ for repo in ${plugins[@]}; do
7070
(
7171
git clone --depth=1 -q "https://github.com/$repo" "$dest"
7272
rm -rf "$dest/.git"
73-
echo "· Cloned $repo"
73+
echo "📦 Cloned $repo"
7474
[ "$plugin" = "onehalf" ] && (mv "$dest" "$dest.TEMP" && mv "$dest.TEMP/vim" "$dest" && rm -rf "$dest.TEMP")
7575
) &
7676
done

install.zsh

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -14,18 +14,18 @@ function symlink() {
1414
if [ -e "$dest" ]; then
1515
if [ -L "$dest" ]; then
1616
if [ ! -e "$dest" ]; then
17-
echo "Removing broken symlink at $dest"
17+
echo "🔗 Removing broken symlink at $dest"
1818
rm "$dest"
1919
else
2020
# Already symlinked -- I'll assume correctly.
2121
return 0
2222
fi
2323
else
2424
# Rename files with a ".old" extension.
25-
echo "$dest already exists, renaming to $dest.old"
25+
echo "📁 $dest already exists, renaming to $dest.old"
2626
backup="$dest.old"
2727
if [ -e "$backup" ]; then
28-
echo "Error: "$backup" already exists. Please delete or rename it."
28+
echo "Error: "$backup" already exists. Please delete or rename it."
2929
exit 1
3030
fi
3131
mv "$dest" "$backup"
@@ -35,27 +35,27 @@ function symlink() {
3535
}
3636

3737
if ! which git >/dev/null ; then
38-
echo "Error: git is not installed"
38+
echo "Error: git is not installed"
3939
exit 1
4040
fi
4141

4242
if [ -d "$basedir/.git" ]; then
43-
echo "Updating dotfiles using existing git..."
43+
echo "🔄 Updating dotfiles using existing git..."
4444
cd "$basedir"
4545
git pull --quiet --rebase origin main || exit 1
4646
else
47-
echo "Checking out dotfiles using git..."
47+
echo "📥 Checking out dotfiles using git..."
4848
rm -rf "$basedir"
4949
git clone --quiet --depth=1 "$repourl" "$basedir"
5050
fi
5151

5252
cd "$basedir"
5353

54-
echo "Updating common Zsh completions..."
54+
echo "Updating common Zsh completions..."
5555
rm -rf .zsh-completions ~/.zcompdump
5656
git clone --quiet --depth=1 https://github.com/zsh-users/zsh-completions .zsh-completions
5757

58-
echo "Creating symlinks..."
58+
echo "🔗 Creating symlinks..."
5959
for item in .* ; do
6060
case "$item" in
6161
.|..|.git)
@@ -81,29 +81,29 @@ symlink "$basedir/.vscode-$vscodeplatform.settings.json" "$vscodepath/settings.j
8181
symlink "$basedir/.vscode-$vscodeplatform.keybindings.json" "$vscodepath/keybindings.json"
8282
symlink "$basedir/.vscode-snippets" "$vscodepath/snippets"
8383

84-
echo "Adding executables to ~/bin/..."
84+
echo "🛠️ Adding executables to ~/bin/..."
8585
mkdir -p "$bindir"
8686
for item in bin/* ; do
8787
symlink "$basedir/$item" "$bindir/$(basename $item)"
8888
done
8989

9090
if [ -n "$VSCODE_REMOTE_CONTAINERS_SESSION" ]; then
9191
# We must be setting up a VS Code remote dev container, so I probably won't use Vim.
92-
echo "VS Code remote environment detected. Skipping Vim setup."
92+
echo "💻 VS Code remote environment detected. Skipping Vim setup."
9393
else
94-
echo "Setting up vim plugins..."
94+
echo "📝 Setting up vim plugins..."
9595
.vim/update.sh
9696
fi
9797

9898
if [ -e "$HOME/Library" ]; then
99-
echo "Adding extra keybindings to macOS..."
99+
echo "⌨️ Adding extra keybindings to macOS..."
100100
mkdir -p "$HOME/Library/KeyBindings"
101101
symlink "$basedir/DefaultKeyBinding.dict" "$HOME/Library/KeyBindings/DefaultKeyBinding.dict"
102102
fi
103103

104-
echo "Setting up git..."
104+
echo "🐙 Setting up git..."
105105
if [ -n "$VSCODE_REMOTE_CONTAINERS_SESSION" ]; then
106-
echo "VSCode remote container detected"
106+
echo "🐳 VSCode remote container detected"
107107
# VS Code won't add a .gitconfig if one already exists, so we need to put
108108
# ours in a magical secondary location I found by reading the Git docs.
109109
altdir="$HOME/.althome"
@@ -115,12 +115,12 @@ else
115115
fi
116116

117117
if which git-lfs >/dev/null 2>&1 ; then
118-
echo "Installing git-lfs"
118+
echo "📦 Installing git-lfs"
119119
git lfs install
120120
fi
121121

122122
if which ksdiff >/dev/null 2>&1 ; then
123-
echo "Found Kaleidoscope.app diff tool (ksdiff). Configuring git to use it."
123+
echo "🔍 Found Kaleidoscope.app diff tool (ksdiff). Configuring git to use it."
124124
git config --global difftool.Kaleidoscope.cmd 'ksdiff --partial-changeset --relative-path "$MERGED" -- "$LOCAL" "$REMOTE"'
125125
git config --global difftool.prompt false
126126
git config --global difftool.trustExitCode true
@@ -129,15 +129,15 @@ if which ksdiff >/dev/null 2>&1 ; then
129129
git config --global diff.tool Kaleidoscope
130130
git config --global merge.tool Kaleidoscope
131131
elif which code >/dev/null 2>&1 ; then
132-
echo "VS Code found. Configuring Git to use it."
132+
echo "💻 VS Code found. Configuring Git to use it."
133133
git config --global merge.tool vscode
134134
git config --global mergetool.vscode.cmd 'code --wait --merge $REMOTE $LOCAL $BASE $MERGED'
135135
git config --global diff.tool vscode
136136
git config --global difftool.vscode.cmd 'code --wait --diff $LOCAL $REMOTE'
137137
fi
138138

139139
if which tmux >/dev/null 2>&1 ; then
140-
echo "Setting up tmux..."
140+
echo "🖥️ Setting up tmux..."
141141
tpm="$HOME/.tmux/plugins/tpm"
142142
if [ -e "$tpm" ]; then
143143
pushd "$tpm" >/dev/null
@@ -150,23 +150,23 @@ if which tmux >/dev/null 2>&1 ; then
150150
$tpm/scripts/clean_plugins.sh >/dev/null
151151
$tpm/scripts/update_plugin.sh >/dev/null
152152
else
153-
echo "Skipping tmux setup because tmux isn't installed."
153+
echo "⏭️ Skipping tmux setup because tmux isn't installed."
154154
fi
155155

156156
postinstall="$HOME/.postinstall"
157157
if [ -e "$postinstall" ]; then
158-
echo "Running post-install..."
158+
echo "🚀 Running post-install..."
159159
. "$postinstall"
160160
else
161-
echo "No post install script found. Optionally create one at $postinstall"
161+
echo "ℹ️ No post install script found. Optionally create one at $postinstall"
162162
fi
163163

164164
if [ ! -e "$HOME/.zshlocal" ]; then
165165
color=$((22 + RANDOM % 209))
166166
echo -e "# If you want a different color, run ~/bin/256-colors.sh and replace $color below:\ncolorprompt \"38;5;$color\"" >"$HOME/.zshlocal"
167-
echo "Chose a random prompt color. Edit $HOME/.zshlocal to change it."
167+
echo "🎨 Chose a random prompt color. Edit $HOME/.zshlocal to change it."
168168
fi
169169

170-
echo "Done."
170+
echo "Done."
171171

172172
} # This ensures the entire script is downloaded.

0 commit comments

Comments
 (0)