Skip to content

Instantly share code, notes, and snippets.

@dealloc
Created January 1, 2020 20:41
Show Gist options
  • Save dealloc/3532d3e8b29ab3703f9961cbf4598ca2 to your computer and use it in GitHub Desktop.
Save dealloc/3532d3e8b29ab3703f9961cbf4598ca2 to your computer and use it in GitHub Desktop.
WSL debian setup script
#!/bin/bash
# Update APT repositories
sudo apt-get update
# Now, install stuff we need.
sudo apt-get install -y vim git curl wget htop postgresql gnupg zsh
# Setup Elixir repositories
cd /tmp
wget https://packages.erlang-solutions.com/erlang-solutions_2.0_all.deb && sudo dpkg -i erlang-solutions_2.0_all.deb
sudo apt-get update
# Install Erlang/Elixir
sudo apt-get install -y esl-erlang elixir
mix local.hex --if-missing --force
mix local.rebar --force
mix archive.install --force hex phx_new 1.4.11
# Setup Postgres
sudo service postgresql start
sudo -u postgres psql -c "ALTER USER postgres with encrypted password 'postgres'"
# Ergonomics!
sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment