Setting up your bundle config to allow your host app to use the local version of your gem
What we don't want:
Having to test your gem on your host app after having to commit changes to your gem... and then having to rebundle your gemfile ... which forces you to refer to your gem-in-process like:
gem 'nfg_ui', git: 'https://github.com/network-for-good/nfg_ui', branch: 'feature/some_feature_branch_that_im_working_on'
And then have to:
$ bundle update gem_name`
None of that annoying stuff! Let's instead allow our gem to pick up immediate changes without having to rebundle from github.
Config bundler to use your local gem version:
Format:
$ bundle config [gem name] [path to the the local version of your gem]
Example using a real gem
This a gem that I'm working on and have cloned to my hardrive
$ bundle config local.nfg_ui /Users/jonathanroehm/projects/nfg_ui
Disabling local usage of your gem
Tell bundler config to STOP using your local gem version:
Format:
$ bundle config --delete local.[your gem name]
Example using a real gem
This deletes the config for the same gem I referred to above:
$ bundle config --delete local.nfg_ui