-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathinstall
executable file
·27 lines (20 loc) · 962 Bytes
/
install
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/bin/bash
SLACK_DIR=/Applications/Slack.app/Contents/Resources/app.asar.unpacked/src/static
u=`tput smul`
nu=`tput rmul`
b=`tput bold`
n=`tput sgr0`
echo -e "\n\t${u}Slack Custom Controls${nu}\n"
echo -e " Backing up current Slack configuration..."
echo -e " (to uninstall custom controls run"
echo -e " uninstall script in this directory)\n"
# Uses root permissions because some users do not own their /Applications directory and therefore cannot perform file operations within Slack.app content directories
sudo cp $SLACK_DIR/ssb-interop.js ./backup/
echo -e " Installing Controls...\n"
sudo rm $SLACK_DIR/ssb-interop.js 2>&1 | grep -i NoFile
sudo cp ./lib/ssb-interop.js ./lib/dark.css $SLACK_DIR/
echo -e " ${b}Complete.${n} Close and Restart Slack Application.\n"
echo -e " * Shortcuts *"
echo -e " ${b}Toggle Dark Mode Theme:${n} ⌘+D"
echo -e " ${b}Toggle Channels Sidebar:${n} ⌘+B"
echo -e " ${b}Toggle Visible Controls:${n} ⌘+G"