Leave out subcommands with only one letter

This commit is contained in:
Jakob Schöttl 2019-01-12 19:59:04 +01:00 committed by Simon Michael
parent 43b3fb3cae
commit 13c4235730

View File

@ -9,7 +9,11 @@ main() {
cat > "$tmp"
sed -rn 's/^ ([-a-z]+).*/\1/gp' "$tmp"
sed -rn 's/^ .*\(([a-z]+)\).*/\1/gp' "$tmp"
# Do not output single letter commands, it's not useful.
sed -rn 's/^ .*\(([a-z]+)\).*/\1/gp' "$tmp" \
| grep -v ^.$
# TODO missing: (reg, r) (multiple aliases)
}