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.
Advanced CLI tools with Ruby and dry-cli! | Hanami Mastery #37
Utility scripts in Ruby can be very powerful, but also very messy. In this episode I showcase dry-cli, to help you maintain advanced ruby CLI progarms. [more inside]
Punch Code Generator. Frame for designing business logic with The Clean Architecture
If you find a solution for how to pack your business logic you can have a look at Punch. Its basic idea is to provide a clean robust frame for domain business logic and bring efficiency to the design process. [more inside]
hexutils gem - Hex Encode / Decode Helpers; From Hex String to Bin(ary) String & Back
Hello, a new addition in the ongoing If I Were ~~King~~ Matz (aka Yukihiro Matsumoto) - Ideas For Ruby 4.0 - What’s Broken & Missing in Ruby 3.x and How To Fix It series I published a first version of the hexutils gem that adds the missing hex(adecimal) encode / decode helpers to String, NilClass, Kernel & Co. that get you from hex(adecimal) string to bin(ary) string and back. Happy wrangling with bits & bytes in ruby. Cheers. Prost. As always questions and comments welcome.
Simon Wardley on Improving Business With Maps
Learn how to use maps to change a business position or strategy, represent possible scenarios or options, and improve decision-making. [more inside]
Advanced Applicative Programming in Ruby
This time we discuss applicative lists, parsers and traversables. Read more here
Adding tests to an existing project
I wrote a blog post about how I’ve added tests to a gem I recently built without writing any tests initially: [more inside]
Awesome Ruby blogs
Hello everyone! 👋 I’m happy to share with you an updated list of ruby and rails blogs. [more inside]
Rails 7 on Docker. (PgSQL + Redis + Sidekiq + Sphinx)
Ready to go Rails Playground with some popular preinstalled and set up tools and services.
Clone and run bin/setup. Rails App will be ready to develop in minutes. Rails 7 on Docker
Using Nebula TextAssist from Glimmer DSL for SWT
Recently, I received a support request concerning Glimmer DSL for SWT (JRuby Desktop Development GUI Framework) and the use of Nebula Custom Widgets, specifically the text_assist widget (auto-complete text field). For a quick background about Nebula, it is a collection of 55+ enterprise-grade high-quality SWT (Standard Widget Toolkit) custom widgets, including a progress circle, a password revealer, and an oscilloscope. Thanks to Glimmer DSL for SWT, they are usable from Ruby. https://andymaleh.blogspot.com/2023/01/using-nebula-textassist-from-glimmer.html
Monkey Patch Responsibly
Learn how to deploy Monkey Patches in Rails Applications, or as Rubygems, that don’t blow up your production environment because you forgot to take them out when a final patch was released. [more inside]
Be Careful With Time Durations in Rails
Rails’ date and time helpers are great. They save us from duplicating simple add-duration-to-time logic across our applications and make the code more readable. However, complex date manipulations are dangerous places full of edge-cases. This article discusses some of them. https://www.honeybadger.io/blog/activesupport-duration-helpers/
Announcing the Ronin 2.0.0 Open Beta
After a year of continuous work refactoring, Ronin 2.0.0 (beta) has finally been released and is ready for beta testing. [more inside]
All Ruby Books @ Planet Ruby Opened Up /2023 Directory & More
Hello, the All Ruby Books collection was started by Florent Guilleux in 2016 and before shutting it down I volunteered to rescue the collection and moved it over to Planet Ruby and converted the code to an all static website built with ruby (via jekyll and github pages) from collections in markdown (one per book organized by directories per year). Anyways, to kick off the new year I added a new /2023 directory and added two upcoming ruby books in beta. Anything missing? Your contributions welcome.
Ruby Conferences & Camps in 2023 @ Planet Ruby - What’s Upcoming?
Hello, over at the Planet Ruby I opened-up a new page listing all Ruby Conferences & Camps in 2023 - What’s Upcoming?. It’s all built with ruby (via jekyll and github pages) and a (open) datafile in yaml. There’s even an old school web feed in xml (and modern flavor in json). What ruby (or rails) conference or camp are you planning to attend in 2023 (or are you cancel-cultured like DHH and have to re-start your own foundation and conference that invites you back as a keynote speaker ;-) ?
Preloading associations on an Array of Objects
It might happen that your initial array of objects is not an ActiveRecord Relation. You cannot use preload on an array of objects and therefore you suffer of N+1 queries. Here is a smart way to solve the problem! [more inside]
It is not what you expect, but it is what you want: how Data#initialize is designed
A curios core class design decision made for happier coding.
Why I think that Authentication Zero is a bad idea
Let’s start the new year with a hot take! I think Authentication Zero is a bad idea for security. I summed up here why I think that: [more inside]
"Woke" Conspiracy Lead By Schneems et al Trying to "Cancel Culture" Rails Lead
What’s ahead in 2023 in rubyland? I am not making it up my “good old friends” - Richard Schneeman (Schneems) and Brandon Weaver - that perma-banned “cancel cultured” for life my humble self from r/ruby & ruby-talk (see r/planetruby for some background) are now leading a conspiracy to “cancel culture” DHH from rails. [more inside]
Reading logs to debug? Consider different approach
Debugging applications can get hard. Unless you know what happened. You can make it easier for yourself, specifically in the most important parts of it. Check out how RailsEventStore can help there. https://blog.arkency.com/simplify-your-system-debugging-by-introducing-event-store-linking/
If I Were ~~King~~ Matz - Ideas For Ruby 4.0 - What's Broken & Missing In 3.x
Hello, to start off the new year with looking ahead I started a new page titled If I Were ~~King~~ Matz (aka Yukihiro Matsumoto) - Ideas For Ruby 4.0 - What’s Broken & Missing in Ruby 3.x and How To Fix It that is a (living) quick draft of ideas (backed-up with code & monkey-patches that you can use / try out today). Your questions and comments welcome. Happy new year. Prosit 2023!