10 May
2023
10 May
'23
11:46
Carlos E. R. wrote:
preremove /usr/local/bin/archive_logfile.sh /var/log/testfile endscript } -------------------
It is not what you wish, but would do.
You are close, but no, it would not be called with the right arguments. There are two calls - 1) as above 2) with the oldest compressed archive
Even I understand you can do:
[snip]
preremove test -n "$1" || exit 75
log="$1" plus the rest endscript
Yes, that variant I hadn't thought of, but I also definitely want to avoid. -- Per Jessen, Zürich (16.5°C) Member, openSUSE Heroes (2016 - present) We're hiring - https://en.opensuse.org/openSUSE:Heroes