diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 18:24:48 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 18:24:48 +0000 |
commit | cca66b9ec4e494c1d919bff0f71a820d8afab1fa (patch) | |
tree | 146f39ded1c938019e1ed42d30923c2ac9e86789 /packaging/macos/jhb/etc/jhb.conf.sh | |
parent | Initial commit. (diff) | |
download | inkscape-upstream/1.2.2.tar.xz inkscape-upstream/1.2.2.zip |
Adding upstream version 1.2.2.upstream/1.2.2upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'packaging/macos/jhb/etc/jhb.conf.sh')
-rw-r--r-- | packaging/macos/jhb/etc/jhb.conf.sh | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/packaging/macos/jhb/etc/jhb.conf.sh b/packaging/macos/jhb/etc/jhb.conf.sh new file mode 100644 index 0000000..398e9d3 --- /dev/null +++ b/packaging/macos/jhb/etc/jhb.conf.sh @@ -0,0 +1,53 @@ +# SPDX-FileCopyrightText: 2022 René de Hesselle <dehesselle@web.de> +# +# SPDX-License-Identifier: GPL-2.0-or-later + +### description ################################################################ + +# This is a convenience wrapper to source all individual configuration files. +# It also takes care of placing a custom configuration file in the appropriate +# location. + +### shellcheck ################################################################# + +# shellcheck shell=bash # no shebang as this file is intended to be sourced + +### dependencies ############################################################### + +SELF_DIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" || exit 1; pwd) + +CUSTOM_CONFIG=$SELF_DIR/jhb-custom.conf.sh +# copy a custom configuration file to the appropriate place +if [[ $1 == *.conf.sh ]] && [ -f "$1" ]; then + cp "$1" "$CUSTOM_CONFIG" +fi + +# source a custom configuration file if present +if [ -f "$CUSTOM_CONFIG" ]; then + # shellcheck disable=SC1090 # file is optional + source "$CUSTOM_CONFIG" +fi +unset CUSTOM_CONFIG + +# source items from jhb.conf directory +for CONFIG_ITEM in $(\ + "$SELF_DIR"/../usr/bin/run-parts list "$SELF_DIR"/jhb.conf/'*.sh' \ + ); do + # shellcheck disable=SC1090 # can't point to a single source here + source "$CONFIG_ITEM" +done +unset CONFIG_ITEM + +unset SELF_DIR + +### variables ################################################################## + +# Nothing here. + +### functions ################################################################## + +# Nothing here. + +### main ####################################################################### + +# Nothing here. |