Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CI:BUILD] Packit: set propose-downstream action type to pre-sync #18687

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 3 additions & 5 deletions .packit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,9 @@ jobs:
update_release: false
dist_git_branches:
- fedora-all
#TODO use the right action to update the goimports
# For whatever reason, none of the actions seem to work
#actions:
# create-patches:
# - "cd rpm && bash update-spec-provides.sh"
actions:
pre-sync:
- "cd rpm && bash update-spec-provides.sh"

- job: koji_build
trigger: commit
Expand Down
2 changes: 1 addition & 1 deletion rpm/Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
.PHONY: rpm
rpm:
$(shell /usr/bin/bash ./update-spec-version.sh)
spectool -g podman.spec
sudo dnf -y builddep podman.spec
rpmbuild -ba \
--define '_sourcedir $(shell pwd)' \
--define '_rpmdir %{_sourcedir}/RPMS' \
Expand Down
2 changes: 0 additions & 2 deletions rpm/podman.spec
Original file line number Diff line number Diff line change
Expand Up @@ -154,8 +154,6 @@ Recommends: %{name}-gvproxy = %{epoch}:%{version}-%{release}
Provides: %{name}-quadlet
Obsoletes: %{name}-quadlet <= 5:4.4.0-1
Provides: %{name}-quadlet = %{epoch}:%{version}-%{release}
# TODO: need to find the right action in packit propose-downstream to update
# the goimports here. None of the actions seem to work so far.
# DO NOT DELETE BELOW LINE - used for updating downstream goimports
# vendored libraries

Expand Down
2 changes: 2 additions & 0 deletions rpm/update-spec-provides.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
# packaging, via the `propose-downstream` packit action.
# The goimports don't need to be present upstream.

set -e

SPEC_FILE=$(pwd)/podman.spec

sed -i '/Provides: bundled(golang.*/d' $SPEC_FILE
Expand Down
2 changes: 2 additions & 0 deletions rpm/update-spec-version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
# default. Useful for local manual rpm builds where the Version needs to be set
# correctly.

set -e

SPEC_FILE=$(pwd)/podman.spec
LATEST_TAG=$(git tag --sort=creatordate | tail -1)
LATEST_VERSION=$(echo $LATEST_TAG | sed -e 's/^v//')
Expand Down