Skip to content

Instantly share code, notes, and snippets.

@gonzedge
gonzedge / error
Created November 11, 2011 02:21
Rails 3.1 "rails server" error Could not find a JavaScript runtime
Could not find a JavaScript runtime.
See https://github.com/sstephenson/execjs for a list of available runtimes.
@gonzedge
gonzedge / bundle_exec.sh
Created November 11, 2011 02:15
Rails 3.1 “rake db:migrate” fails with “stack level too deep” error
bundle exec rake db:migrate
bundle exec bash
@gonzedge
gonzedge / application.html
Created November 11, 2011 02:10
jQuery fadeIn and fadeOut: IE bug workaround
<body style="display: none;">
@gonzedge
gonzedge / highlight.vim
Created November 11, 2011 01:57
Change cursor highlight color on Vim
highlight Cursor guifg=black guibg=white
@gonzedge
gonzedge / gem_uninstall.sh
Created November 11, 2011 01:52
Updating and/or uninstalling all installed gems
gem uninstall `gem list | cut -d ' ' -f 1`
@gonzedge
gonzedge / content.js.erb
Created November 11, 2011 01:48
Rails 3.1 and the assert_select_jquery
if($('#container').is(':not(:visible)')) $('#container').show('blind', 1000);
$('#container').html('<%= render @content %>');
@gonzedge
gonzedge / application_after.rb
Created November 11, 2011 01:32
Rails 3.1 smtp gmail Errno::ECONNREFUSED Connection refused
Demo::Application.configure do
# ...
config.action_mailer.delivery_method :smtp
config.action_mailer.smtp_settings = {
enable_starttls_auto: true,
address: 'smtp.gmail.com',
port: 587,
authentication: 'plain',
user_name: '<[email protected]>',
password: '<password>'
@gonzedge
gonzedge / install.sh
Created November 11, 2011 01:17
Rails 3.1 “rails console” fails with “no such file to load — readline”
apt-get install libreadline-dev
rvm pkg install readline
rvm remove 1.9.2
rvm install 1.9.2
rvm --default 1.9.2
rvm use 1.9.2
@gonzedge
gonzedge / clone.sh
Created November 10, 2011 21:33
Refinery CMS, rails 3.1.1 and the Operation not permitted error Errno::EPERM
git clone git://github.com/resolve/refinerycms.git ~/refinerycms-edge
@gonzedge
gonzedge / install.sh
Created November 10, 2011 20:03
The nokogiri gem and the “libxslt is missing” error
apt-get install libxslt1.1 libxslt1-dev libxslt-ruby