onboard packit

This commit is contained in:
Filip Janus 2025-04-03 07:17:51 +00:00
commit d77bc28faf
2 changed files with 27 additions and 0 deletions

8
packit-update-sources.sh Executable file
View file

@ -0,0 +1,8 @@
git clone --depth 1 --branch master https://github.com/postgres/postgres.git
pushd postgres
git fetch --tags
NEW_MINOR=$(git tag -l "REL_16_*" | sed -E "s/REL_16_([0-9]+)/\1/" | sort -n | tail -n 1)
popd
pushd $PACKIT_DOWNSTREAM_REPO
sed -i "s/\(%global prevversion %{prevmajorversion}\)\.[0-9]\+/\1.$NEW_MINOR/" $PACKIT_DOWNSTREAM_PACKAGE_NAME.spec
popd

19
packit.yaml Normal file
View file

@ -0,0 +1,19 @@
# See the documentation for more information:
# https://packit.dev/docs/configuration/
actions:
pre-sync:
- bash -c "$PACKIT_DOWNSTREAM_REPO/packit-update-sources.sh"
jobs:
- job: pull_from_upstream
trigger: release
dist_git_branches:
- fedora-all
- job: koji_build
trigger: commit
dist_git_branches:
- fedora-all
- job: bodhi_update
trigger: commit
dist_git_branches:
fedora-all