Skip to content

Instantly share code, notes, and snippets.

@MSchmidt
Created March 24, 2013 18:26
Show Gist options
  • Save MSchmidt/5232942 to your computer and use it in GitHub Desktop.
Save MSchmidt/5232942 to your computer and use it in GitHub Desktop.
Install ruby (with rbenv) on debian
#!/usr/bin/env bash
aptitude update && aptitude upgrade
aptitude install build-essential bison openssl libreadline6 libreadline6-dev curl git-core zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-0 libsqlite3-dev sqlite3 libxml2-dev libxslt-dev autoconf libc6-dev ncurses-dev
adduser ruby
#!/usr/bin/env bash
# rbenv
git clone git://github.com/sstephenson/rbenv.git ~/.rbenv
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> .bash_profile
echo 'eval "$(rbenv init -)"' >> .bash_profile
source ~/.bash_profile
# ruby-build
mkdir -p ~/.rbenv/plugins
git clone git://github.com/sstephenson/ruby-build.git ~/.rbenv/plugins/ruby-build
rbenv install 1.9.3-p392
rbenv global 1.9.3-p392
rbenv rehash
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment