-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy path.packit.yaml
More file actions
48 lines (43 loc) · 1.63 KB
/
.packit.yaml
File metadata and controls
48 lines (43 loc) · 1.63 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
upstream_tag_template: v{version}
specfile_path: packaging/chunkah.spec
srpm_build_deps:
- cargo
- cargo-vendor-filterer
- git
- openssl-devel
- zlib-devel
actions:
# Packit defaults to `git describe` for the version, but for PRs that bump the
# Cargo.toml release, the versioned tarball that create-archive produces will
# not match what Packit expects. Always get the version from Cargo.toml.
get-current-version:
- bash -c 'cargo metadata --no-deps --format-version=1 | python3 -c "import json,sys; print(json.load(sys.stdin)[\"packages\"][0][\"version\"])"'
create-archive:
- tools/create-archives.sh --outdir packaging
# Packit only handles Source0 by default; we need to also rewrite Source1
# (the vendor tarball). Overriding this replaces all default behaviour, so
# we must handle Version, Release, and Source0 ourselves too.
fix-spec-file:
- >-
bash -c 'sed -i
-e "s/^Version:.*/Version: ${PACKIT_PROJECT_VERSION}/"
-e "s/^Release:.*/Release: ${PACKIT_RPMSPEC_RELEASE}%{?dist}/"
-e "s|^Source0:.*|Source0: ${PACKIT_PROJECT_ARCHIVE}|"
-e "s|^Source1:.*|Source1: chunkah-${PACKIT_PROJECT_VERSION}-vendor.tar.gz|"
packaging/chunkah.spec'
files_to_sync:
- src: packaging/chunkah.spec
dest: chunkah.spec
jobs:
# Build RPMs in COPR on every PR
- job: copr_build
trigger: pull_request
targets:
- fedora-latest-stable
- fedora-rawhide
# Propose updates to Fedora on release
- job: propose_downstream
trigger: release
dist_git_branches:
rawhide:
fast_forward_merge_into: [fedora-branched]