MacOS users, perhaps you know you can option-click an icon in the Dock to force quit that app. You can also press Shift while clicking the Apple menu to do the same for the current app. Nifty. 😽RC Logr 20210117 110526 - MacOS users, perhaps you know …
Here be my pithy, short, technical nuggets. Maybe I’m the only one who cares. Who says Hugo can’t be used for microblogging‽
17 Jan 2021
07 Jan 2021
Two interesting new apps, both keyboard-centric, light and fast: @height_app, @linear_app 😍
Update 17 Jan 2021
- Linear app is opinionated, and wants you to buy in to their philosophy, which appears to be not quite finished (“cycles” not sprints, etc).
- Height app is flexible and lets you adjust your workflow how you want.
Kind of like SAP vs Oracle in the ERP world, no?
In any case, either one would be worlds better than Jira, which, in addition to its sister app Confluence, to this day has that good ol’ java sluggishness. I mean, those apps are painfully slow, and exist simply because “that’s the way we’ve always done it”. Ugh.RC Logr 20210107 215726 - Two interesting new apps, both …
01 Jan 2021
🗓 "New Year Holiday" in Japan
Happy new year! May your 2021 be healthy & extra geeky! 🤖RC Logr 20210101 084415 - Happy new year! May your 2021 …
29 Dec 2020
🗓 "Year End Holiday" in Japan
MacOS users, if you ever need to reset your Finder, Dock or Menubar, you can issue these commands from Terminal.
It’s useful sometimes.RC Logr 20201229 132632 - MacOS users, if you ever need …
27 Dec 2020
MacOS Big Sur users, if you are having trouble with trackpad gestures, try opening terminal and doing:
killall -kill Dock
This fixes the problem for me. 🤖RC Logr 20201227 210231 - MacOS Big Sur users, if you …
15 Nov 2020
Devs, if you upgraded to MacOS Big Sur and use brew, you might need to manually uninstall and re-install «CLT» Command Line Tools. It does appear in Software Update, but just updating Xcode there does not do it. 😅
Here are the simple steps you can take in your term:
Once you run the second
install line, it will popup a dialog box to agree to and off you go. Go have a coffee, as it is a large download.
N.b.: if you stumbled on this and don’t know what to do, you can run the above in Terminal.app. You can copy paste in the first line, press enter, then because the command uses
sudo you’ll need to enter your MacOS login password. The password you enter will still be effective for the second line, which pops up a disclaimer to agree to. When you agree, it will do the needful and reinstall.
02 Nov 2020
«Dasel» is an open source DAta SELector program that allows you to query and modify data structures from JSON, YAML, TOML and XML, similar to jq and yq. It is written in go, so it has zero runtime dependencies. 🤩
If you look at the repo readme, it seems like it would be fairly trivial to convert from jq to dasel in many cases, and it also replaces some obscure jq syntax with more verbose syntax that might be a tad easier to grok.RC Logr 20201102 163842 - «Dasel» is an open source DAta …
18 Aug 2020
Learned about the sweet free and open source «@Asciinema» service today, which lets you record your terminal sessions for sharing. Read on for a few tips. 🤩
- Create an account at https://asciinema.org by supplying an email, click on the link in an email you will receive to create an account, then give yourself a username. This creates a profile URL like: https://asciinema.org/~rickcogley
- If you use macOS and
brew, install with
brew install asciinema. ASCII Cinema, get it?
asciinema authand open the link that appears in the terminal, in the browser where you are logged into asciinema. This links your localhost with your account, so when you make a screen recording on that host, it will be linked and appear when you are logged in. You can see what localhosts are linked in the “recorder tokens” section in Settings in the web app:
- Record a session by issuing
asciinema rec -t "Title of the Session"changing the title to taste. Press
ctrl-Dto exit, and you’ll get a message like:
- You can download the “cast” files for sharing, as well. They are tiny, compared to video screencasts.
30 Jul 2020
If you make a mistake and enter sensitive information in your zsh prompt, it is saved in history. Since you do not want that info sitting around in a plain text file, simply edit $HISTFILE to get rid of the offending line, then use
fc -R to reload the history file. 😎
A couple of tips:
- zsh history is often kept in
~/.zsh_historybut that path can be confirmed by doing
~/.zsh_historymight be massive, but
vimcan load it without trouble. Assuming you have
vim, open the history file with
vim ~/.zsh_history, press
esc, then use
shift + Gto jump to the end of the file. Delete the offending line with
Dthen save with
- if you confirm with
historyit will show the unneeded line still, so do the
fc -Rto reload the history file you just edited and saved.
21 Jul 2020
If you want to autosign git commits on Mac, there are a couple of tricks to it. I have not been able to get brew gpg to work consistently well, but installing from gpgtools.org seems to be able to be made to work. 🤖 This worked for me:
- Install GPGTools from https://gpgtools.org
- Create / import a key, then run
gpg --list-secret-keysto find the
- Make git settings, specifying the signing key as the fingerprint with no spaces:
- If you want to autocommit to GitHub, open https://github.com/settings/keys and add the same public gpg key there. This links signed commits you make locally, once you push to master on the remote.
~/.gnupg/gpg-agent.confand add this line:
I had the brew version installed, and this was set to call
/usr/local/bin/pinentry-mac, but the brew version is an older version. You can see that the
pinentry-mac binary is being called from within an app bundle.
~/.gnupg/gpg.confand add this line:
You can relogin with
exec $SHELL --login, and reload the agent with
gpgconf --kill gpg-agent.
It may work now.RC Logr 20200721 195846 - If you want to autosign git …
If you like Sudoku, you might also like «Hexologic», by Mythic Owl. ⬡
六角論理 in Japanese.RC Logr 20200721 085228 - If you like Sudoku, you might …
20 Jul 2020
«Zsh for Humans» (z4h by @romkatv on GitHub) is a configuration for z-shell that just works and works well. It has a killer ssh wrapper feature, that lets you auto-push your zsh environment up to a remote server, and is pre-configured with the most useful stuff. So sweet. 😎
That is not to even mention the awesome prompt it includes: powerlevel10k.
Use the ssh wrapper like this:
If you are on MacOS, be sure to tweak some settings in your term so the bindings work as expected:
- iTerm, Prefs, Profiles (select your profile), Keys, then…
- Right/Left option key: Esc+
- in the config file:
- in the config file:
Now you can enter a command like
history and before hitting Enter, press
19 Jul 2020
Today I sat and replaced cat with «bat». Bat is a fast (written in Rust) cat clone with syntax highlighting for programming and markup languages, integration with your $PAGER, and git index awareness. 🔥
Set defaults in a config stored in
~/.config/bat/config, which looks something like:
most as my
$PAGER and it appears to not play well with
bat, so, setting the
--pager in the config was required.
18 Jul 2020
«Exa» (@dot_slash_exa) is a superb modern and fast ls replacement that supports colors, file and filesystem info, tree view, git info, and wide view. You have plenty of compute power, so why not take advantage of it and use something better than ls. 🤖💌
It’s easily installed on mac (
brew install exa) or linux (e.g. on fedora
sudo dnf install exa).
10 Jul 2020
One way to hide the contents of a file, e.g. one containing environment variables containing secrets, is to use gpg symmetric encryption, which meb7 ans encrypt and decrypt use the same secret. It is convenient, and you can supply the secret when you need it. 🤖
The encrypt command will create a file
vars.txt.gpg and if you list its contents you will see they are encrypted.
06 Jul 2020
You install zplug like this:
Enable and configure it in your
~/.zshrc using some of the examples provided:
liquidprompt, those are just copy-pasted from the docs. Then restart your terminal and answer the install prompts to install the plugins. Sweet zsh goodness. Thanks to Masaki Ishiyama for coding up a great system https://twitter.com/b4b4r07.
RC Logr 20200706 060711 - Trying a different zsh plugin …