Skip to content

Instantly share code, notes, and snippets.

@anargu
Last active October 31, 2018 21:48
Show Gist options
  • Save anargu/8e153564ffc32c52718238df4bc79880 to your computer and use it in GitHub Desktop.
Save anargu/8e153564ffc32c52718238df4bc79880 to your computer and use it in GitHub Desktop.
my startup file after install a new linux distro/OS
#!/bin/bash
#git
sudo apt install git
# nvm
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash
nvm install node
printf "
*** copy this into ~/.profile:
export NVM_DIR=\"\${XDG_CONFIG_HOME/:-\$HOME/.}nvm\"
[ -s \"\$NVM_DIR/nvm.sh\" ] && \. \"\$NVM_DIR/nvm.sh\" # This loads nvm
"
#golang
curl https://dl.google.com/go/go1.11.1.linux-amd64.tar.gz -o /tmp/go1.11.1.linux-amd64.tar.gz
tar -C /usr/local -xzf /tmp/go1.11.1.linux-amd64.tar.gz
printf "
*** set GO VARIABLES (GOPATH and GO itself) in ~/.profile:
export PATH=\$PATH:/usr/local/go/bin
export GOPATH=\$HOME/.go
*** copy this snippet into ~/.config/fish/config.fish:
set -x GOPATH \$HOME/.go
set -x PATH \$PATH /usr/local/go/bin
"
# fish
sudo apt install fish
chsh -s /usr/bin/fish
mkdir -p ~/.config/fish
# vim ~/.config/fish/config.fish
# oh my fish: https://github.com/oh-my-fish/oh-my-fish
curl -L https://get.oh-my.fish | fish
# installing bass (for nvm)
omf install bass
printf "
*** copy this snippet into ~/.config/fish/config.fish:
function nvm
# bass source (brew --prefix nvm)/nvm.sh --no-use ';' nvm \$argv
bass source ~/.nvm/nvm.sh ';' nvm \$argv
end
*** copy this snippet into ~/.config/fish/config.fish:
set -x NVM_DIR \$HOME/.nvm
"
omf install nvm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment