My dotfiles. Period.

setup 394B

1234567891011121314151617
  1. #!/bin/bash
  2. put() {
  3. echo "$1" >> "$HOME/.bashrc"
  4. }
  5. mark="# added by https://gitea.vornet.cz/netvor/mydots"
  6. if grep -qFe "$mark" "$HOME/.bashrc";
  7. then
  8. echo "already set up, giving up";
  9. exit 1;
  10. else
  11. put ''
  12. put '# added by https://gitea.vornet.cz/netvor/mydots'
  13. put 'test -f "${HOME}/.config/bashum/head.bashrc" \'
  14. put ' && . "${HOME}/.config/bashum/head.bashrc"'
  15. fi