Restoring a lost scene in Unity

FYI – This mostly applies to folks using Macs.

Well shit. Losing progress on a project is bound to happen to you at some point in your career. Whether the application hangs and you have to restart or the power goes out, you’re bound to experience some bad luck once in a while. Turns out that was me this morning.

I sa...

Categories in a Rails App

Categorizing things in a Rails app is a common need, but it’s a non-trivial lift to get it all implemented. Database relationships need to be right. How in the world should you set up your forms? What’s going on in my controllers? I’m going to do my best to show you how I implement categories.

Here’s our little todo l...

A gotcha with Active Storage and Cloudflare

Rails 5.2 introduced Active Storage and it’s pretty awesome. I’d used paperclip from the @thoughtbot folks for a long time, but file uploading is a requirement for just about any site these days so it might as well be part of the core. Now it is.

Well, if you happened to implement Active Storage into your Rails app an...

Deleting Facebook

I deleted Facebook for good a few weeks back. With the #DeleteFacebook hashtag trending and looming figures like Woz deciding to leave I figured I’d add my two cents.

Leaving Facebook is a two part story.

For years I have been absent from Facebook. I truly mean I didn’t get on. I used to only get on around my birthda...

Debugging in RubyMine with Rails 5.2

If you’ve upgraded to Rails 5.2 and are using RubyMine’s debugger you might notice that breakpoints aren’t working as they should. For me, they would only work in views, but controllers and models wouldn’t stop anything.

Turns out the problem is the inclusion of the Bootsnap gem in Rails 5.2. Bootsnap is awesome so yo...

Getting rid of Time Machine backup folder

Okay, wow. Have you been pulling your hair out trying to get rid of some old Time Machine backup files that simply won’t delete? Well, if you’ve tried a hundred things and ended up here I just might be able to help because I just dealt with the same thing.

Somehow Time Machine had made a backup to my boot drive. Not s...

Custom validation in Rails

Here’s a little trick I like to do when I’m addressing validations in my models. Let’s say you have a standard Post model. It might look something like the following.

If you’re like me and prone to ideas popping into your head at inopportune times then you probably only have a few seconds to jot down an idea before yo...

System Tests with RSpec, Rails, Capybara, and Devise

Since the release of RSpec 3.7 we’ve been able to take advantage of system tests which are new as of Rails 5.1. If you’ve been using RSpec for a while you’re already likely familiar with feature tests using Capybara. For those new to these types of tests: they allow us to test the actual actions of a user. Clicking, fi...

Bootstrap 4 Cheat Sheet

Get your Bootstrap 4 documentation faster!

This got posted on Hacker News the other day. It’s fantastic. It’s much quicker and cleaner than Bootstrap’s documentation. It’s not going to be as verbose, but if you’ve been using Bootstrap for a while and you just need the syntax, it’s lightning fast.

ActionMailer SMTP settings for SendGrid (Rails)

Okay, I got no Google hits for this. Here’s a tip if you’re using SendGrid in a Rails app for your transactional emails. A while back you needed to provide your SendGrid username and password (hopefully via environment variables), but now you can use an app-specific api key.

Here’s some historical context. This was th...

About These Posts

Matt Haliski's mug

My blog primarily contains writings about my work on computers, but I occasionally mix in fun life stuff. I am, at best, a mediocre writer, but I like doing my part to give back to the community. Feel free to contact me if you have specific something to chat about. See you around!