Sheldon Hull

sheldonhull@macbook: ~/ (pwsh)
  • _________________________________
  • < Welcome! Thanks for stopping by >
  •  ---------------------------------
  •  \
  •   \
  •      __
  •     /  \
  •     |  |
  •     @  @
  •     |  |
  •     || |/
  •     || ||
  •     |\_/|
  •     \___/

Here you’ll find mostly tech talk and musings, with other topics periodically. If you want to stay in touch, look at the bottom for the curated newsletter I send out.

Cheers! 🙏🏻

Go R1 Day 37

progress initialized new start of cli tool to try to parse markdown content using Goldmark1 and then convert markdown links into reference style links Improved default template for starting new basic cli tools with Go to include zerolog and run based design instead of the majority of logic being in main. goldmark ↩︎

Go R1 Day 36

progress more taskflow work learned how to use io.Multiwriter to have both a stdout stream as well as output captured to a stringbuilder. got confused on reading docs, only to realize I was reading docs for a C# solution. 😂 used Pterm1 to beautiful console output, which was pretty cool to see in action. pterm/pterm: ✨ #PTerm is a modern go module to beautify console output ↩︎

Go R1 Day 35

progress Worked with Taskflow a bit more. Need to identify better error handling pattern on when to resolve vs handle internal to a function, as it feels like I’m doing needless error checking. Wrote func to run terraform init, plan, and apply. This takes dynamical inputs for vars and backend file. Also dynamically switches terraform versions by running tfswitch. Definitely more verbose code than powershell, but it’s a good way to get used to Go while achieving some useful automation tasks I need to do.

Go R1 Day 34

progress figured out how to import util/logger.go as a package after much confusion due to logger, log, *zerolog.Logger and more variables all deviously similar in name… how to pass around the initialized package logger that I configure. learned that global scope and package scoped loggers being initialized at run is concerned an anti-pattern properly wrapping to avoid the log initialization on import with type Logger struct { logger: *zerolog.Logger; } as an example avoids the same behavior as: var Log *zerolog.

Go R1 Day 33

progress successfully created logging package using zerolog learned about scoping with packages linked to a private internal repository and how to leverage the module replace operator to temporarily alter path import from url to local override. middleware is a newer concept, so I need to learn more on this later so I can understand how to use to inject special log handling for http requests and other actions. Thoughts for today are that the pressure of jumping into an existing codebase is resulting in me moving faster than I probably should.