Skip to content

Commit

Permalink
Merge pull request #18 from r0x0d/package-as-copr-build
Browse files Browse the repository at this point in the history
Package as copr build
  • Loading branch information
r0x0d authored Jun 14, 2023
2 parents 47669b1 + 084f7fe commit 932dce6
Show file tree
Hide file tree
Showing 6 changed files with 762 additions and 54 deletions.
33 changes: 22 additions & 11 deletions .packit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,31 +3,42 @@ upstream_package_name: rhc-bash-worker
downstream_package_name: rhc-bash-worker
upstream_project_url: https://github.com/oamg/rhc-bash-worker

srpm_build_deps: []
srpm_build_deps: [golang, make]


jobs:
- job: copr_build
trigger: pull_request
enable_net: true
owner: "@oamg"
project: rhc-bash-worker
project: "rhc-bash-worker"
targets:
- epel-7-x86_64
- epel-7-x86_64
trigger: pull_request
actions:
# do not get the version from a tag (git describe) but from the spec file
get-current-version:
- grep -oP '^Version:\s+\K\S+' packaging/rhc-bash-worker.spec
- grep -oP '^Version:\s+\K\S+' packaging/rhc-bash-worker.spec
create-archive:
- "make distribution-tarball"
- bash -c "ls -1 ./rhc-bash-worker-*.tar.gz"

- job: copr_build
trigger: commit
branch: main
enable_net: true
owner: "@oamg"
project: rhc-bash-worker
project: "rhc-bash-worker"
targets:
- epel-7-x86_64
- epel-7-x86_64
trigger: commit
branch: main
actions:
# bump spec so we get release starting with 2 and hence all the default branch builds will
# have higher NVR than all the PR builds
post-upstream-clone:
- rpmdev-bumpspec --comment='latest upstream build' ./packaging/rhc-bash-worker.spec
- rpmdev-bumpspec --comment='latest upstream build' ./packaging/rhc-bash-worker.spec

# do not get the version from a tag (git describe) but from the spec file
get-current-version:
- grep -oP '^Version:\s+\K\S+' packaging/rhc-bash-worker.spec
- grep -oP '^Version:\s+\K\S+' packaging/rhc-bash-worker.spec
create-archive:
- "make distribution-tarball"
- bash -c "ls -1 ./rhc-bash-worker-*.tar.gz"
3 changes: 3 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Contributing

WIP
Loading

0 comments on commit 932dce6

Please sign in to comment.