title: Load error when requiring lib directory from config/initializers in Rails
body: <p>Let say, that I have a <code>Lib</code> structure with directory <code>secret_code</code> inside.</p>
  <pre><code>    ├── lib
      │   ├── assets
      │   ├── files_excercises.rb
      │   ├── secret_code
      │   │   └── secret_1.rb
      │   └── tasks
  </code></pre>
  <p>And I want to make sure that this <code>lib/secret_code</code> is always loaded in app, therefore using initializers like this:</p>
  <pre><code># config/initializers/secret_code.rb 
  require &quot;#{Rails.root}/lib/secret_code&quot;
  </code></pre>
  <p>And I am getting this <code>error</code>:</p>
  <pre><code>/Users/user/.rvm/gems/ruby-2.0.0-p353/gems/activesupport-3.2.16/lib/active_support/dependencies.rb:251:in `require': cannot load such file -- /Users/user/project_name/lib/secret_code (LoadError)
  </code></pre>
  <p>What is wrong?.</p>
  <p>Note: I am aware, that this can be done in different way, trying to understand why this approach does not work.</p>
  <p><strong>EDIT</strong></p>
  <p>Even if this is added into <code>application.rb</code>:</p>
  <pre><code> config.autoload_paths  = %W(#{config.root}/lib/secret_code)
  </code></pre>
  <p>only <code>Ruby</code> is in <code>$load_path</code>:</p>
  <pre><code>#irb session: 
  2.0.0-p353 :003 &gt; puts $LOAD_PATH
  /Users/user/.rvm/rubies/ruby-2.0.0-p353/lib/ruby/site_ruby/2.0.0
  /Users/user/.rvm/rubies/ruby-2.0.0-p353/lib/ruby/site_ruby/2.0.0/x86_64-darwin12.5.0
  /Users/user/.rvm/rubies/ruby-2.0.0-p353/lib/ruby/site_ruby
  /Users/user/.rvm/rubies/ruby-2.0.0-p353/lib/ruby/vendor_ruby/2.0.0
  /Users/user/.rvm/rubies/ruby-2.0.0-p353/lib/ruby/vendor_ruby/2.0.0/x86_64-darwin12.5.0
  /Users/user/.rvm/rubies/ruby-2.0.0-p353/lib/ruby/vendor_ruby
  /Users/user/.rvm/rubies/ruby-2.0.0-p353/lib/ruby/2.0.0
  /Users/user/.rvm/rubies/ruby-2.0.0-p353/lib/ruby/2.0.0/x86_64-darwin12.5.0
  </code></pre>