Skip to content

Commit

Permalink
Add Packit config (#20)
Browse files Browse the repository at this point in the history
  • Loading branch information
ekohl authored Aug 14, 2024
1 parent 3872537 commit 6244cbf
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 0 deletions.
33 changes: 33 additions & 0 deletions .packit.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# See the documentation for more information:
# https://packit.dev/docs/configuration/

specfile_path: foreman_ygg_worker.spec

# add or remove files that should be synced
files_to_sync:
- foreman_ygg_worker.spec
- .packit.yml

# name in upstream package repository or registry (e.g. in PyPI)
upstream_package_name: foreman_ygg_worker
# downstream (Fedora) RPM package name
downstream_package_name: foreman_ygg_worker

actions:
post-upstream-clone:
- "wget https://raw.githubusercontent.com/theforeman/foreman-packaging/rpm/develop/packages/client/foreman_ygg_worker/foreman_ygg_worker.spec -O foreman_ygg_worker.spec"
get-current-version: "awk '/VERSION :=/ { print $3 }' Makefile"
create-archive: make distribution-tarball

jobs:
- job: copr_build
trigger: pull_request
targets:
- rhel-9
- rhel-8
- epel-7

srpm_build_deps:
- golang
- make
- wget
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,11 @@ distribution-tarball:
--exclude=.github \
--exclude=.gitignore \
--exclude=.copr \
--exclude=.packit.yml \
--transform s/^\./$(PKGNAME)-$(VERSION)/ \
. && mv /tmp/$(PKGNAME)-$(VERSION).tar.gz .
rm -rf ./vendor
@echo $(PKGNAME)-$(VERSION).tar.gz

test:
go test src/*
Expand Down

0 comments on commit 6244cbf

Please sign in to comment.