Dotfiles for my tiling window manager + terminal workflow.
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.

70 lines
1.8 KiB

  1. #!/bin/bash
  2. # setup_marble=true
  3. # vars {{{ #
  4. linux_config_dir=/home/kevin/linux-config
  5. dot_dir=$linux_config_dir/dotfiles
  6. config_dir=$linux_config_dir/configs
  7. sys_config_dir=~/.config
  8. # }}} vars #
  9. # dotfiles {{{ #
  10. # link files {{{ #
  11. # Get directory variables from script.
  12. # List of dotfiles I want to link to system.
  13. dotfiles=(bashrc gitconfig inputrc imwheelrc vimrc xinitrc Xmodmap Xresources zshrc)
  14. cd $dot_dir || exit
  15. for dotfile in "${dotfiles[@]}"; do
  16. # Remove system dotfile.
  17. rm ~/."$dotfile"
  18. # Link dotfile in repository to system dotfile.
  19. ln -s "$dot_dir"/"$dotfile" ~/."$dotfile" && echo "Linked .$dotfile."
  20. done
  21. # }}} link files #
  22. # setup nvim config {{{ #
  23. orig_file="$sys_config_dir"/nvim/init.vim
  24. # Remove system dotfile.
  25. rm "$orig_file"
  26. # Link dotfile in repository to system dotfile.
  27. ln -s "$dot_dir"/nvim "$orig_file" && echo "Setup Neovim config."
  28. # }}} setup nvim config #
  29. # }}} dotfiles #
  30. # configs {{{ #
  31. cd $linux_config_dir || exit
  32. # List of config dirs in system config dir that I want to link to.
  33. config_dirs=(neofetch i3 i3blocks sam-i3blocks ranger)
  34. for cur_dir in "${config_dirs[@]}"; do
  35. # Remove system file.
  36. rm -rf ${sys_config_dir:?}/"$cur_dir"
  37. # Link config file in repository to system config location.
  38. ln -s "$config_dir"/"$cur_dir" "$sys_config_dir"/"$cur_dir" && echo "Linked $cur_dir config."
  39. done
  40. # }}} configs #
  41. # # marble mouse {{{ #
  42. # if [[ "$setup_marble" = true ]]; then
  43. # config_file_name="10-evdev.conf"
  44. # sys_layout_file="/etc/X11/xorg.conf.d/$config_file_name"
  45. # config_dir="$linux_config_dir/x/marble-mouse"
  46. # # Remove system file.
  47. # sudo rm -rf "$sys_layout_file"
  48. # # Link config file in repository to system config location.
  49. # sudo ln -s "$config_dir"/"$config_file_name" "$sys_layout_file" && echo "Setup Marble mouse config."
  50. # fi
  51. # # }}} marble mouse #