This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# this don't work (bundler don't support nested platform/grouping https://github.com/carlhuda/bundler/issues/1298) | |
group :development, :test do | |
gem 'pg', :platforms => :ruby | |
gem 'activerecord-jdbcpostgresql-adapter', :platforms => :jruby | |
end | |
# you should do something like this | |
group :development, :test do | |
gem 'pg' if RUBY_PLATFORM != 'java' | |
gem 'activerecord-jdbcpostgresql-adapter' if RUBY_PLATFORM == 'java' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require "capistrano_colors" | |
require "railsless-deploy" | |
set :default_stage, "dev" | |
require "capistrano/ext/multistage" | |
set :use_sudo, false | |
set :application, "bar" | |
set :user, "www-data" | |
set :group, "www-data" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
~/Projects/opensource/jruby_report (master) $ gem install yajl-ruby | |
Building native extensions. This could take a while... | |
ERROR: Error installing yajl-ruby: | |
ERROR: Failed to build gem native extension. | |
/Users/plentz/.rvm/rubies/jruby-1.6.7/bin/jruby extconf.rb | |
WARNING: JRuby does not support native extensions or the `mkmf' library very well. | |
Check http://kenai.com/projects/jruby/pages/Home for alternatives. | |
creating Makefile |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
~/Projects/my/forgott (master) $ irb | |
1.9.3p125 :001 > puts `rvm current` | |
RVM is not a function, selecting rubies with 'rvm use ...' will not work. | |
ruby-1.9.3-p125 | |
=> nil | |
1.9.3p125 :002 > |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$:.unshift(File.expand_path('./lib', ENV['rvm_path'])) # Add RVM's lib directory to the load path. | |
require "rvm/capistrano" # http://beginrescueend.com/integration/capistrano/ | |
require "bundler/capistrano" | |
require "capistrano_colors" | |
require "new_relic/recipes" | |
set :use_sudo, false | |
`rvm info` | |
set :rvm_ruby_string, `rvm current` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
~/Projects/my/forgott (master) $ cap deploy | |
RVM is not a function, selecting rubies with 'rvm use ...' will not work. | |
RVM is not a function, selecting rubies with 'rvm use ...' will not work. | |
RVM is not a function, selecting rubies with 'rvm use ...' will not work. | |
* 02:02:43 == Currently executing `deploy' | |
* 02:02:43 == Currently executing `deploy:update' | |
** transaction: start |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NoMethodError (undefined method `in_use?' for nil:NilClass): | |
gems/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:201:in `clear_stale_cached_connections!' | |
org/jruby/RubyArray.java:1615:in `each' | |
gems/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:199:in `clear_stale_cached_connections!' | |
gems/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:250:in `checkout' | |
org/jruby/RubyKernel.java:1410:in `loop' | |
gems/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:230:in `checkout' | |
file:/lib/gems-gems-jruby-jars-1.6.7-lib-jruby-stdlib-1.6.7.jar!/META-INF/jruby.home/lib/ruby/1.8/monitor.rb:191:in `mon_synchronize' | |
file:/lib/gems-gems-jruby-jars-1.6.7-lib-jruby-stdlib-1.6.7.jar!/META-INF/jruby.home/lib/ruby/1.8/monitor.rb:190:in `mon_synchronize' | |
gems/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:229 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" # This loads RVM into a shell session. | |
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ brew --version | |
0.8.1 | |
$ brew doctor | |
Warning: Your Xcode is configured with an invalid path. | |
You should change it to the correct path. Please note that there is no correct | |
path at this time if you have *only* installed the Command Line Tools for Xcode. | |
If your Xcode is pre-4.3 or you installed the whole of Xcode 4.3 then one of | |
these is (probably) what you want: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
... | |
if Rails.env.a_fortune_one_company? | |
# required for threadsafe!. it have different behaviors when added here and when it's added to the env file | |
config.eager_load_paths += Dir["#{config.root}/app/**/"] | |
config.eager_load_paths += Dir["#{config.root}/lib/**/"] | |
end | |
... |