summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorblockiv <blockiv@tuta.io>2022-03-23 20:05:24 -0400
committerblockiv <blockiv@tuta.io>2022-03-23 20:05:24 -0400
commit2b7128905fc115e1d5da1ae9e4dc9d82b80813eb (patch)
tree2f0b44cb8ce6adf99040554466e269fc354210ac
parentMerge branch 'master' into 'master' (diff)
Add Makefile to simplify installation and removal process. Updated README to show usage
-rw-r--r--Makefile12
-rw-r--r--README.md8
2 files changed, 16 insertions, 4 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..7a2cc86
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,12 @@
+clean:
+ rm -rf /opt/shell-color-scripts
+
+install: clean
+ mkdir -p /opt/shell-color-scripts/colorscripts
+ cp -rf colorscripts/* /opt/shell-color-scripts/colorscripts
+ cp colorscript.sh /usr/local/bin/colorscript
+
+uninstall:
+ rm -rf /opt/shell-color-scripts
+ rm -f /usr/local/bin/colorscript
+
diff --git a/README.md b/README.md
index aeac88e..f6f83e7 100644
--- a/README.md
+++ b/README.md
@@ -25,10 +25,10 @@ Download the source code from this repository or use a git clone:
git clone https://gitlab.com/dwt1/shell-color-scripts.git
cd shell-color-scripts
- rm -rf /opt/shell-color-scripts || return 1
- sudo mkdir -p /opt/shell-color-scripts/colorscripts || return 1
- sudo cp -rf colorscripts/* /opt/shell-color-scripts/colorscripts
- sudo cp colorscript.sh /usr/bin/colorscript
+ sudo make install
+
+ # Removal
+ sudo make uninstall
# optional for zsh completion
sudo cp zsh_completion/_colorscript /usr/share/zsh/site-functions