Worm with Glasses

Coding • DevOps • Personal

May 3, 2022

Seventeen Years and a Million Lines of Code

I was looking at my old development projects recently when I noticed that all of them predate 2005. In 2005, I started work at ePublishing as a Perl developer. In the past 17 years I’ve been:

  • a Ruby and Rails developer
  • VP of Software Engineering
  • Chief Software Architect

In all that time, I’ve written hundreds of thousands of lines of code (maybe more than a million), but it’s locked away.

It’s a bit depressing that almost two-decades of creativity is forever hidden from view. It’s the curse of corporate development: we can write blogs, give talks, and prepare papers, but we can’t show the code itself. All anyone sees are shadows on the wall.

More companies should release their source code. Most of what we write is not the company’s crown jewels. Let people see how you solved that weird 3rd-party integration! Or how you monitor some obscure open-source service.

Every company is standing on a mountain of open-source code. Give back and let your developers have the opportunity to show off!

Apr 30, 2018

Gem Home for Fish Shell

In a recent twitch stream, Gary Bernhardt showed a bit of behind-the-scenes in how he prepares his development environment for recording a screencast.

One of the tools he showed in passing was gem_home by Hal Brodigan.

gem_home is a simple script that manipulates Ruby’s GEM_HOME and GEM_PATH environmental variables in order to keep separate ruby gem locations.

By using gem_home, there is no longer a requirement to prefix all ruby commands with bundle exec. All the gems for a project are local to the project, which eliminates conflicts that might arise when gems for multiple projects are mixed together in one location.

Eliminating the need for bundle exec allows commands such as rspec to execute much quicker!

Unfortunately for me, I recently switched over to using fish shell from ZSH. Hal’s gem_home only supports Bash and ZSH. 🙁

One nice thing about gem_home is how simple and straightforward it is. In a few hours I was able to replicate its functionality as a fish shell compatible script!

If you’re using ruby and fish shell, I would highly recommend using my implementation of gem_home along with Jean Mertz’s wrapper around chruby. Both of these play well together.

Dec 12, 2017

🔗 Writing Code Like a Mathematical Proof

Spiro Sideris writes:

To write understandable code, always ask the question of who your audience is. What level of experience do they have? What are the prerequisites they should know before reading this function? There are even differences in the semantics between programming languages, so knowing the best practices, and the language coding style, will ensure you are writing readable code for developers in that language.

Writing Code Like a Mathematical Proof

Nov 10, 2017

🔗 Coding Principles Every Engineer Should Know

Sam Schillace writes:

I was talking with the engineering team at Box about what I’ve learned along this journey, and what came out of that conversation were my personal engineering principals. These aren’t rules or engineering guidelines. They’re simply the principles that I pay attention to when I write and operate code.

These include:

  • Be paranoid.
  • Don’t lie to the computer.
  • Keep it simple.
  • First rule of optimizing: don’t.
  • Don’t just fix the bug; fix all possibility of it ever happening again.
  • Question assumptions constantly.
  • Think long term. Slow down, it goes faster.
  • Care about your code.
  • Cheap, fast, right — pick two.
  • Conclusion: Be curious. Learn as much as you can, all the time.
Coding Principles Every Engineer Should Know

Jan 16, 2006

Programmer's Library

Every working programmer or software developer ought to have a large personal library of books they consider essential–these books are mine. My list started off being very language heavy (mostly Perl), but as I’ve gotten older (and gained more experience) I’ve gravitated towards broader topics in software development.







Regular Expressions





System Administration

Graphic Design/Usability