Interactively rebase your current branch onto main, keeping the original base commit (i.e. not rebasing onto main directly).

makandracards.com

Added reference to git who.

Why Rails has multiple schema formats When you run migrations, Rails will write your current database schema into db/schema.rb. This...

ActiveStorage does not provide any built-in way of implementing authentication for the available DirectUpload endpoint in Rails. When using...

makandracards.com

Added methods to keep the line number steady while you time-travel between commits: Copy the file to a new...

haml.info

Haml renders HTML with indentation reflecting the nesting level of elements. When it comes to white-space preserving content, this...

Given there is a user with an attachable avatar: class User < ApplicationRecord has_one_attached :avatar end

Ubuntu 24 added some guarding for Python packages which no longer allows installing applications through pip on system level. Instead...

Hint If you are using our opscomplete.com hosting we can set all environment variables mentioned below for your deployment on...

makandra dev

Bundler allows you to specify the name of the Gemfile you want to bundle with the BUNDLE_GEMFILE environment variable...

Your package-lock.json should always match and resolve all packages from your package.json. Coming from Yarn, I was looking for an...

TL;DR: Rails ships two methods to convert strings to constants, constantize and safe_constantize. Neither is safe for untrusted...

In development, we store files using ActiveStorage's disk service. This means that stored files are served by your Rails...

tl;dr When a cookie includes an Expires attribute or an HTTP response includes caching headers like Expires or Cache...

developer.mozilla.org

Text fragments allow linking directly to a specific portion of text in a web document, without requiring the author to...

makandra dev

Capistrano 3 has a doctor task that will print information about Environment: Ruby, Rubygems and Bundler versions List of Capistrano...

blog.saeloun.com

Rails' fragment caching caches subtrees of an HTML document tree. While constructing that tree though, it can be really hard...

makandra dev

YJIT is Ruby's default just-in-time compiler. It is considered production-ready since Ruby 3.2 (source).

makandra dev

Git has the concept of hooks: bash scripts that are invoked at certain points in the Git lifecycle. One handy...

We recently migrated a Rails application from yarn to npm. We decided to go this step instead of upgrading to...

makandra dev

I noticed that tig 2.5.1 that is provided by Ubuntu 22.04 repositories has inferior bash completion than older versions after...

While the main goal always is to prevent long-running queries in the first place, automatic timeouts can serve as...

The ActiveSupport::BroadcastLogger allows you to log to multiple sinks. You know this behavior from from the rails server command...

Starting with ChromeDriver 127, if your application displays a beforeunload confirmation dialog, ChromeDriver will immediately close it. In consequence, any...