A scrappy jobhunt toolkit (or: doing silly things with vim macros)

The silly macro in action

Last time I jobhunted, I kept an up-to-date markdown file - a table for application status and linked notes at the bottom for each call and interview. It was a pretty good system, but it was painful to keep up to date. My first instinct was to write a small CLI for inserting new applications and updating application status, but markdown is a surprisingly painful format to parse non-destructively, and I ended up finding a job before writing any code.

This time, I took a slightly different approach - instead of writing code to parse markdown and manipulate it, why not lean into my existing workflow and IDE?

This is probably a good time to mention that I do almost all of my writing and coding in vim. Perhaps also a good time to mention that I would not recommend this to anyone. And yet, it gives me some cool tools for problems like this!

I wrote a short macro (a re-runnable set of vim keypresses) that takes the contents of 3 vim registers (one each for the company, role name, and job posting link) and composes them into a new line in my application table and creates a new stub for any later meeting notes.

The macro

/^### Tracker
2}O| [[#a"cpa, "rpa]] | Applied | "=strftime("%-m/%-d/%Y")
pa |jo##### "cpa, "rpo
- Applied [here]("lpa) on "=strftime("%-m/%-d/%Y")
p

Piece by piece...

  • /^### Tracker, find the markdown header before my table
  • 2}k, go down two 'paragraphs' (below the table)
  • O, enter edit mode on the line before (the new end of the table)
  • [[#a, write the beginning of a markdown intra-page link (e.g., [[#header text to link to]])
  • "cp, paste the company name
  • a, write a comma and space to separate the job role from the company name
  • "rp]], paste the job role / title and close the markdown link
  • | Applied |, write the state of the application
  • "=strftime("%-m/%-d/%Y")pa, calculate the current date, store it in a register, then dump it in the table
  • |, close the table
  • jo##### , go down one line and make a new, small header (h5)
  • "cpa, "rpo, paste the company and role name in the same format so the link above links correctly to the header
  • - Applied [here](, begin an external markdown link to the job posting
  • "lpa), paste the URL and close the markdown link
  • on "=strftime("%-m/%-d/%Y")p, include the date in the same format as earlier

And...?

Instead of writing a bespoke tool, it's really lovely to be able to use an existing IDE & workflow and build something easily reusable in just a few minutes. That's it, more or less.