chmod 777 /tmp/charsel/
# Makes charsel executeable
-chmod +x charsel
+chmod +x src/charsel
+
+# Makes local folder
+mkdir -p ~/.local/share/charsel/charfiles/
# 2 sets of commands for whether it is root or not
if [ `whoami` == root ]; then
- mkdir -p /usr/share/charsel/charfiles
+ mkdir -p /usr/share/charsel/charfiles/
cp charfiles/* /usr/share/charsel/charfiles/
mkdir /usr/share/doc/charsel
cp README.md /usr/share/doc/charsel/
cp src/charsel /usr/bin/
exit
else
- mkdir -p ~/.local/share/charsel/charfiles
- cp charfiles/* ~/.local/share/charsel/charfiles
+ cp charfiles/* ~/.local/share/charsel/charfiles/
cp src/motd ~/.local/share/charsel/
cp src/charsel ~/.local/bin/
exit
Fill it in, using the provided examples as a template. Hidden shortcuts go above the '---'
## LICENSE
-charfile is GPLv3 licensed, see COPYING for more information
+Charfile is GNU GPLv3 licensed, see COPYING for more information
-charfile is written by [Armaan Bhojwani](https://armaan.bhojwani.org), [Email](mailto:3fb650a9-b47e-4604-a282-1dd91953b2ee@anonaddy.me)
+Charfile is written by [Armaan Bhojwani](https://armaan.bhojwani.org), [Email](mailto:3fb650a9-b47e-4604-a282-1dd91953b2ee@anonaddy.me)
+
+## BRANCHES
+Development happens on the "development" branch, which then gets merged into the "master" branch once its ready for a stable release
# Merge both global and local charfiles
CHARDIR=/tmp/charsel
cp -R /usr/share/charsel/* $CHARDIR/
-cp -R ~/.local/share/* $CHARDIR/
-
-# Clear screen
-clear
+cp -R ~/.local/share/charsel/* $CHARDIR/
# Check if user provided an input
-[ -z "$1" ] && echo "No argument supplied" && exit
-
if [ $1 = "list" ]; then
echo "The following charfiles are installed"
ls $CHARDIR/charfiles
exit
+elif [[ $1 = "help" || $1 = "-h" || $1 = "--help" || $# -ne 1 ]]; then
+ cat /usr/share/doc/charsel/README.md
+ exit
else
-# Define charfile
+# Clear screen
+clear
+
+# Define charfile path
CHARFILE=$CHARDIR/charfiles/$1
# Define length of shortcut
WELCOME TO CHARSEL!
-FOR HELP, PLEASE REFER TO /usr/share/doc/charsel/README.md
+FOR HELP, PLEASE USE `charsel help`
+THIS PROGRAM IS GNU GPLv3 LICENSED. SEE https://www.gnu.org/licenses/gpl-3.0.en.html
+