Revision 13277
Added by Aaron Marcuse-Kubitza over 10 years ago
trunk/lib/sh/util.sh | ||
---|---|---|
709 | 709 |
|
710 | 710 |
# makes $1 a canon_rel_path if it's a filesystem path |
711 | 711 |
alias cmd2rel_path="$(cat <<'EOF' |
712 |
if test "$(type -t "$1")" = file && test -e "$1"; then # not relative to PATH
|
|
712 |
if is_extern "$1" && test -e "$1"; then # not relative to PATH
|
|
713 | 713 |
declare _1="$1"; shift |
714 | 714 |
_1="$(log++ canon_rel_path "$_1")" || return |
715 | 715 |
set -- "$_1" "$@" |
Also available in: Unified diff
lib/sh/util.sh: cmd2rel_path: use is_extern()