Git Word-Diff and Wayback Machine Extension

Git Word Diff #TIL about the --word-diff parameter in Git which is a very useful option to see the changes in a file. It is especially useful for Markdown and LaTeX files, where the changes are usually in the form of words and sentences. The default git diff just shows the changes in the form of lines, which is not very useful for Markdown and LaTeX files. The command git diff --word-diff shows the changes in the form of words and sentences....

Applying multiple variable transforms in VS Code Snippets

TL;DR: It might not be possible. But there are workarounds via capture groups. #TIL how to apply multiple transforms to a variable in VS Code snippets using RegEx capture groups. I was trying to create a VS Code snippet for quickly creating new markdown files with prefilled Hugo post metadata fields, particularly for my SITREP posts. I wanted to be able to type @sitrep and have it expand to the following (using an example filename):...

Calculating marginal improvement in the 1% Rule

I got curious as to how the 37% improvement in James Clear’s book “Atomic Habits” was calculated. As such, I went about figuring out how and tried to generalize it to different time periods (rather than just a year) and with variable improvement and regression rates for each day. ...