From 851fe4ca9fed86045d9849e68f84209482d8a42e Mon Sep 17 00:00:00 2001 From: merakor Date: Mon, 12 Apr 2021 12:00:57 +0000 Subject: cpt: fix --help output when inside a directory prefixed with cpt- FossilOrigin-Name: 83ae4a759534bb013b2b6c3db11874017869e70c7566f89dc6a86a0b2c4c6df3 --- src/cpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cpt b/src/cpt index 4ddb4df..50268ea 100755 --- a/src/cpt +++ b/src/cpt @@ -11,7 +11,7 @@ case "$arg" in log "Carbs Packaging Tool" set -- for path in $(SEARCH_PATH=$PATH pkg_find cpt-* all -x); do - set -- "${path#*/cpt-}" "$@" + set -- "${path##*/cpt-}" "$@" max=$((${#1} > max ? ${#1} : max)) done -- cgit v1.2.3