My personal dotfiles
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

install.sh 2.4KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. #!/bin/bash
  2. AGREEN="\e[92m"
  3. ARED="\e[91m"
  4. ABLUE="\e[34m"
  5. ARESET="\e[0m"
  6. clear
  7. echo ""
  8. echo -e "$AGREEN▄ ▄ ▗▄▖ ▄▄ ▄ ▗▖ ▄▄ █ ▗▄▖"
  9. echo -e "$AGREEN█ █ ▝▜▌ ▐▛▀ █ ▐▌ ▐▌ ▐▛▀ ▀ ▝▜▌"
  10. echo -e "$AGREEN▜▖█▗▛ ▟█▙ ▐▌ ▐███ ▟█▙ ▀ ▗▟██▖ ▟█▟▌ ▟█▙ ▐███ ▐███ ██ ▐▌ ▟█▙ ▗▟██▖"
  11. echo -e "$AGREEN▐▌█▐▌▐▛ ▜▌ ▐▌ ▐▌ ▐▙▄▟▌ ▐▙▄▖▘ ▐▛ ▜▌▐▛ ▜▌ ▐▌ ▐▌ █ ▐▌ ▐▙▄▟▌▐▙▄▖▘"
  12. echo -e "$AGREEN▐█▀█▌▐▌ ▐▌ ▐▌ ▐▌ ▐▛▀▀▘ ▀▀█▖ ▐▌ ▐▌▐▌ ▐▌ ▐▌ ▐▌ █ ▐▌ ▐▛▀▀▘ ▀▀█▖"
  13. echo -e "$AGREEN▐█ █▌▝█▄█▘ ▐▙▄ ▐▌ ▝█▄▄▌ ▐▄▄▟▌ ▝█▄█▌▝█▄█▘ ▐▙▄ ▐▌ ▗▄█▄▖ ▐▙▄ ▝█▄▄▌▐▄▄▟▌"
  14. echo -e "$AGREEN▝▀ ▀▘ ▝▀▘ ▀▀ ▝▘ ▝▀▀ ▀▀▀ ▝▀▝▘ ▝▀▘ ▀▀ ▝▘ ▝▀▀▀▘ ▀▀ ▝▀▀ ▀▀▀"
  15. echo -e $ARESET
  16. if [[ $1 = "-g" ]] || [[ $1 = "--git" ]]; then
  17. git clone https://github.com/WolfeCub/dotfiles.git
  18. cd dotfiles
  19. ./install.sh
  20. elif [[ $1 = "-u" ]] || [[ $1 = "--uninstall" ]]; then
  21. for ITEM in `ls -d */`;
  22. do
  23. ( stow -D $ITEM )
  24. done
  25. elif [[ $1 = "-h" ]] || [[ $1 = "--help" ]]; then
  26. echo -en "Wolfe's dotfile installer (inspired by anthonytam)\n\n"
  27. echo -en "$ABLUE""USAGE$ARESET:\n"
  28. echo -en "\t${0} [FLAGS]\n\n"
  29. echo -en "$ABLUE""FLAGS$ARESET:\n"
  30. echo -en "\t-u, --uninstall\tRemoves all dotfile symlinks\n"
  31. echo -en "\t-h, --help\tDisplay this message\n\n"
  32. echo -en "Report bugs/problems by creating an issue on github\n"
  33. echo -en "https://github.com/anthonytam/DotFiles\n"
  34. else
  35. for ITEM in `ls -d */`;
  36. do
  37. TEMP=`echo $ITEM | sed s'/.$//'`
  38. echo -en "Setup config for $ARED$TEMP$ARESET? (y/n) "
  39. read USRINPUT
  40. case "$USRINPUT" in
  41. y)
  42. ( stow $ITEM )
  43. ;;
  44. *)
  45. printf "Skipping $TEMP\n"
  46. ;;
  47. esac
  48. done
  49. fi