Due to the way we setup Jasmine tests in our projects, you may run into various errors when Jasmine boots...

Cookies without an expiration timestamp are called "session cookies". [1] They should only be kept until the end of the...

...to a value. The validation is skipped silently when terms is nil. While this behavior is useful to validate acceptance in the frontend and not the admin backend, it also...

Git allows you to set push options when pushing a branch to the remote. You can use this to build...

When deploying code with Capistrano (depending on your configuration) at some point Capistrano tries to check out code from your...

...to name any file @imported by SASS with a leading underscore. SASS files not beginning with an underscore will be rendered on their own, which will fail if they are...

Active Record's select method allows you to make use of the power of MySQL select statements. On the one...

Usually, Unpoly compiler destructors are returned from the compiler function. However, when using async compiler functions, you can not register...

When you are using the default MIME-Type configuration and your application allows uploading files, it can be a security...

jQuery doesn't store information about event listeners and data values with the element itself. This information is instead stored...

Yesterday, Rails fixed a security issue (CVE-2014-3514) in Rails 4+. It was possible to use .where...

...new RegExp('^(\\d+) users') # => /^(\d+) users/ Our expression above now works only at the beginning of the matched string, looks for a number (\d+ [1]) and also captures that. Sweet...

bugs.launchpad.net

Terminator has a cool feature that allows you to split your terminal into many panels and type in all of...

...might have a negative impact on your application's performance. We did not yet benchmark it, but using it for elements that are rendered very often is probably a bad...

In order to request a SSL certificate from any dealer, you usually need a CSR certificate. As both the CSR...

github.com

The ancestry gem allows you to easily use tree structures in your Rails application. There is one somewhat unobvious pitfall...

...nested, :inverse_of => :parent accepts_nested_attributes_for :nested end class Nested < ActiveRecord::Base belongs_to :parent validates_presence_of :parent_id # <- end With the parent already persisted creating nesteds...

...soften the validation to only validate on the associated object: class Nested < ActiveRecord::Base belongs_to :parent validates_presence_of :parent # <- without `_id` end Drawback With this softened validation now...

blog.jayfields.com

Deprecated ways to execute shell code in Ruby This is just a reference for legacy code. For new code, always...

angular-tips.com

Angular comes with different types of services. Each one with its own use cases. All of these services are singletons...

...origin (e.g. git fetch and git status). You should be 0 commits ahead or behind. Add and commit a file touch .please-update git add .please-update

...is no way to make GitHub do this nicely. :( If you know of a better approach, please let me know...

...hide gems from the backtrace. In such cases, log_subscriber.rb is the inner-most (i.e. "best") source in the backtrace. You probably have an initializer with this line: Rails.backtrace_cleaner.remove_silencers!

In a web application you often need to move data between the client (HTML, Javascript) and the server (Ruby, Rails...

makandra dev
stackoverflow.com

Using git rebase can be painful but luckily you can resort to cheating with git reset and committing anew.

We recently had a problem on a Memcache cluster, where one of the servers showed a significantly worse cache hit...