Jonathan Konrath

Written by Jonathan Konrath, technical writer, docs manager, and publications engineer.

  1. (Update: nope. I've since switched to VSC, so looks like you should too. I'll leave this here for nostalgia purposes.)

    Part of this switch to Jekyll I mentioned previously is that I now edit this site in Markdown instead of WordPress. The great thing about Markdown is you can theoretically edit it in anything; you could even use Notepad or TextEdit or even the DOS Edlin editor to make a Markdown file. But you probably want something that adds some conveniences, like a few key bindings to save some time typing, a preview pane, and the ability to search and replace multiple files.

    When I first started using Markdown at work in 2015, I looked for a good editor that would do all of this, but never entirely found it. I stumbled through trying to set up Notepad++ like an IDE (I was stuck on a Windows machine), and I almost considered setting up Eclipse as a Markdown editor, but then I remembered it wasn't 2003.

    I eventually settled on using Atom, which is a text editor-slash-IDE released by GitHub. It's free, open-source, and customizable, with a lot of optional packages that are easy to add.

    Here's what I did to set up Atom for my Markdown editing needs:

    • Not part of Atom per se, but life is much easier when I'm also using GitHub Desktop along with it. It makes it much easier to handle git commits/pushes/merges/branches. Atom does have its own git integration down in the lower right corner, where you see your current branch, do a quick fetch, and see PR review comments.

    • First thing I do is change the theme, because I can't deal with dark mode (sorry). Go to Preferences > Settings > Themes and pick something; I usually go with One Light, but there are many options.

    • Then go to Preferences > Settings > Install and grab the following:

      • language-markdown - adds grammar support for MD files.
      • markdown-writer - adds more MD writing features.
      • markdown-preview-enhanced - there are a few previewers out there, but this one seems to work best for me. I had problems with markdown-preview handling Jekyll files; maybe that's fixed now?
    • Go to Preferences > Settings > Packages and go to the settings for the spell-check package. In the Grammars section, add text.md.

    • If you File > Open to the directory of your project, it opens it with the hierarchy shown in the left sidebar, and you can then click around in that to open various files.

    I've been using this setup daily for a while now at work. But now everyone's using Visual Studio Code, so maybe I need to switch.

  2. I can't remember when, but I recently heard someone use the term dogfooding, as in a shorthand verb form of eating your own dog food. Every noun in tech becomes a verb, usually when it gets to marketing or sales, but this one made me roll my eyes a bit more than usual.

    My wife had never heard the term, which is a bit ironic, since she actually works in the dog food industry. I have mixed feelings about it, although it's marginally better than "drinking your own champagne," because I don't drink, and when I did, champagne was second only to tequila as the alcoholic beverage I disliked the most. But in the late nineties in the tech industry, they would roll out champagne almost as much as they would print team t-shirts. Anyway.

    The term "eating your own dog food" is supposed to mean using the tools your company makes to actually operate your company. If your company makes bug tracking software, you shouldn't be paying Atlassian to use Jira; you should be using your own software, to show customers that it actually works.

    (Side note: I've always called it JIRA. I started at the new place, and everyone was saying Jira. Turns out the name changed in September of 2017. See here. This is partly the trend of making everything lowercase, and partly testimony to how infrequently the last place updated their software.)

    So, the actual news here is that I'm "dogfooding" by moving this site away from Wordpress and doing it all with a static site generator. This is the same docs-as-code approach I do at my job. That means:

    • Writing everything in Markdown.
    • Using Atom as my editor.
    • Using Jekyll as the SSG.
    • Using the Minima theme with some customization, most notably pagination.
    • Pushing it all to GitHub.
    • Hosting it with GitHub pages.

    There's lots to cover here, and also not everything is done. My redirect from jonkonrath.com to the new hosted site is a bit of a hack, and I've barely started any page design. I'll get to that, and I plan to explain all of it as I go. But first, I need to go eat something other than dog food for lunch and not think about Alpo.

  3. Just a small programming note: after ten and a half years, I left my last position, and moved on to a new one. I’m still managing, still writing, but at a much younger company, which is always interesting.

    As per my usual policy, I won’t mention names here, but if you follow me on LinkedIn, you can figure it out.

    Also worth mentioning that as always, all words here are mine, and I don’t speak for my employer.

    Unrelated grammar nit: I was trying to determine if the saying was onward and upward or onwards and upwards. The  first one sounded right to me. Both of the -ward words in question are adverbs with the -s, or adjectives without. (You look downwards; Nine Inch Nails has a great record called The Downward Spiral.)

    The saying could be using adverbs or adjectives though, so none of this helps. I think both AP and Chicago Manual of Style would say that Americans would drop the -s and British love to keep it. So, onward and upward.

  4. I wish I could tell the 1990 me that the 2020 me would be posting DOS commands in a blog instead of using a brain-implant computer on the surface of Mars. (I also wish 2020 me could tell 1990 me to patent the idea for an online book store, or that the Reds would sweep the A’s in the World Series.) Anyway, here’s a quick one I should have known already.

    You can set the prompt in a command window by setting the environment variable PROMPT. There is a PROMPT command too, which I vaguely remember from the DOS days and setting up an AUTOEXEC.BAT file. But the PROMPT command only works for that session. The variable works for every session.

    The default would be PROMPT $P$G: show your current directory, then a greater-than sign, so you get C:\this\that> as your prompt. But you can do some other fun stuff:

    • $D – the date
    • $T – the time
    • $V – the OS version number
    • $B – a pipe symbol
    • $G and $T – greater-than and less-than
    • $S – space
    • $+ – a plus-sign for each level of depth in the PUSHD directory (If you’re not a habitual user of PUSHD/POPD, look into it.)

    There are more; do a PROMPT /? to see them.

    I normally set an environment windows by right-clicking My Computer and going to Properties > Advanced > Environment variables, but another fun trick is you can use the SETX command to do this, too. So I did this:

    SETX PROMPT=$T $P$G

    That adds the time to the front of the default prompt. The reason I did this is because Jekyll builds take forever, and I wanted an easy way to tell if I started the build two minutes or seventeen minutes ago, because time loses all meaning on the last day of a release.

    (Thanks: http://www.hanselman.com/blog/a-better-prompt-for-cmdexe-or-cool-prompt-environment-variables-and-a-nice-transparent-multiprompt)

  5. Every now and again, I run into a situation where a bunch of HTML files can’t be opened by simply double-clicking the index.html, and need to be hosted on a web server to behave properly. I think this used to happen with WebWorks output, and built Jekyll output does this. It’s also sometimes handy to have a web server spinning in the background so you can modify and preview things on the fly.

    In the past when this came up, I’d fall down a wormhole about installing the Apache or IIS web server, or trying to figure out where Apple moved the built-in out-of-date Apache web server in the latest version of macOS. (I think it’s gone completely in Catalina.) But instead of sifting through the many different Apache installers and Medium articles about how to get an entire full stack going, I realized this is dead simple if you have Python installed.

    First, do you have Python installed? A quick python -V will tell you. If you don’t, grab a copy.

    Open a command line in the directory you want to serve up, and if you have Python 3, do this:

    python3 -m http.server

    If you’re a Windows user, that is probably python and not python3.

    If you’re still using Python 2, do this instead:

    python -m SimpleHTTPServer

    Now point a web browser at localhost:8000 and there’s your stuff.

    If you’ve already got something on port 8000, put another port number after the command, like python3 -m http.server 90125.

    Don’t expect to run your Fortune 500’s production environment on this. It’s great for testing, though.

    (Thanks: https://developer.mozilla.org/en-US/docs/Learn/Common_questions/set_up_a_local_testing_server and https://docs.python.org/3/library/http.server.html)

Jonathan Konrath
Technical writing, management, documentation systems, API docs, and assorted blog posts from Jonathan Konrath.