From 4efef314be599419f1805b43c02a483983ee0871 Mon Sep 17 00:00:00 2001 From: pjv <327716+pjv@users.noreply.github.com> Date: Tue, 3 Sep 2019 06:27:43 -0500 Subject: [PATCH] fix cheat install MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 1. make script executable or it won’t work 2. instead of writing to user’s dotfiles, create a symbolic link with the script alias. --- install | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/install b/install index 2fb4750..6b9b45f 100755 --- a/install +++ b/install @@ -797,10 +797,9 @@ wo_ufw_setup() { wo_cheat_install() { curl -sL https://cht.sh/:cht.sh > /usr/local/bin/cht.sh + chmod +x /usr/local/bin/cht.sh + ln -s /usr/local/bin/cht.sh /usr/local/bin/cheat curl -sL https://cheat.sh/:bash_completion > /etc/bash_completion.d/cht.sh - if ! grep -q "cheat" $HOME/.bashrc; then - echo "alias cheat='/usr/local/bin/cht.sh'" >> "$HOME/.bashrc" - fi } ###