# Script Metadata
scriptName="bklog"; # Define basename of script file.
-scriptVersion="0.1.29"; # Define version of script.
-scriptURL="https://gitlab.com/baltakatei/ninfacyzga-01"; # Define wesite hosting this script.
+scriptVersion="0.1.30"; # Define version of script.
+scriptURL="https://gitlab.com/baltakatei/ninfacyzga-01"; # Define website hosting this script.
scriptTimeStartEpoch="$(date +%s)"; # Save start time of script in epoch seconds
scriptTimeStart="$(date +%Y%m%dT%H%M%S.%N)"; # YYYYmmddTHHMMSS.NNNNNNNNN
scriptHostname=$(hostname); # Save hostname of system running this script.
fi;
vbm "STATUS:$fn:Finished magicSetScriptTTL() function.";
} # Set scriptTTL in seconds until next (day|hour).
+magicVerboseReadout() {
+ vbm "$bufferTTL"; # Time-to-live (seconds) for each buffer round
+ vbm "$scriptTTL_TE"; # Time element at the end of which script terminates
+ vbm "$dirTmpDefault"; # Default parent of working directory
+ # Script Metadata
+ vbm "$scriptName"; # Basename of script file.
+ vbm "$scriptVersion"; # Version of script.
+ vbm "$scriptURL"; # Website hosting this script.
+ vbm "$scriptTimeStartEpoch"; # Start time of script in epoch seconds
+ vbm "$scriptTimeStart"; # YYYYmmddTHHMMSS.NNNNNNNNN
+ vbm "$scriptHostname" # Hostname of system running this script.
+ vbm "$PATH"; # PATH env. var.
+ vbm "$ageVersion"; # Version of age (encryption program)
+ vbm "$ageURL"; # Website hosting age.
+} # Display script variables
magicWriteVersion() {
# Desc: Appends time-stamped VERSION to pathout_tar
# Usage: magicWriteVersion
magicParseProcessStrings; # Sets arrays: procStrings, procFileExts
## React to "-l" (output file label) option
magicParseLabel; # sets label (ex: "_location")
+ ## React to "-v" (verbose) option
+ magicVerboseReadout; # Display various script variables
# Perform secondary setup operations
## Set script lifespan (scriptTTL from scriptTTL_TE)
done;
# Mark time for buffer
## Initial time
- if [[ ! -z "$timeBufferEndEpoch" ]]; then
+ if [[ bufferRound -gt 0 ]]; then
### Usual case
timeBufferStartEpoch="$timeBufferEndEpoch" && vbm "DEBUG :$fn:timeBufferStartEpoch:$timeBufferStartEpoch";
- else
+ elif [[ bufferRound -eq 0 ]]; then
### Edge case: initial startup
timeBufferStartEpoch="$scriptTimeStartEpoch" && vbm "DEBUG :$fn:timeBufferStartEpoch:$timeBufferStartEpoch";
+ else
+ yell "ERROR:$fn:Invalid bufferRound value."; exit 1;
fi;
## End Time
timeBufferEndEpoch="$(date +%s)" && vbm "DEBUG :$fn:timeBufferEndEpoch:$timeBufferEndEpoch";