BUILD TIME VARIABLES

While not entirely new learning, I spent time today working on variable injection using ldflags with go build - the Gopher Guide folks have an article on Digital Ocean to learn about using ldflags for setting version information Until today I always thought variable injection worked for variables defined in a Go program’s main package. In needing to inject a version string held by an exported Version variable in a cmd package, I learned the way to reference the variable within the ldflags is to use the full import path of the cmd package.

STARTING SMALL

In the spirit of Tiny Habits, the process of building sustainable habits by marking them super small, I am starting a new series of posts called Tiny Learnings. Tiny learnings will be a series of small blog posts about a thing I learned in the week to help me create a habit of writing. With my newly formed habit of taking 15 minutes of my mornings to practice my craft, finding something to write about should be as showing up.

CODE REVIEWS USING RERERE

ReReRe, short for Review/Retest/Reflect, is my three phase process for reviewing code changes. It is one of the key processes that I’ve come to rely on for learning and growing my craft. Side note, I refer to GitHub and its pull request system within the post; however, ReReRe works independently of GitHub and should work for any team with a formal code review process. In fact, I generally review code changes locally within my editor, as opposed to on GitHub, to allow for off-line reviews.