From 59b6046684dd405f60d2a164b93ba9c50f5e80c4 Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Tue, 23 Aug 2016 20:33:49 +1200 Subject: Fully expand FUNCNAME --- bash/bashrc.d/keep.bash | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'bash/bashrc.d/keep.bash') diff --git a/bash/bashrc.d/keep.bash b/bash/bashrc.d/keep.bash index fb4b8bde..8f6a6fdb 100644 --- a/bash/bashrc.d/keep.bash +++ b/bash/bashrc.d/keep.bash @@ -46,18 +46,18 @@ keep() { # -h given; means show help h) cat <&2 + "${FUNCNAME[0]}" "$opt" >&2 return 2 ;; esac @@ -92,7 +92,7 @@ EOF # characters besides letters, numbers, or underscores *[^a-zA-Z0-9_]*|[^a-zA-Z_]*) printf 'bash: %s: %s not a valid NAME\n' \ - "$FUNCNAME" "$name" >&2 + "${FUNCNAME[0]}" "$name" >&2 ((errors++)) ;; @@ -126,7 +126,7 @@ EOF # Deleting is an error, since we need at least one argument if ((delete)) ; then printf 'bash: %s: must specify at least one NAME to delete\n' - "$FUNCNAME" >&2 + "${FUNCNAME[0]}" >&2 return 2 fi -- cgit v1.2.3