fix shellchecks warnings + stop using brew in Linux
This commit is contained in:
@ -3,7 +3,7 @@
|
||||
|
||||
echo "Hello $(whoami)! Let's get you set up."
|
||||
|
||||
echo "mkdir -p $(HOME)/Code"
|
||||
echo "mkdir -p $HOME/Code"
|
||||
mkdir -p ~/Code
|
||||
ln -snf ~/Code/dotfiles/dot_scripts ~/.scripts
|
||||
chmod +x ~/.scripts/*.sh
|
||||
@ -23,28 +23,15 @@ case "$(uname -s)" in
|
||||
Darwin)
|
||||
echo "(Mac OS X) installing homebrew"
|
||||
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
|
||||
;;
|
||||
|
||||
Linux)
|
||||
echo "(Linux) installing homebrew"
|
||||
git clone https://github.com/Homebrew/brew ~/.linuxbrew/Homebrew
|
||||
mkdir -p ~/.linuxbrew/bin
|
||||
ln -snf ../Homebrew/bin/brew ~/.linuxbrew/bin
|
||||
eval "$(~/.linuxbrew/bin/brew shellenv)"
|
||||
;;
|
||||
*)
|
||||
echo 'Homebrew installation aborted : Non supported OS'
|
||||
exit
|
||||
# Prevent `Error: Your Homebrew is outdated. Please run `brew update`.`
|
||||
echo "Updating Homebrew"
|
||||
brew update
|
||||
;;
|
||||
esac
|
||||
# Prevent `Error: Your Homebrew is outdated. Please run `brew update`.`
|
||||
echo "Updating Homebrew"
|
||||
brew update
|
||||
|
||||
# Create symbolic links
|
||||
echo "Creating symbolic links"
|
||||
ln -snf ~/.local/share/chezmoi/ ~/dotfiles
|
||||
ln -snf ~/Code/dotfiles/Brewfile ~/Brewfile
|
||||
ln -snf ~/Code/dotfiles/Gemfile ~/Gemfile
|
||||
ln -snf ~/Code/dotfiles/README.md ~/README.md
|
||||
ln -snf ~/Code/dotfiles/dot_bash_profile ~/.bash_profile
|
||||
@ -75,8 +62,21 @@ case "$(uname -s)" in
|
||||
esac
|
||||
|
||||
# Install dependencies (apps, fonts, ...) with Brew
|
||||
echo "Brew installing stuff (apps, fonts, ...)"
|
||||
brew bundle
|
||||
case "$(uname -s)" in
|
||||
Darwin)
|
||||
echo "(Mac OS X) Brew installing stuff (apps, fonts, ...)"
|
||||
ln -snf ~/Code/dotfiles/Brewfile ~/Brewfile
|
||||
brew bundle
|
||||
;;
|
||||
esac
|
||||
|
||||
# Install dependencies (apps, fonts, ...) for CentOS
|
||||
case "$(uname -s)" in
|
||||
Linux)
|
||||
echo "(CentOS) Installing stuff (apps, ...)"
|
||||
~/Code/dotfiles/centos.sh
|
||||
;;
|
||||
esac
|
||||
|
||||
# Switch to ZSH
|
||||
echo "switching to ZSH"
|
||||
@ -125,7 +125,7 @@ ln -snf ~/Code/dotfiles/dot_zshrc.pre-oh-my-zsh ~/.zshrc.pre-oh-my-zsh
|
||||
|
||||
echo "Installing Vundle + VIM Plugins"
|
||||
git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim
|
||||
vim +PluginInstall +qall
|
||||
vim +PluginInstall +qall > /dev/null
|
||||
#https://github.com/ycm-core/YouCompleteMe/blob/master/README.md#installation
|
||||
cd "$HOME/.vim/bundle/YouCompleteMe" || exit
|
||||
./install.py --all
|
||||
|
@ -4,7 +4,15 @@ export SDKMAN_DIR="$HOME/.sdkman"
|
||||
chmod +x ~/.scripts/*.sh
|
||||
source ~/.zshrc
|
||||
sdk use java 8.0.222-zulu
|
||||
brew bundle
|
||||
|
||||
# Homebrew reloading stuff
|
||||
case "$(uname -s)" in
|
||||
Darwin)
|
||||
echo "(Mac OS X) Homebrew reloading stuff"
|
||||
brew bundle
|
||||
;;
|
||||
esac
|
||||
|
||||
# OSX Defaults
|
||||
case "$(uname -s)" in
|
||||
Darwin)
|
||||
|
@ -2,9 +2,16 @@
|
||||
export SDKMAN_DIR="$HOME/.sdkman"
|
||||
[[ -s "$SDKMAN_DIR/bin/sdkman-init.sh" ]] && source "$SDKMAN_DIR/bin/sdkman-init.sh"
|
||||
sdk selfupdate
|
||||
brew update
|
||||
#brew upgrade
|
||||
brew outdated | xargs brew upgrade
|
||||
|
||||
# Upgrading HomeBrew stuff
|
||||
case "$(uname -s)" in
|
||||
Darwin)
|
||||
echo "(Mac OS X) Homebrew upgrading stuff"
|
||||
brew update
|
||||
#brew upgrade
|
||||
brew outdated | xargs brew upgrade
|
||||
;;
|
||||
esac
|
||||
|
||||
bundle update --all
|
||||
#gem update --system
|
||||
@ -15,5 +22,5 @@ sudo pip3 install --upgrade pip 2>/dev/null
|
||||
pip list --outdated --format=freeze | grep -v '^\-e' | cut -d = -f 1 | xargs -n1 pip install -U
|
||||
pip freeze > ~/requirements.txt
|
||||
# Update VIM plugins installed via Vundle https://github.com/VundleVim/Vundle.vim
|
||||
vim +PluginUpdate +qall
|
||||
vim +PluginUpdate +qall > /dev/null
|
||||
rustup-update
|
||||
|
Reference in New Issue
Block a user