Dotfiles, utilities, and other apparatus.
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.

134 lines
3.8 KiB

  1. #!/bin/sh
  2. KIT_ROOT=$(pwd)
  3. echo "installing kit from $KIT_ROOT"
  4. echo 'installing package prereqs'
  5. sudo apt-get install build-essential xterm tmux vim perl ack-grep \
  6. git git-gui htop zsh suckless-tools figlet xmonad trayer xmobar \
  7. volumeicon-alsa diodon curl jq byzanz festival redshift-gtk ranger \
  8. rofi xsettingsd wmctrl lynx perl-doc dict moreutils myrepos etckeeper \
  9. bzr cvs darcs mercurial subversion subversion-tools dunst i3lock \
  10. fzf xclip xsel xautolock pngphoon tree scrot pandoc dnsutils \
  11. pasystray pavucontrol exa shellcheck \
  12. bsdmainutils \
  13. calendar \
  14. visidata \
  15. sqlite3 \
  16. konsole \
  17. cabal-install \
  18. ncdu \
  19. yubikey-manager \
  20. mosh \
  21. xcalib \
  22. icc-profiles
  23. echo 'installing some extra fonts'
  24. sudo apt-get install fonts-noto-color-emoji fonts-liberation fonts-roboto-hinted texlive-fonts-extra
  25. echo 'installing pandoc from cabal'
  26. # TODO: restore this or put it elsewhere
  27. # cabal update
  28. # cabal install pandoc --lib pandoc pandoc
  29. echo 'installing perl dependencies'
  30. # TODO: Some of these belong with specific progs:
  31. sudo cpan -i Module::Build App::WRT DBI SQL::Abstract DBD::SQLite XML::FeedPP
  32. # TODO: These need to go in a venv now?
  33. echo 'installing python dependencies and utils'
  34. sudo apt-get install python3-pip
  35. if [ ! -d ~/python_bullshit ]; then
  36. python3 -m venv ~/python_bullshit
  37. ~/python_bullshit/bin/pip3 install panflute
  38. ~/python_bullshit/bin/pip3 install mastodon-archive
  39. ~/python_bullshit/bin/pip3 install pinboard-to-sqlite
  40. ~/python_bullshit/bin/pip3 install virtualenv
  41. fi
  42. echo 'vim setup'
  43. if [ -e ~/.vim ]; then
  44. echo 'a ~/.vim exists'
  45. else
  46. ln -s "$KIT_ROOT/home/.vim" "$HOME/.vim"
  47. fi
  48. mkdir -p ~/.vim/bundle
  49. if [ ! -d ~/.vim/bundle/Vundle.vim ]; then
  50. git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim
  51. fi
  52. vim +PluginInstall
  53. echo 'xmonad setup'
  54. echo "(don't forget to point /usr/share/xsessions/xmonad.desktop at xmonad.start)"
  55. if [ ! -d ~/.xmonad ]; then
  56. ln -s "$KIT_ROOT/home/.xmonad" "$HOME/.xmonad"
  57. fi
  58. if [ ! -f ~/.xmobarrc ]; then
  59. ln -s "$KIT_ROOT/home/.xmobarrc" "$HOME/.xmobarrc"
  60. fi
  61. if [ ! -f ~/.xsettingsd ]; then
  62. ln -s "$KIT_ROOT/home/.xsettingsd" "$HOME/.xsettingsd"
  63. fi
  64. # shellcheck disable=SC2088
  65. echo '~/bin'
  66. if [ ! -d ~/bin ]; then
  67. ln -s "$KIT_ROOT/home/bin" "$HOME/bin"
  68. fi
  69. # shellcheck disable=SC2088
  70. echo '~/fragments'
  71. if [ ! -d ~/fragments ]; then
  72. ln -s "$KIT_ROOT/home/fragments" "$HOME/fragments"
  73. fi
  74. # shellcheck disable=SC2088
  75. echo '~/cheatsheets'
  76. if [ ! -d ~/cheatsheets ]; then
  77. ln -s "$KIT_ROOT/home/cheatsheets" "$HOME/cheatsheets"
  78. fi
  79. echo 'shell setup'
  80. if [ ! -f ~/.zshrc ]; then
  81. ln -s "$KIT_ROOT/home/.zshrc" "$HOME/.zshrc"
  82. fi
  83. if [ ! -f ~/.bashrc ]; then
  84. ln -s "$KIT_ROOT/home/.bashrc" "$HOME/.bashrc"
  85. fi
  86. if [ ! -f ~/.sh_common ]; then
  87. ln -s "$KIT_ROOT/home/.sh_common" "$HOME/.sh_common"
  88. fi
  89. echo 'tmux / screen setup'
  90. if [ ! -f ~/.tmux.conf ]; then
  91. ln -s "$KIT_ROOT/home/.tmux.conf" "$HOME/.tmux.conf"
  92. fi
  93. if [ ! -f ~/.screenrc ]; then
  94. ln -s "$KIT_ROOT/home/.screenrc" "$HOME/.screenrc"
  95. fi
  96. echo 'git setup'
  97. if [ ! -f ~/.gitconfig ]; then
  98. ln -s "$KIT_ROOT/home/.gitconfig" "$HOME/.gitconfig"
  99. fi
  100. echo 'lynx setup'
  101. if [ ! -f ~/.lynxrc ]; then
  102. ln -s "$KIT_ROOT/home/.lynxrc" "$HOME/.lynxrc"
  103. fi
  104. echo 'keyboard setup (Ctrl and CapsLock swap)'
  105. sudo cp etc/default/keyboard /etc/default/keyboard
  106. # TODO: This worked on Debian 12 to trigger the new setup - I _think_.
  107. # Not sure if it's taken on a reboot or if I need to add a rule
  108. # or something to run each time.
  109. #
  110. # Sources: https://wiki.debian.org/Keyboard
  111. sudo udevadm trigger --subsystem-match=input --action=change
  112. echo 'Remember to:'
  113. echo ' - install commandlog from https://code.p1k3.com/gitea/brennen/commandlog'
  114. echo ' - chsh'