armbian-build/lib/tools/gen-library.sh
Igor Pecovnik 4d60ce08f2 chore: update copyright years to 2026
Update all copyright notices in shell scripts from 2025 to 2026.

## Changes

- **Igor Pecovnik**: 2013-2025 → 2013-2026 (129 files)
- **Ricardo Pardini**: 2023-2025 → 2023-2026, 2020-2025 → 2020-2026 (5 files)

## Additional Improvements

Also updated the backtitle in `lib/functions/configuration/interactive.sh`:
- Changed title from "Armbian building script" to "Armbian Linux build framework"
- Removed docs link for cleaner display
- Uses dynamic year calculation with separate declaration (fixes shellcheck SC2155)
2025-12-25 12:03:34 +01:00

54 lines
1.7 KiB
Bash
Executable File

#!/usr/bin/env bash
#
# SPDX-License-Identifier: GPL-2.0
#
# Copyright (c) 2013-2026 Igor Pecovnik, igor@armbian.com
#
# This file is a part of the Armbian Build Framework
# https://github.com/armbian/build/
set -e
SRC="$(
cd "$(dirname "$0")/../.."
pwd -P
)"
echo "SRC: ${SRC}"
TARGET_SH="${SRC}/lib/library-functions.sh"
echo "Writing ${TARGET_SH}"
cat <<- AUTOGEN_INCLUDES_HEADER > "${TARGET_SH}"
#!/usr/bin/env bash
# This file is/was autogenerated by ${0}; don't modify manually
AUTOGEN_INCLUDES_HEADER
cd "${SRC}"
find lib/functions -type f -name \*.sh | sort -h | while read -r path; do
ref="$(echo -n "${path}")"
cat <<- AUTOGEN_INCLUDES_EACH >> "${TARGET_SH}"
# no errors tolerated. invoked before each sourced file to make sure.
#set -o pipefail # trace ERR through pipes - will be enabled "soon"
#set -o nounset ## set -u : exit the script if you try to use an uninitialised variable - one day will be enabled
set -o errtrace # trace ERR through - enabled
set -o errexit ## set -e : exit the script if any statement returns a non-true return value - enabled
### ${path}
# shellcheck source=${ref}
source "\${SRC}"/${path}
AUTOGEN_INCLUDES_EACH
done
cat <<- AUTOGEN_INCLUDES_FOOTER >> "${TARGET_SH}"
# no errors tolerated. one last time for the win!
#set -o pipefail # trace ERR through pipes - will be enabled "soon"
#set -o nounset ## set -u : exit the script if you try to use an uninitialised variable - one day will be enabled
set -o errtrace # trace ERR through - enabled
set -o errexit ## set -e : exit the script if any statement returns a non-true return value - enabled
# This file is/was autogenerated by ${0}; don't modify manually
AUTOGEN_INCLUDES_FOOTER
echo "done."