dbginfo.sh: dash compatible copy sequence

rewrite the copy of dbginfo.sh for dash compatibility

Reviewed-by: Mike Storzer <MSTORZER@de.ibm.com>
Reviewed-by: Mario Held <mario.held@de.ibm.com>
Signed-off-by: Joern Siglen <siglen@de.ibm.com>
Signed-off-by: Steffen Eiden <seiden@linux.ibm.com>
This commit is contained in:
Joern Siglen
2024-03-12 11:34:37 +01:00
committed by Steffen Eiden
parent a3199d58db
commit 1c128c0d11
2 changed files with 4 additions and 4 deletions

View File

@@ -10,6 +10,7 @@ Release history for s390-tools (MIT version)
Changes of existing tools:
Bug Fixes:
- dbginfo.sh: dash compatible copy sequence
* __v2.31.0 (2024-02-02)__

View File

@@ -15,7 +15,7 @@ export LC_ALL
########################################
# Global used variables
readonly SCRIPTNAME="${0##*/}" # general name of this script
readonly STARTDIR="$(pwd)" # save calling directory
readonly FULLPATHSCRIPT="$(readlink -f "${0}")"
#
readonly DATETIME="$(date +%Y-%m-%d-%H-%M-%S 2>/dev/null)"
readonly DOCKER=$(if type docker >/dev/null 2>&1; then echo "YES"; else echo "NO"; fi)
@@ -1420,9 +1420,8 @@ environment_setup() {
create_package() {
local rc_tar
pr_syslog_stdout ${step_num} "Finalizing: Creating archive with collected data"
# get a copy of the script used - enabled for relative path calls
cd "${STARTDIR}"
cp -p "${BASH_SOURCE[0]}" "${WORKPATH}"
# get a copy of the script used
cp -p "${FULLPATHSCRIPT}" "${WORKPATH}"
# create the archive
cd "${WORKDIR_BASE}"
touch "${WORKARCHIVE}"