title: How does one develop a pair of gems together, one using the other?
body: <p>I'm a complete moron when it comes to ruby, and I'm trying to clean up a build problem.</p>
  
  <p>In a directory with two gems, one of which depends on the other,
  the dependency seems ok until runtime.  Here's a test case:</p>
  
  <p><a href="https://github.com/dankegel/rdepdemo" rel="nofollow noreferrer">https://github.com/dankegel/rdepdemo</a></p>
  
  <p>And here's what happens when I run its demo.sh:</p>
  
  <pre><code>+ cd subdemo
  + bundle install
  Using rake 10.5.0
  Using bundler 1.16.5
  Using minitest 5.11.3
  Using subdemo 0.1.0 from source at `.`
  Bundle complete! 4 Gemfile dependencies, 4 gems now installed.
  Use `bundle info [gemname]` to see where a bundled gem is installed.
  + rake
  ...
  2 runs, 2 assertions, 0 failures, 0 errors, 0 skips
  + gem build subdemo
    Successfully built RubyGem
    Name: subdemo
    Version: 0.1.0
    File: subdemo-0.1.0.gem
  + cd ../demo
  + bundle install
  Using rake 10.5.0
  Using bundler 1.16.5
  Using subdemo 0.1.0 from source at `..`
  Using demo 0.1.0 from source at `.`
  Using minitest 5.11.3
  Bundle complete! 4 Gemfile dependencies, 5 gems now installed.
  Use `bundle info [gemname]` to see where a bundled gem is installed.
  + rake
  
  File does not exist: subdemo
  </code></pre>
  
  <p>(The problem may be related to the fact that there's no top-level Gemfile sewing them together, but that's kind of a feature; our team really likes seeing separate build logs for each gem.)</p>
  
  <p>Previous similar questions, without the runtime problem:
  <a href="https://stackoverflow.com/questions/19761326/how-can-i-develop-two-gems-together-with-bundler">How can I develop two gems together with Bundler?</a>
  <a href="https://stackoverflow.com/questions/13020669/how-do-you-develop-multiple-gems">How do you develop multiple gems?</a>
  <a href="https://stackoverflow.com/questions/18677217/local-dependency-in-gem-gemspec">Local Dependency in Gem .gemspec</a></p>