Watch
1
0
Fork
You've already forked dotfiles
0

bin: carg

This commit is contained in:
Jeremy Kaplan 2026-06-04 09:42:25 -04:00
commit e072fa3b77

16
bin/carg Executable file
View file

@ -0,0 +1,16 @@
#!/usr/bin/env bash
# This program should be installed as `carg`. It fixes typos like
#
# carg oc -> cargo c
# carg obuild -> cargo build
#
# It unconditionally removes one leading `o` from its first argument and then
# runs the corrected `cargo` subcommand with the rest of the arguments.
set -euo pipefail
sub="$1"; shift;
sub="${sub#o}"
exec cargo "$sub" "$@"