fix: generate RPM Specs for Qubes Builder V2

It doesn't checkout the current directory when querying the spec, so we
provide the already modified version of the spec.
This commit is contained in:
Ben Grande 2024-06-21 17:00:06 +02:00
parent 7aee0c44d8
commit c84dfea48e
No known key found for this signature in database
GPG key ID: 00C64E14F51F9E56
108 changed files with 7181 additions and 58 deletions

View file

@ -53,15 +53,14 @@ if test "${key}" = "branch"; then
branch="$(git branch --show-current)"
fi
group="qusal"
toplevel="$(git rev-parse --show-toplevel)"
group="${toplevel##*/}"
block_max_chars group "${group}" 70
file_roots="/srv/salt/${group}"
vendor="${QUSAL_VENDOR:-"Benjamin Grande"}"
packager="${QUSAL_PACKAGER:-"Benjamin Grande"}"
url="${QUSAL_URL:-"https://github.com/ben-grande/qusal"}"
bug_url="${QUSAL_BUGURL:-"https://github.com/ben-grande/qusal/issues"}"
# shellcheck disable=SC2094
read -r version <version
vendor="${SPEC_VENDOR:-"$(git config --get user.name)"}"
packager="${SPEC_PACKAGER:-"${vendor}"}"
url="${SPEC_URL:-"https://github.com/ben-grande/qusal"}"
bug_url="${SPEC_BUGURL:-"${url}/issues"}"
project="${group}-${name}"
project_dir="salt/${name}"
@ -71,6 +70,8 @@ if ! test -d "${project_dir}"; then
exit 1
fi
# shellcheck disable=SC2094
read -r version <"${project_dir}/version"
readme="${project_dir}/README.md"
if ! test -f "${readme}"; then
echo "Project ${name} does not have README.md" >&2