Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

25 linhas
594 B

  1. #!/bin/bash
  2. # Set source and target directories
  3. powerline_fonts_dir=$( cd "$( dirname "$0" )" && pwd )
  4. find_command="find \"$powerline_fonts_dir\" \( -name '*.[o,t]tf' -or -name '*.pcf.gz' \) -type f -print0"
  5. if [[ `uname` == 'Darwin' ]]; then
  6. # MacOS
  7. font_dir="$HOME/Library/Fonts"
  8. else
  9. # Linux
  10. font_dir="$HOME/.fonts"
  11. mkdir -p $font_dir
  12. fi
  13. # Copy all fonts to user fonts directory
  14. eval $find_command | xargs -0 -I % cp "%" "$font_dir/"
  15. # Reset font cache on Linux
  16. if [[ -n `which fc-cache` ]]; then
  17. fc-cache -f $font_dir
  18. fi
  19. echo "All Powerline fonts installed to $font_dir"