/usr/local/jetapps/usr/share/rear/lib
# some array functions # return whether $1 equals one of the remaining arguments function IsInArray() { { local needle="$1" test -z "$needle" && return 1 while shift ; do # at the end $1 becomes an unbound variable (after all arguments were shifted) # so that an empty default value is used to avoid 'set -eu' error exit # and that empty default value cannot match because needle is non-empty: test "$needle" == "${1:-}" && return 0 done } 2>>/dev/$DISPENSABLE_OUTPUT_DEV return 1 } function RmInArray() { # "$1" string to be removed in array "${2[@]}" # please note that the array elements are a bunch of words in this function # usage: BACKUP_RSYNC_OPTIONS=( $( RmInArray "--relative" "${BACKUP_RSYNC_OPTIONS[@]}" ) ) { local needle="$1" declare -a nArray # we will build a new array while shift ; do if [[ "$needle" != "$1" ]] ; then nArray+=( "$1" ) fi done } 2>>/dev/$DISPENSABLE_OUTPUT_DEV # we return the array as a string echo "${nArray[@]}" }
.
Edit
..
Edit
.shellcheckrc
Edit
_input-output-functions.sh
Edit
array-functions.sh
Edit
authtoken-functions.sh
Edit
bareos-functions.sh
Edit
bootloader-functions.sh
Edit
borg-functions.sh
Edit
checklayout-workflow.sh
Edit
columns-functions.sh
Edit
config-functions.sh
Edit
drlm-functions.sh
Edit
dump-workflow.sh
Edit
filesystems-functions.sh
Edit
finalizeonly-workflow.sh
Edit
format-workflow.sh
Edit
framework-functions.sh
Edit
global-functions.sh
Edit
help-workflow.sh
Edit
hp_raid-functions.sh
Edit
layout-functions.sh
Edit
layoutonly-workflow.sh
Edit
linux-functions.sh
Edit
mail-functions.sh
Edit
mkbackup-workflow.sh
Edit
mkbackuponly-workflow.sh
Edit
mkboot-workflow.sh
Edit
mkopalpba-workflow.sh
Edit
mkrescue-functions.sh
Edit
mkrescue-workflow.sh
Edit
mountonly-workflow.sh
Edit
network-functions.sh
Edit
opal-functions.sh
Edit
opaladmin-workflow.sh
Edit
output-functions.sh
Edit
progresssubsystem.nosh
Edit
rear-shell.bashrc
Edit
recover-workflow.sh
Edit
restoreonly-workflow.sh
Edit
rsync-functions.sh
Edit
savelayout-workflow.sh
Edit
serial-functions.sh
Edit
sesam-functions.sh
Edit
shell-workflow.sh
Edit
udev-workflow.sh
Edit
uefi-functions.sh
Edit
validate-workflow.sh
Edit
validated
Edit
write-protect-functions.sh
Edit