Skip to content

Instantly share code, notes, and snippets.

@wayneeseguin
Created August 4, 2010 01:08
Show Gist options
  • Star 5 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save wayneeseguin/ed6423a598b2c0c2a0e9 to your computer and use it in GitHub Desktop.
Save wayneeseguin/ed6423a598b2c0c2a0e9 to your computer and use it in GitHub Desktop.
# Mike,
# I hope that you find the following useful as it
# sounds like this is a common task for you.
# Place this in your ~/.bash_profile or shell 'dotfiles'
# Or simply paste it into the terminal you want to use it in
gemspecinstall() {
# Install Bundler, w00t!!!
gem install bundler --pre
# Create a Gemfile to build the gem from the gemspec.
printf "source :rubygems\ngemspec :path => '.'\n" > Gemfile
# Install Z gem!
bundle install
}
# or gembundle or whatever name makes sense :)
sandboxbundle() {
# Create a gemset for the current directory (gem) name
# under the currently selected (RVM) Ruby, optional.
rvm --create use "${rvm_ruby_string}@$(basename $(pwd))"
gemspecinstall
# Scratch that itch!
rake
}
# Then to use it from the directory you cloned a gem into:
sandboxbundle
# If you only want to install the gem to the current
# environment istead of sandboxed, from the cloned gem root:
gemspecinstall
# Enjoy!!!
# ~Wayne
@limeyd
Copy link

limeyd commented Aug 16, 2011

hey wayne is this still the best way to work with bundler and rvm?

@wayneeseguin
Copy link
Author

I never said this was a best way so NO :) This was me refactoring some code for someone.

@limeyd
Copy link

limeyd commented Aug 17, 2011 via email

@wayneeseguin
Copy link
Author

I'd be happy to screen share with you and show you my workflow. The reason I do not say 'this is the way' is because workflows are both personal and dependent on what you are working with. I do have a generalized workflow that I use and then add custom tooling for application specific items.

@limeyd
Copy link

limeyd commented Aug 18, 2011 via email

@wayneeseguin
Copy link
Author

Find me on IRC in #rvm during daytime EDT

@limeyd
Copy link

limeyd commented Sep 14, 2011 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment