1
0
mirror of synced 2026-01-25 20:06:44 +00:00

Some polish on the new loadup scripts - dribble files and lock overrides (#2157)

Three changes to loadup scripts:

1) dribble files are now copied from the workdir into loadups if loadup completes successfully, 

2) if the lock preventing simultaneous runs is already set when loadup starts, it now asks the user if they want to override the lock or to exit (previously it just exited), 

3) there is now a --override flag that will automatically override the lock without asking the user.  

Man page updated accordingly.
This commit is contained in:
Frank Halasz
2025-05-19 09:48:39 -07:00
committed by GitHub
parent 2499b3546e
commit 330c5a01a7
6 changed files with 84 additions and 21 deletions

View File

@@ -17,6 +17,7 @@ main() {
nocopy=false
thinw=false
thinl=false
override_lock=false
while [ "$#" -ne 0 ];
do
case "$1" in
@@ -144,6 +145,9 @@ main() {
export MAIKODIR="${maikodir}"
shift
;;
-ov | -override | --override)
override_lock=true
;;
--noendmsg)
noendmsg=true
;;
@@ -251,7 +255,7 @@ main() {
# check and set the run_lock
check_run_lock
check_run_lock "${override_lock}"
# if requested, thin the loadups and workdirs by eliminating all versioned (*.~[0-9]*~) files
# from these directories
@@ -348,18 +352,24 @@ main() {
then
/bin/sh "${LOADUP_CPV}" "${LOADUP_WORKDIR}"/lisp.sysout "${LOADUP_OUTDIR}" \
| sed -e "s#${MEDLEYDIR}/##g"
/bin/sh "${LOADUP_CPV}" "${LOADUP_WORKDIR}"/lisp.dribble "${LOADUP_OUTDIR}" \
| sed -e "s#${MEDLEYDIR}/##g"
fi
if [ $start -le 3 ] && [ $end -ge 4 ]
then
/bin/sh "${LOADUP_CPV}" "${LOADUP_WORKDIR}"/full.sysout "${LOADUP_OUTDIR}" \
| sed -e "s#${MEDLEYDIR}/##g"
/bin/sh "${LOADUP_CPV}" "${LOADUP_WORKDIR}"/full.dribble "${LOADUP_OUTDIR}" \
| sed -e "s#${MEDLEYDIR}/##g"
fi
if [ $start -le 4 ] && [ $end -ge 5 ]
then
/bin/sh "${LOADUP_CPV}" "${LOADUP_WORKDIR}"/apps.sysout "${LOADUP_OUTDIR}" \
| sed -e "s#${MEDLEYDIR}/##g"
/bin/sh "${LOADUP_CPV}" "${LOADUP_WORKDIR}"/apps.dribble "${LOADUP_OUTDIR}" \
| sed -e "s#${MEDLEYDIR}/##g"
fi
if [ "${aux}" = true ]
@@ -368,12 +378,18 @@ main() {
| sed -e "s#${MEDLEYDIR}/##g"
/bin/sh "${LOADUP_CPV}" "${LOADUP_WORKDIR}"/exports.all "${LOADUP_OUTDIR}" \
| sed -e "s#${MEDLEYDIR}/##g"
/bin/sh "${LOADUP_CPV}" "${LOADUP_WORKDIR}"/whereis.dribble "${LOADUP_OUTDIR}" \
| sed -e "s#${MEDLEYDIR}/##g"
/bin/sh "${LOADUP_CPV}" "${LOADUP_WORKDIR}"/exports.dribble "${LOADUP_OUTDIR}" \
| sed -e "s#${MEDLEYDIR}/##g"
fi
if [ "${db}" = true ]
then
/bin/sh "${LOADUP_CPV}" "${LOADUP_WORKDIR}"/fuller.database "${LOADUP_OUTDIR}" \
| sed -e "s#${MEDLEYDIR}/##g"
/bin/sh "${LOADUP_CPV}" "${LOADUP_WORKDIR}"/fuller.dribble "${LOADUP_OUTDIR}" \
| sed -e "s#${MEDLEYDIR}/##g"
fi
fi