MacOS adaption

New role, new laptop, new Operating system — Having come from Windows & Linux desktops, I found MacOS to be extremely jarring when it came to a number of simple but crucial tasks, it was time-consuming to find the equivalents and workarounds for many typicalß developer tools. I’ll summarise my approach here and update as and when I find improvements. A quick summary on what I need; Git, Code editors, Linux CLI, Linux containers, productivity shortcuts....

June 7, 2023 · 5 min · Joe Heaton

WSLg - Graphical Apps on Windows Subsystem for Linux

Windows Subsystem for Linux supports displaying graphical Linux apps, it implements this via transparent RDP which forwards the visuals to Windows. ...

February 21, 2023 · 1 min · Joe Heaton

Git config per directory

I discovered gitconfig’s includeIf feature can change your global Git config depending on which directory you are working in. This is super useful if you have different identities for different project, or you need to specify the SSH key to use, etc.. in my case I want to use my personal email address for personal projects and work email for work projects. So let’s assume a directory layout like this:...

February 9, 2023 · 1 min · Joe Heaton

Git Commands

Some of my most visited Stack Overflow answers are on how to use Git! We all remember how to add, commit, push, but how often to do you rebase, resolve merge conflicts, modify old commits? Here I’m going to list out all the Git commands I usually look-up! Including any relevant updates, since Git and the way we use Git is always evolving! Commands Git config for a directory full of repositories When you have sets of git repositories with different credentials it can be useful to manage shared git configuration across them....

February 2, 2023 · 5 min · Joe Heaton

Understand MermaidJS; Concepts & Syntax

MermaidJS is great because it brings graphs-as-code to the web! No longer do we need to run graphviz from the commandline to generate static image files each time we make a change; Now we see changes instantly, embed graphs with ease in source repositories and track their changes, etc.. The trouble I’ve had with Mermaid is figuring out the syntax, there are quite a few gotchas which don’t advertise themselves very clearly, such as it not tolerating blank lines, or spaces are comma-deliminated lists.. I’ll list these here so you can get graphing quicker than I did! ...

May 17, 2022 · 2 min · Joe Heaton

Styling MermaidJS

What’s better than a graph? A graph with style! Using Mermaid’s class definitions we can style blocks and subgraphs to reflect the ecosystem they belong to; In this case I want to style my infrastructure diagrams to Google’s branding. ...

May 13, 2022 · 2 min · Joe Heaton

My VSCode

Visual Studio Code, “VSCode”, is the hugely featureful successor to projects like Atom & Visual Studio itself, the extensibility of VSCode is key to this success and I’m going to share what I do to make VSCode work for me. ...

May 2, 2022 · 3 min · Joe Heaton

Host Hugo static website on GitHub Pages using Actions and my domain

In a cost-saving exercise I wanted to try host my personal website on a free platform, since the code repository is hosted on GitHub, I decided to look into GitHub pages. ...

March 12, 2021 · 5 min · Joe Heaton

my Vim

This is my .vimrc, I find it benefitial to use this where I do development to normalise my editor across different operating systems, and to enable some useful untapped features to make Vim feel a bit less prehistoric. ...

October 14, 2020 · 3 min · Joe Heaton

Windows Terminal - Change default profile

The new Windows Terminal requires some manual intervention to set the default profile.

February 21, 2020 · 1 min · Joe Heaton

Useful Unixisms

Here’s a list of useful piped commands or just commands for which I need a refresher on which arguments to use. For example, using Awk to print between two known lines, or seleting a line in sed are good examples of infrequently used commands which are really useful. ...

February 17, 2020 · 2 min · Joe Heaton

Run for every updated file

Using inotifywait to watch for file changes recursively in the current directory. I use $CHECK to ignore unwanted directories and filetypes. ...

February 11, 2020 · 1 min · Joe Heaton

Git feature branch & merge

Start with your master branch git checkout master git fetch origin If your local master has been modified, you can reset its state. git reset --hard origin/master Checkout a new feature branch. git checkout -b my-feature Make changes in this branch, committing as usual. git add file.txt git commit -m "add my file.txt" You can push your branch to allow others and yourself to evaluate and commit further to it....

April 9, 2019 · 1 min · Joe Heaton

tmux

I find myself working on the move a lot more recently and I often have to deal with poor terminal emulators, iffy connectivity and sometimes I need resume my work on another machine entirely. As such I am trying out tmux as a way of persisting my working environment between sessions, supporting multiple tabs for when my emulator lacks it (Looking at you PuTTY, Git Bash) and lastly allowing me to resume my work on another desktop. ...

April 3, 2019 · 2 min · Joe Heaton