pmaports/main/devicepkg-utils/source_deviceinfo
Clayton Craft ce67c46bd4
main/devicepkg-utils: initialize SOURCE_DEVICEINFO_ROOT
Otherwise things that `set -u` (like boot-deploy) fail

[ci:skip-build]: already built successfully in CI

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7028>
2025-09-10 09:18:57 -07:00

7 lines
465 B
Text

# These scripts must be sourced (not executed) to work properly
# shellcheck disable=SC1091
SOURCE_DEVICEINFO_ROOT="${SOURCE_DEVICEINFO_ROOT:-}"
[ -f "$SOURCE_DEVICEINFO_ROOT/usr/share/deviceinfo/deviceinfo" ] && . "$SOURCE_DEVICEINFO_ROOT/usr/share/deviceinfo/deviceinfo"
[ -f "$SOURCE_DEVICEINFO_ROOT/etc/deviceinfo" ] && . "$SOURCE_DEVICEINFO_ROOT/etc/deviceinfo"
[ -z "$deviceinfo_arch" ] && { echo "$0: ERROR: deviceinfo file is missing!!"; exit 1; } || true