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

Refactor rpm packaging #125

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft
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
31 changes: 20 additions & 11 deletions .packit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,9 @@
specfile_path: dist/subprocess-tee.spec
actions:
create-archive:
- sh -c "rm dist/*.tar.gz >/dev/null || true"
- python3 -m build --sdist --outdir dist
- sh -c "ls dist/subprocess-tee-*.tar.gz"
- sh -c "ls dist/subprocess_tee-*.tar.gz"
get-current-version:
- python3 -m setuptools_scm --strip-dev
post-upstream-clone:
Expand All @@ -17,21 +18,29 @@ actions:
srpm_build_deps:
- python3-build
- python3-setuptools_scm
- python3-pytest
jobs:
- job: copr_build
trigger: pull_request
branch: main
targets:
# See https://packit.dev/docs/configuration/#aliases
# API to get available targets: https://api.dev.testing-farm.io/v0.1/composes/public
# Fedora 37 is the first version having a setuptools(-scm) that supports our PEP-621 metadata
- fedora-37
- fedora-rawhide
- fedora-rawhide-x86_64
- fedora-rawhide-aarch64
- fedora-latest-x86_64
- fedora-latest-aarch64
# Missing python3-build see https://bugzilla.redhat.com/show_bug.cgi?id=2129071
# - centos-stream-9-aarch64
# - centos-stream-9-x86_64
- job: tests
trigger: pull_request
# - job: tests
# trigger: pull_request
# metadata:
# targets:
# - fedora-all
branch: main
targets:
- fedora-latest
- fedora-rawhide
# - job: propose_downstream
# trigger: release
# metadata:
# dist-git-branch: master
notifications:
pull_request:
successful_build: false
9 changes: 9 additions & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -76,3 +76,12 @@ commands =
{toxinidir}
# metadata validation
python -m twine check --strict {toxinidir}/dist/*

[testenv:rpm]
description = Use packit to build RPM (requires RPM based Linux distro)
deps =
build
packitos
setuptools-scm
commands =
sh -c "packit build in-mock --root=fedora-40-$(arch)"