Skip to content

Instantly share code, notes, and snippets.

@shaunfink
Last active March 9, 2019 15:44
Show Gist options
  • Save shaunfink/7ca17745ed1eb1d444343baaa257dd4c to your computer and use it in GitHub Desktop.
Save shaunfink/7ca17745ed1eb1d444343baaa257dd4c to your computer and use it in GitHub Desktop.
#!/bin/bash
# https://www.moncefbelyamani.com/how-to-install-xcode-homebrew-git-rvm-ruby-on-mac/
# http://usabilityetc.com/articles/ruby-on-mac-os-x-with-rvm/
# http://railsapps.github.io/installrubyonrails-mac.html
# https://gist.github.com/denji/8706676
# Import GPG Keys for Ruby
command curl -sSL https://rvm.io/mpapis.asc | gpg --import -
command curl -sSL https://rvm.io/pkuczynski.asc | gpg --import -
# Install RVM
curl -L https://get.rvm.io | bash -s stable --auto-dotfiles --autolibs=enable --rails
source ~/.bash_profile
# Install Ruby
ruby_version="2.5.1"
rvm install ruby-${ruby_version}
# Update Gems
gem update --system
# Set Ruby Version
ruby_version=$( rvm list | head -1 | awk '{ print $2 }' )
# Useful Gemset
useful_gemset="useful"
rvm use ${ruby_version}@${useful_gemset} --create
gem install bundler
gem install nokogiri
# Rails Gemset
rails_gemset="rails"
rvm use ${ruby_version}@${rails_gemset} --create
gem install rails --pre
gem install rails
# Puppet Gemset
puppet_gemset="puppet"
rvm use ruby-${ruby_version}@${puppet_gemset} --create
gem install puppet
gem install librarian-puppet
# Vagrant Gemset
puppet_gemset="vagrant"
rvm use ruby-${ruby_version}@${vagrant_gemset} --create
gem install vagrant-puppet-install
gem install vagrant-librarian-puppet
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment