diff options
| author | benj <benj@rse8.com> | 2018-03-20 02:09:27 -0700 |
|---|---|---|
| committer | benj <benj@rse8.com> | 2018-03-20 02:09:27 -0700 |
| commit | 2e80a2fc1315d9da51555e4c7359f115a9dbf4c7 (patch) | |
| tree | 1b203bbe8f9fb922137966887a2b735e5c0dc67e /setup.sh | |
| download | setup-2e80a2fc1315d9da51555e4c7359f115a9dbf4c7.tar setup-2e80a2fc1315d9da51555e4c7359f115a9dbf4c7.tar.gz setup-2e80a2fc1315d9da51555e4c7359f115a9dbf4c7.tar.bz2 setup-2e80a2fc1315d9da51555e4c7359f115a9dbf4c7.tar.lz setup-2e80a2fc1315d9da51555e4c7359f115a9dbf4c7.tar.xz setup-2e80a2fc1315d9da51555e4c7359f115a9dbf4c7.tar.zst setup-2e80a2fc1315d9da51555e4c7359f115a9dbf4c7.zip | |
Basic setup for *nix and macOS
Diffstat (limited to '')
| -rwxr-xr-x | setup.sh | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/setup.sh b/setup.sh new file mode 100755 index 0000000..2df630e --- /dev/null +++ b/setup.sh @@ -0,0 +1,40 @@ +#!/bin/bash -e + + +### +# symlink .bashrc and .bash_profile, and create +# .bashrc.local and .bash_profile.local +### +bash_files=("$HOME/.bashrc" "$HOME/.bash_profile") +for i in ${bash_files[@]}; do + # create symlinks if they don't exist + if [ ! -L $i ]; then + echo "Beginning Process to Symlink $i" + echo "------------------------------------" + if [ -f $i ]; then + echo "removing regular file $i" + rm $i + fi + + fmtd_i=`echo $i | rev | cut -d'/' -f1 | rev` + echo "symlinking $i -> $PWD/$fmtd_i" + ln -s $PWD/$fmtd_i $i + + local_i=$PWD/$fmtd_i.local + if [ ! -e $local_i ]; then + echo "creating $PWD/$fmtd_i.local" + touch $local_i + chmod 666 $local_i + fi + echo "------------------------------------" + fi +done + +if [ "$(uname)" = "Darwin" ]; then + bash setup_brew.bash + + defaults write NSGlobalDomain KeyRepeat -int 0 + defaults write NSGlobalDomain InitialKeyRepeat -int 4 +fi + +echo "SETUP COMPLETE" |
