The Ruby and Rails community linklog
Made a library? Written a blog post? Found a useful tutorial? Share it with the Ruby community here or just enjoy what everyone else has found!
Submit a post
Post Preview
Note: Only the first pargraph is shown on the front page and overly long paragraphs may be broken up.
rspec-benchmark v0.3.0
rspec-benchmark adds a new performance matcher for comparing between two operations.
Percona Migrator - online MySQL schema migrations in Rails
“Percona Migrator Announcement” @prez_pau https://hackernoon.com/percona-migrator-announcement-6a32d5b7484c [more inside]
Sharing models between Rails apps – Keeping Rails engine migrations in the engine
Sharing models and a database across multiple Rails applications might not always be the best idea ever. Luckily there are tricks that allow you to do it right. In this article I describe how to keep migrations in the engine and make them run only once (not from each application that uses shared models). Sharing models between Rails apps – Keeping Rails engine migrations in the engine
NLP with Ruby goes online
Today we announce the online version of the RubyNLP list: http://rubynlp.org [more inside]
letsencrypt_heroku
Eventually I found a way to automate the SSL setup for heroku with letsencrypt without those annoying manual steps. And it also works for the renewal process! [more inside]
In Defense of Sliming
Don’t apologize for starting with a simple passing test. The practice of putting an obviously-temporary result as a first step in testing is useful. [more inside]
How to disable transaction blocks during migration
Migrations are used to modify your database. By default, all migrations run inside a transaction. You can disable the transaction during migration. Let’s have a look on how to disable transaction block! [more inside]
Secrypto API
This API Allow to encrypt/decrypt text http://secrypto.herokuapp.com/
Extending git with Ruby
Git offers some extension hooks that can be used to make our lives easier, I wrote this blog post to explain how you can take advantage of them using ruby.
Two Rails Based Elasticsearch vs Postgres Benchmarks
Sites like Amazon can use Sub Aggregations and Simple Aggregations to quickly get category and brand counts for millions of products. These posts compare the performance differences and offer some insight into using searchkick for elasticsearch and Rails for postgres to determine speed differences.
Postgres: Adding foreign keys with zero downtime
This blog post discusses foreign key migrations, which have consistently burned me in Rails. It’s only vaguely related to Ruby, but I thought I’d share. There is a PR in Rails to hopefully make these migrations a little easier in the future.
Giving super powers to Rails nested forms with Vue.js
I decided to try vuejs.org to implement dynamic nested forms and I really liked the result. For more details and code: https://medium.com/@kdiogenes/giving-super-powers-to-rails-nested-forms-with-vue-js-5091c2e6b37e#.7jj5m9lcl
When Method Names Should Go Out with a Bang
Why do some methods in Ruby end with an exclamation mark while others don’t? This quick post explains the bang convention. http://www.rubyletter.com/blog/2017/01/31/when-to-use-ruby-bang.html
RSpec Refactoring Patterns: Extract Matcher
Extract Matcher is good for when you’ve got one or more expectations verifying state. By extracting well-named matchers, you can make the spec more readable. More at https://www.wetestrails.com/blog/extract-matcher (with code samples)
Working with the Evernote API in Rails
The Evernote API offers superb leverage for harnessing your data. You can improve on the Evernote ecosystem by bringing your technology to the table. Read more.
Blazer - a great tool to see what (data) you get
No matter what kind of online business you run, you also collect some data. To be honest we collect and store more and more data nowadays. The problem is that almost no one understands collected data and it cannot be used to make better business decisions. [more inside]
Flash card game Language Cards 0.1.0 has been released!
Cross-platform compatible command line flash card game for learning foreign languages with full internationalization support (I18n) and the ability to easily add flash cards with YAML files of your own. See: language_cards This version update features game mode swapping between translation-practice and typing-practice. Lots of code refactoring and added support for using a home sub-directory for adding flash-card files, or translation files.
Adding "Cart" feature to your KMS-powered website
Adding “Cart” feature to your website has never been so easy before KMS Shop release. Check out this extension: https://github.com/webgradus/kms_shop
How To Test Ruby CLI: Code Generators
One of the most difficult tasks I met during Hanami development is to write integration tests for the Command Line Interface (CLI). This challenge required a deep knowledge of the Ruby toolchain. https://lucaguidi.com/2017/02/01/how-to-test-ruby-cli-code-generators/
How to Integrate Bootstrap 4 with Rails 5
Learn how to integrate Twitter Bootstrap 4 with Rails 5 without using any gem. Faster upgrades and no gem dependencies? Sounds good to me!
Login as another user with devise_masquerade
This week on GoRails, we cover impersonating other users with the devise_masquerade gem.
JQuery-Free Rails and Legacy Browsers
Rails 5.1 will no longer depend on JQuery. I ran the UJS test suite on several versions of IE to see how nicely the new system plays with legacy browsers. - http://blog.honeybadger.io/jquery-free-rails-and-legacy-browsers/