Dan's Tech Blog

Very infrequent posts about whatever I have going on

Previous | Page: 2 of 2 | Next

ActiveRecord.dup and constantize

July 16, 2020 | (Last Update : July 17, 2020)
active-record ruby Default post image

I’m still unsure how I want to use this blog and wether I intend on creating a separate section for these short “TIL” posts or if I want to keep them here, but for today I’m combining two TILs into a longer post. I’m also using this to experiment with a post not having an image associated with it; we’ll see if that bugs me and I end up changing it or not.

This week I’ve learned a bit about the limitations ActiveRecord’s dup function as well as how constantize works.

Read more...

Things I Forget When Creating New Characters in Gloomhaven

July 11, 2020 | (Last Update : July 11, 2020)
gloomhaven rules levelling Things I Forget When Creating New Characters in Gloomhaven

After not playing Gloomhaven for a bit, my wife and I opened up the box to realize that she needed to retire her character and make a new one before we play the scenario. Easy enough we thought, we opened up the rule book to ensure we were doing it the right way and… Lo and behold we had forgotten about things that make a fairly large difference.

Read more...

PostgreSQL num_nulls and num_nonnulls

July 10, 2020 | (Last Update : July 10, 2020)
postgres rails ruby active-record PostgreSQL `num_nulls` and `num_nonnulls`

PostgreSQL offers a few comparison functions that are very useful if your table has columns that require exactly one entry. I ran into a situation recently that utilized the num_nonnulls function combined with a DB constraint to ensure that only one of a group of tables had data.

Read more...

Dotfile Shenanigans

July 09, 2020 | (Last Update : July 09, 2020)
dotfiles shell bash zsh Dotfile Shenanigans

Recently I watched this video from RubyConf 2018 about dotfiles and decided to customize my own setup across my various systems (a personal Macbook, a work Macbook and a personal Linux server). If you’re not familiar with the concept of dotfiles, I’d watch the first few minutes of that video before continuing to read.

Read more...
Previous | Page: 2 of 2 | Next