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.
Ruby Vector Graphics Programming ("Less Is More") Challenge - Draw 24x24 Pixel Punks
Hello, in the ongoing ~pixel~ vector art / punk programming - yes, in ruby - series I put together a new Ruby (Vector) 2D Graphics Programming (“Less Is More” or “Code Golfing”) Challenge. The challenge - draw 24x24 pixel punks w/ vector 2D graphics instructions (e.g. line_to, move_to, …) - using your ruby (2D graphics) library of choice. Cheers. Prost.
A no-go fantasy: writing Go in Ruby with Ruby Next
On the Martian blog, Svyatoslav Kryukov enters into a fantasy realm, and is forced to imagine that ✨everything must be written in Go!✨ [more inside]
Snake Game by Glimmer DSL for LibUI
Snake has been built test-first following the MVP (Model / View / Presenter) architectural pattern using Glimmer DSL for LibUI. [more inside]
New release of Truemail 🚀 configurable plain Ruby 📨 email validator
Fixed SMTP validation issues caused by Ruby 3.0 stdlib SMTP client 🚀 Be sure that email address valid and exists 📨
[Screencast] Speeding Up Requests
In this episode, we look at several issues around pagination and different kinds of querying that could affect performance when working with large datasets. https://www.driftingruby.com/episodes/speeding-up-requests
Ruby Pixel Art Programming How-To - The Making of 1-Bit (B&W) Adam (24x24 Pixel Punk)
Hello, I put together a 1-bit black & white edition of The Making of Adam (24x24 Pixel Punk) from Scratch / Zero Using Pixel Art Designs in the ASCII Text Format in the Pixel Art How-To series. Happy pixel art programming in ruby.
Glimmer DSL for GTK
Yes, I’ve done it! I built an entire Glimmer DSL in one day! I built Glimmer DSL for GTK after receiving an issue request for it on the Glimmer project page on GitHub! GTK (aka GIMP-Toolkit or [incorrectly] GNOME-Toolkit) is the premiere desktop GUI toolkit on Linux, which also runs on Mac (Quartz GTK+) and Windows. Glimmer DSL for GTK aims to supercharge productivity and maintainability in developing Ruby-GNOME applications by providing a DSL similar to Glimmer DSL for SWT. [more inside]
Glimmer DSL for LibUI Tetris Example
I recently got an issue request to build games in Glimmer DSL for LibUI, so I went ahead and built Glimmer Tetris. Of course, I followed the Glimmer Process in building it, so I released the following version changes of Glimmer DSL for LibUI along the way… [more inside]
Migrating from Webpacker to the New Bundling Approach
Interested in migrating from webpacker to jsbundling-rails and cssbundling-rails? I’ve migrated two Rails apps so far and have tips to share!
The Factory Method Pattern in Ruby (video)
The Factory Method Pattern might be somewhat hard to understand at first, mainly because you probably don’t need it as often. But nonetheless, it’s good to know about it and use it whenever you feel it’s appropriate. [more inside]
The Abstract Factory Pattern in Ruby (video)
The Abstract Factory Pattern allows you to do is to isolate conditional instantiations of related objects so that your client code can be extended without changing it. [more inside]
About that monkey-patching business...
Is monkey-patching inherently bad? Should its use make Polyphony illegitimate? These are the questions I’m exploring in my latest article.
Ruby on Rails Podcast Episode #390: Code Quality with Ernesto Tagwerker
Ernesto Tagwerker is the Founder of OmbuLabs, the Ruby on Rails development shop behind FastRuby.io. He comes back to the podcast to talk about code quality: what it is, what it is perceived to be and what its like to maintain a few Ruby code quality gems, including ruby-critic and skunk. [more inside]
The Singleton Pattern in Ruby (video)
The Singleton Pattern helps with restricting the number of instances a class can create to just one and gives you a global way of accessing the instance. [more inside]
GitHub Issue-style File Uploader Using Stimulus and Active Storage
I recently built a drag-and-drop and copy-and-paste file uploader for Markdown (like GitHub’s editor) using Stimulus and Active Storage. Just published the code and my write up on it:
International Pricing for Ruby and Rails Books and Courses
If you live in a country that has an undervalued currency compared to the dollar, it makes it difficult to invest in your education. [more inside]
Rubber Duck Dev Show Episode 18 | How Many 3rd Party Libraries Should You Use
Hear two rubyists discuss discuss how many 3rd party libraries you should use in your projects:
Rails Code Review with Kasper from Rails core
Kasper and I sat down to code review a pull request for the Unsafe URL protection in Rails 7. We talked about naming, shaping the code, and how to design code to better show its intentions. Watch the Rails PR Code Review with Kasper Timm Hansen screencast
New "Upsized" Female Pixel Punk Archetype (Incl Zombie/Ape/Alien) Experiment / Series
Hello, in the ongoing pixel art / punk programming - yes, in ruby - series I put together all new “upsized” unisize female pixel punk archetypes incl. zombie, ape, and alien that sport the same size / dimensions and eye/nose/mouth positions as the male archetypes. Pixel size (gender) equality at last! As a case study I converted the five top selling million $$$ punks to punkettes using the new unisize female archetypes that let you (re)use almost all “male” attributes such as Cap Forward, Knitted Cap, Headband, Small Shades, and so on. If the attributes differ for male / female such as wild hair or crazy hair - the female attribute version needs to get “stretched” by 2px on the left and top. And the neckwear such as the gold chain can (re)use the “female” version as-is. See the (Female) Pixel Punk Unisize Archetypes experiment page for more including the script - yes, in ruby - to (re)generate the top selling pixel punks from scratch / zero. Questions and comments welcome. Join us in the r/CryptoPunksDev channel / forum.
wordlist-1.0.0 released!
Wordlist is a Ruby library for reading, combining, manipulating, and building wordlists, efficiently.
Glimmer DSL for SWT Supports Linux DEB/RPM Packaging
Glimmer DSL for SWT v4.21.2.0 just added support for Linux DEB/RPM native executable packaging (while still supporting the older GEM packaging alternative), rendering Linux a 1st class packaging citizen in Glimmer DSL for SWT just like Mac, which has support for APP/DMG/PKG native executables/installers, and Windows, which has support for MSI/EXE native executables/installers. [more inside]
The Joy of Structs
I wrote a comprehensive guide to Ruby Structs which is meant to shed more light on this underutilized but powerful primitive. Enjoy!