diff --git a/Monaco_Linux.ttf b/Monaco_Linux.ttf new file mode 100644 index 0000000..99a7f96 Binary files /dev/null and b/Monaco_Linux.ttf differ diff --git a/README.md b/README.md index 0cd6003..0582f97 100644 --- a/README.md +++ b/README.md @@ -66,4 +66,9 @@ cd monaco-font ./install-font-gentoo.sh [url] ``` +#### Install Monaco Font on Arch Linux + +```bash +./install-font-archlinux.sh [url] +``` diff --git a/install-font-archlinux.sh b/install-font-archlinux.sh index de09bda..d54c117 100755 --- a/install-font-archlinux.sh +++ b/install-font-archlinux.sh @@ -1,21 +1,24 @@ #!/bin/bash -URL=$1 +URL="$1" FILENAME=${URL##*/} -FONT_DIR=/usr/share/fonts/TTF/ +FONT_DIR=~/.fonts/TTF/ -echo "Start install" -# sudo mkdir -p /usr/share/fonts/truetype/custom -# we don't need to do that, we have the TTF folder in /usr/share/fonts/ already -# take a look to the folder structure in: https://wiki.archlinux.org/index.php/Fonts#International_users +if [ -n "$URL" ] +then + echo "Start install" + mkdir -p $FONT_DIR -echo "Downloading font" -wget -c $URL + echo "Downloading font" + wget -c $URL -echo "Installing font" -sudo mv $FILENAME $FONT_DIR + echo "Installing font" + mv $FILENAME $FONT_DIR -echo "Updating font cache" -sudo fc-cache -f -v + echo "Updating font cache" + fc-cache -f -v -echo "Enjoy" + echo "Enjoy" +else + echo "No URL was provided. Please run the script again providing an URL to download a font." +fi