OSDN Git Service

[update] : msgsh fullpath
authorhayao <hayao@fascode.net>
Tue, 6 Apr 2021 12:42:29 +0000 (21:42 +0900)
committerhayao <hayao@fascode.net>
Tue, 6 Apr 2021 12:42:29 +0000 (21:42 +0900)
tools/msg.sh

index db40fb4..198404d 100755 (executable)
@@ -4,6 +4,8 @@ set -eu
 
 script_path="$( cd -P "$( dirname "$(readlink -f "$0")" )" && cd .. && pwd )"
 
+msgsh="$( cd -P "$( dirname "$(readlink -f "$0")" )" && pwd )/$(basename "${0}")"
+
 msg_type="info"
 echo_opts=()
 bash_debug=false
@@ -98,7 +100,7 @@ text() {
 
 # Message functions
 msg_error() {
-    bash "${script_path}/tools/msg.sh" -a "msg.sh" error "${1}"
+    bash "${msgsh}" -a "msg.sh" error "${1}"
 }
 
 # Check color