rspec.info

In modern default RSpec configurations, your tests are usually run in random order. This helps to detect "flickering" tests that...

makandra dev

This card compares patterns to store trees in a relation database like MySQL or PostgreSQL. Implementation examples are for the...

github.com

The parallel-gem is quite easy to use and can speed up rendering time if you want to render the...

blog.jetbrains.com

RubyMine allows bookmarking lines of code. This is super-helpful when working on a complex problem. I've been using...

Some pseudo-elements need to be addressed with vendor prefixes. E.g. ::selection is not supported by Firefox, you need to...

Hint This applies only to distributions based on Debian. Requirement You need to setup the PostgreSQL Apt Repository first.

makandra Operations

on the bash (issued as postgres user) Start/Stop/Restart PostgreSQL pg_ctl -D $configdir start|stop|restart Start/Stop/Restart the corresponding PostgreSQL...

There are various ways to run external commands from within Ruby, but the most powerful ones are Open3.capture3 and Open3.popen3...

makandra dev
badssl.com

Website that offers lots of different kinds of HTTPS configurations, bad or good or complicated. They also offer a dashboard...

evilmartians.com

Adding a gem means you take over the liability towards the external code. Checklist Based on "To gem, or not...

We generally use multiple application servers (at least two) and you have to search on all of them if you...

First find the reference for the entry you want through looking at the stash: $ git stash list stash@{0}: WIP...

medium.freecodecamp.com

Collection of useful tools in the Chrome JavaScript console. Make the whole page editable This is not special to Chrome...

Sometimes huge refactorings or refactoring of core concepts of your application are necessary for being able to meet new requirements...

In general, you should not put a block element inside an inline element. So don't do this: text

This card tries to summarize by example the different uses of heredoc. In Ruby << vs. <<- vs. <<~ In Rails strip_heredoc...

web.archive.org

xargs is a powerful bash tool that can take input from $STDIN and pass it to a given command. I.e...

There is no CSS selector for matching elements that contains a given string ¹. Luckily, Capybara offers the :text option to...

api.rubyonrails.org

Instantiating ActiveRecord objects comes expensive. To speed up things, you can choose a more direct way to talk to your...

api.rubyonrails.org

When working with custom transactions and use ActiveRecord::Rollback you may encounter unexpected behaviour if you try to roll back...

If you want to find the commits that touched a specific text in a file, use git log -S 'text...

davidverhasselt.com

Rails 5 / 6 / 7 Method Uses Default Accessor Saves to Database Runs Validations Runs Callbacks Updates updated_at/updated_on Respects Readonly...

Ruby's __FILE__ keyword returns the path to the current file. On popular for this are Ruby binaries: #!/usr/bin/env ruby...

makandra Operations
redis.io

Hint You're not able to control which redis replica will chosen for the failover. Connect to your sentinel instance...