diff --git a/patch-monolisa b/patch-monolisa index 1bbd5e3..03d1310 100755 --- a/patch-monolisa +++ b/patch-monolisa @@ -1,12 +1,11 @@ #!/usr/bin/env bash - exts=(otf ttf woff woff2) ext=$1 shift fp_args=$@ -if [[ -z "$ext" ]];then +if [[ -z $ext ]]; then echo "please provide an extension" exit 1 fi @@ -21,10 +20,8 @@ fi echo "Patching all fonts with ext -> $ext" echo "Using the following arguments for font-patcher $fp_args" - for fontfile in MonoLisa/$ext/*.$ext; do fontforge -script font-patcher $fontfile -o patched/$ext $fp_args done - diff --git a/update-fonts b/update-fonts index f57f86b..ce720ff 100755 --- a/update-fonts +++ b/update-fonts @@ -4,16 +4,16 @@ PATCHED_FONTS=./patched INSTALL_DIR=~/.local/share/fonts/MonoLisa for font_dir in $PATCHED_FONTS/*; do - patched_dir="${font_dir##*/}" - echo ">>> $patched_dir" + patched_dir="${font_dir##*/}" + echo ">>> $patched_dir" - if [[ -d "${INSTALL_DIR}/${patched_dir}" ]]; then - echo "deleting existing version" - rm -rf $INSTALL_DIR/$patched_dir - fi + if [[ -d "${INSTALL_DIR}/${patched_dir}" ]]; then + echo "deleting existing version" + rm -rf $INSTALL_DIR/$patched_dir + fi - dest=$INSTALL_DIR/$patched_dir - mkdir $dest && cp -v $font_dir/* $dest + dest=$INSTALL_DIR/$patched_dir + mkdir $dest && cp -v $font_dir/* $dest done echo "Don't forget to run 'fc-cache -f -v'"