Opal, A new hope (for Ruby programmers)
Opal compiles Ruby to JavaScript and includes a runtime and core library, aiming for broad RubySpec compatibility for browser and client-side code.
Rails always tries to use a layout with the same name as your controller
Rails automatically applies a same-named layout for a controller, which can create surprising view behavior when an unintended template is picked up.
Threads and processes in a Capybara/Selenium session
Capybara/Selenium tests involve a test process, a server thread and a browser process, so blocking, stale time, and uncommitted transactions can cause seemingly impossible failures.
Careful when writing to has_many :through associations
has_many :through associations can lose or duplicate records when written to, especially with nested forms and loaded associations. Treat them as read-only or build the join records directly.
Howto set jQuery colorbox overlay opacity
Colorbox overlay opacity set in the initializer can be overridden by an inline style, leaving the backdrop too opaque. A CSS !important rule on #cboxOverlay restores the intended transparency.
Sort a Ruby array with multiple criteria
Ruby arrays can be ordered by multiple keys with sort_by, using an array of values for primary and secondary criteria. Natural sorting also works with the same pattern.
How to fix "undefined method `name' for Array" error when running bundled commands on Ruby 1.8.7 + Rails 2.3
Bundled commands can fail on Ruby 1.8.7 and Rails 2.3 with undefined method 'name' for Array because rubygems-bundler or Bundler no longer works reliably on older setups.
Skype screen sharing: Select which monitor to share
Multiple monitors can make Skype sharing tricky, but moving the call window to the desired display before starting sharing selects the correct screen on Linux.
Auto-coerced virtual attributes with Virtus
Virtual ActiveRecord attributes can lose Rails-style type casting, causing string values, validation roundtrip bugs, and broken select boxes. Virtus restores coercion for non-persistent fields.
Virtus can coerce structured values
Virtus auto-casts structured values such as hashes and arrays, letting attributes accept typed collections and maps without manual conversion.
Careful when calling a Ruby block with an array
Ruby procs can unexpectedly unpack arrays into multiple block parameters, while lambdas enforce arity and raise ArgumentError instead.
Embed Font Awesome icons from your CSS
Font Awesome icons can be used directly from Sass without adding them to the DOM, using icon constants and mixins for :before or :after content.
CarrierWave: Don't use #url when you mean a file path
CarrierWave url escapes non-ASCII characters while path returns the local filesystem path; use the right method for links, images, and send_file.
Build cronjobs or list next dates
Cron schedules are easy to mistype, and invalid syntax only appears when crontab tries to install the file. CronMaker helps build valid expressions and check them quickly.
Ruby: How to measure code execution time in an IRB or Rails console
IRB and Rails console sessions can time code execution directly with measure; older versions can use Benchmark.measure for manual timing.
Use the Ruby debugger on Rails 2 script/runner scripts
Rails 3+ script/runner debugging needs rdebug because --debugger is gone; Ruby-debug must be available and required to enter the debugger from a script.
Bash: How to only do things in interactive shells
Printing from .bashrc can break non-interactive commands like scp; checking for an interactive shell keeps startup output limited to terminal sessions.
Howto provide a single page preview for PDF & TXT with carrierwave
Single-page previews for PDF and TXT uploads can be generated with CarrierWave and RMagick by rendering the first page as a JPG thumbnail.
How to silence "I18n.enforce_available_locales" deprecation warnings
Rails 3.2.16 and 4.0.2 can emit deprecation warnings for invalid I18n locales after upgrades; I18n.enforce_available_locales controls whether unsupported locales are validated.
Ruby 1.8: SimpleDelegator is very slow
SimpleDelegator on Ruby 1.8 can be prohibitively slow because it defines methods for every target method; DelegateClass(User) is often much faster for fixed model types.
Spreewald 0.8.0 brings a file attachment step
File attachments can be assigned to model attributes and related objects in Cucumber scenarios, including polymorphic associations and timestamp setup.
Virtual attributes for integer fields
Virtual integer attributes in Rails can lose form selections and type casting on validation roundtrips; an auto-coerced accessor keeps values as integers or nil.
howto fix spreewald issue „database configuration does not specify adapter (ActiveRecord::AdapterNotSpecified)“
Spreewald fails with ActiveRecord::AdapterNotSpecified when database.yml defines Cucumber settings instead of test settings. Renaming the environment entry to test resolves the adapter error.
Rubymine >= 5.4.3.2.1 supports keybinding for "Goto next/previous splitter"
RubyMine 5.4.3.2.1 can bind hotkeys for moving between split panes, useful for keyboard-driven pane switching.