All of my important config files
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.

23 lines
723 B

  1. #!/usr/bin/env bash
  2. DOTFILES=$HOME/.dotfiles
  3. if [[ ! -d ~/.oh-my-zsh ]]; then
  4. echo -e "\nInstall oh-my-zsh"
  5. echo "============================="
  6. sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
  7. ln -s $DOTFILES/zsh/custom.zsh ~/.oh-my-zsh/custom/custom.zsh
  8. fi
  9. echo -e "\nCreating symlinks"
  10. echo "=============================="
  11. linkables=$( find -H "$DOTFILES" -maxdepth 3 -name '*.symlink' )
  12. for file in $linkables ; do
  13. target="$HOME/.$( basename $file '.symlink' )"
  14. if [ -e $target ]; then
  15. echo "~${target#$HOME} already exists... Skipping."
  16. else
  17. echo "Creating symlink for $file"
  18. ln -s $file $target
  19. fi
  20. done