Lessons learned adding OpenTelemetry to a (Cobra) command-line Go tool (10 mins read).
Some reflections on what I've found good and not so good about instrumenting a command-line tool with OpenTelemetry.
Lessons learned adding OpenTelemetry to a (Cobra) command-line Go tool (10 mins read).
Some reflections on what I've found good and not so good about instrumenting a command-line tool with OpenTelemetry.
How I manage my dotfiles (8 mins read).
A deep dive into how managing my dotfiles has (not) evolved over the last 10 years.
Common issues faced with exec
ing an executable on Linux (2 mins read).
Some common issues you may face, with esoteric error messages, and how to fix them.
Making it easier to schedule cross-timezones, with the tz
CLI (3 mins read).
Writing a command-line tool with Charm's Go libraries to compare the suitability of meetings across timezones.
Pressing "enter" on an empty buffer displays an information-rich and pretty dashboard. - chrisgrieser/zsh-magic-dashboard
Creating a quick CLI in Go is easy, but here are some patterns you can use to make your CLI easier to extend in the future
Why am I getting Too many arguments
with vault
? (1 mins read).
Why you may be getting Too many arguments
from the vault
CLI, and how to fix it.
Why is set -eu
not working? (2 mins read).
Why you may be finding set -u
in a shell script not exiting when set -e
is also present.
A themeable LS_COLORS generator with a rich filetype datebase - GitHub - sharkdp/vivid: A themeable LS_COLORS generator with a rich filetype datebase
IDE style command line auto complete. Contribute to microsoft/inshellisense development by creating an account on GitHub.
pex makes piping easier. Contribute to josharian/pex development by creating an account on GitHub.
Linux Troubleshooting Interview DevOps SRE
Building resilient, runnable command-line demos with Asciinema and demo
(3 mins read).
How to use the demo
library alongside Asciinema to make it easier to build and maintain demos for your command-line tools.
Importing a subdirectory from one repo into another (1 mins read).
How to import a subdirectory of a given Git repository into another one, using git subtree
.
A super fast CLI tool to decode and encode JWTs built in Rust - GitHub - mike-engel/jwt-cli: A super fast CLI tool to decode and encode JWTs built in Rust
Turning on Caps Lock when the Caps Lock key is bound to a different key (1 mins read).
How to trigger a Caps Lock event when you've rebound the key to a differnet key.
Alex shares his insights from building half a dozen popular Go CLIs. Which can you apply to your projects?
Seth Michael Larson pointed out that the Python gzip module can be used as a CLI tool like this:
Introducing openapi-sorbet
, a command-line tool for generating Sorbet types from OpenAPI (2 mins read).
How to generate Sorbet type-checked models from OpenAPI specifications.
A simple, fast, and fun package for building command line apps in Go - GitHub - urfave/cli: A simple, fast, and fun package for building command line apps in Go
Go subcommand library. Contribute to google/subcommands development by creating an account on GitHub.
a little shell-based emoji picker. Contribute to biox/shmoji development by creating an account on GitHub.
Small tip: a delightful bash alias that helped me today alias '$'='' lets you copy tutorials that include '$' verbatim.swyx 🌴 (@swyx)Mon, 07 Feb 2022 16:19 GMT
A tool for glamorous shell scripts 🎀. Contribute to charmbracelet/gum development by creating an account on GitHub.
Weirdness with git diff-index
showing 1 file changed, 0 insertions(+), 0 deletions(-)
(1 mins read).
Something weird I hit last week with git diff-index
, which shows 1 file changed, but no changes.
Constructing a serialised YAML string in Ruby (1 mins read).
How to convert a YAML document to a string representation, preserving escaped newlines, with Ruby.
I have been a Vim user for 12 years and one important thing that you learn the first days using it is that you can be super efficient…
When should I use env
to start a command with environment variables? (2 mins read).
When you should use the env
command to specify environment variables when executing a command on the command-line (TL;DR: always).
Determining if there are uncommitted changes in Git (1 mins read).
A one-liner to work out whether there are uncommitted changes in a repository.
Building a fault-tolerant work queue for command-line executions with GNU Parallel (2 mins read).
How to use parallel
to create a lightweight work queue of commands, with retry logic and a record of what's been executed.
Removing 'smart' quotes from a file, on the command-line (2 mins read).
A one-liner with sed
to replace 'smart' quotes with regular quotes.
TIL MacOS has a built-in speed test tool.
Luke Holder (@lukeholder)Fri, 08 Apr 2022 01:39 +0000
TIL zgrep(1) is a shell script. BSD basically does “zcat | grep”, but GNU does “gzip -dc | sed”. How did I learn that? The fun way! CVE-2022-1271, arbitrary-file-write _and_ code execution vulnerability in GNU zgrep / gzip. openwall.com/lists/oss-secu…Jan Schaumann (@jschauma)Fri, 08 Apr 2022 13:30 +0000
I've recently been doing similar with some of my utilities, albeit with an informal comparison between Ruby and Go versions, but would agree that for large, production critical scrips, this is a great way to do it
Running a command on a visual selection in Vim (1 mins read).
How to pipe the text in a visual selection to a command, either to run it, or to replace the text in the seletion.
Converting Spring Boot Property Variables to Environment Variables with Go (1 mins read).
A command-line script to convert a Spring Boot property to an environment variable.
Pretty Printing JSON Web Tokens (JWTs) on the Command Line using Go (2 mins read).
How to easily introspect and pretty print a signed JWT (JWS) or an encrypted JWT (JWE) on the command line using Go.
Reading all of stdin
on the command-line with Go (1 mins read).
How to read the whole of stdin
, up to EOF, with Go.
Combining an Audio-only and Video-only MP4 with ffmpeg
on the command-line (1 mins read).
How to use ffmpeg
to combine two MP4 files, where each file contains audio and video separately.
there is a special place in hell for developers who give their cli’s -v flag a meaning other than version/verbose
Anna 🏳️⚧️ #blm (@addaleax)Wed, 16 Feb 2022 13:13 GMT
Bundling Multi-File OpenAPI Documents into a Single File (2 mins read).
Looking at the options we have for converting a multi-file OpenAPI specification to a single document.
Generating Favicons using ImageMagick on the Command-Line (1 mins read).
How to generate a multi-size favicon.ico
on the command-line using ImageMagick.
The fact that “grep” stands for global regex print, which is 4000x times easier to understand than trying to understand grep in abstract just neatly summarises the entire Linux ecosystem in a nutshell to me 😂
Lou ☁️ 👨💻🏋️♂️🎸🚴🏻♂️🏍 (@loujaybee)Sat, 05 Feb 2022 20:13 GMT
The worst crime the open source community ever committed was making two tools, one called 'useradd' and the other called 'adduser' and making them do almost the same thing.
🍃 f o r e s t ~ w i t c h 🌻 (@endlesstemple)Fri, 04 Feb 2022 05:16 GMT
You're currently viewing page 1 of 4, of 158 posts.