Copyright © 2024 Robert S. Muhlestein (rwxrob). All rights reserved.

The code portions of this book are dedicated to the public domain under the terms of the Creative Commons Zero (CC0 1.0 Universal) license (https://creativecommons.org/publicdomain/zero/1.0/). This means you are free to copy, modify, distribute the code portions only, even for commercial purposes, without asking permission, and without saying where you got them. This is so there is no fear your creations are your own after learning to code using them.

The non-code prose and images are licensed under the more restrictive Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License (CC BY-NC-ND 4.0) (https://creativecommons.org/licenses/by-nc-nd/4.0/). This means that no non-code prose or image from the book may be reproduced, distributed, or transmitted in any form or by any means, without the prior written permission of the copyright holder. This includes remaking the same content in different formats such as PDF or EPUB since these fall under the definition of derived works. This restriction is primarily in place to ensure outdated copies are not redistributed given the frequent updates expected.

"Terminal Velocity" is a legal trademarks of Robert S. Muhlestein but can be used freely to refer to this book without limitation. To avoid potential confusion, intentionally using this trademark to refer to other projects—free or proprietary—is prohibited.

Bookshelf

A Code Mage’s First Spell Book
Learn practical computer science and programming with Go as a first language

Terminal Velocity
Master the fastest human-computer interface

Bonzai Beauty
Compose completable command trees with the Go Bonzai command-line framework

Linux homelab init
Extend your code-mage magic with Linux and a Proxmox power tower

Autodidactic
Keys to success as a modern knowledge warrior

Programming with Purpose
Code for self-empowerment to save humanity

Dedication

To Doris, my wife,
To friends of rwxrob,
To Chloe, my faithful assistant,
And to the memories of Aaron Swartz and Kris Nova:

Thank you for your light, support, and inspiration.
This book would never have happened without you.

Preface

GitHub CLI tool (gh)

GitHub is a terminal master’s favorite service for one reason alone: the gh command-line tool. This humble command allows leveraging the full power of the GitHub API from the command line. In fact, it is so powerful that GitHub becomes more important than any other social media or threaded newsgroup service available.

Redirect user.github.io

Many GitHub users are unaware that creating a special repo that matches your username plus github.io, https://rwxrob.github.io, for example. Most use that with a custom domain name to host their main landing page on the Web. But what if you just used your GitHub profile instead? After all, unless you are a designer you really have no reason to showcase your ability to create a custom Web page.

The more significant the person, the less likely they are to have a fancy web page. I always chuckle at Bryan Ford’s web site. He’s the inventor of Parsing Expression Grammars with multiple significant technology and academic credits to his name, but he’s completely content to have a 1990s web site. He has nothing to prove with a flashy web template design.

Here’s the content of index.html you can add just such a GitHub repo that simply redirects anyone to your meticulously crafted and always up to date GitHub profile instead. Change rwxrob to your own name:

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="refresh" content="0; url=https://github.com/rwxrob">
    <title>Redirecting...</title>
</head>
<body>
    <p>If you are not redirected automatically, follow this <a href="https://github.com/rwxrob">link</a>.</p>
</body>
</html>

Enable GitHub repo discussions

Since GitHub added full support for threaded discussions there is even less reason to use any other service at all for communication. It’s not enabled by default, but can be enabled from one command on the command line:

gh repo edit --enable-discussions

Although this does not yet have the ability to interact with discussions from the gh tool, it most likely will in the future given all the stuff that has been progressively added to the gh command set. For now, opening the repo and clicking on the Discussions tab isn’t that hard:

gh repo view --web