-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bring back Python >= 3.6 and EL 8 support (#256)
Bring back Python >= 3.6 and EL 8 support Fixes #255. RELEASE NOTES BEGIN specfile now once again supports EPEL 8 and Python 3.6. RELEASE NOTES END Reviewed-by: Tomas Tomecek <[email protected]> Reviewed-by: Jiri Popelka Reviewed-by: František Lachman <[email protected]>
- Loading branch information
Showing
21 changed files
with
319 additions
and
64 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,111 +1,174 @@ | ||
--- | ||
# We want to use both instances for all upstream jobs including the `propose-downstream` one. | ||
# For downstream, we need to pick just one instance (`stg` in our case) | ||
# and redefine it for the `koji_build` and `bodhi_update` jobs. | ||
packit_instances: ["prod", "stg"] | ||
|
||
specfile_path: fedora/python-specfile.spec | ||
|
||
# add or remove files that should be synced | ||
files_to_sync: | ||
- fedora/python-specfile.spec | ||
- .packit.yaml | ||
- src: plans/ | ||
dest: plans/ | ||
- src: .fmf/ | ||
dest: .fmf/ | ||
|
||
# name in upstream package repository or registry (e.g. in PyPI) | ||
upstream_package_name: specfile | ||
# downstream (Fedora) RPM package name | ||
downstream_package_name: python-specfile | ||
|
||
copy_upstream_release_description: true | ||
|
||
upstream_project_url: https://github.com/packit/specfile | ||
issue_repository: https://github.com/packit/specfile | ||
|
||
copy_upstream_release_description: true | ||
|
||
actions: | ||
# we need this b/c `git archive` doesn't put all the metadata in the tarball: | ||
# LookupError: setuptools-scm was unable to detect version for '/builddir/build/BUILD/ogr-0.11.1'. | ||
# Make sure you're either building from a fully intact git repository or PyPI tarballs. | ||
create-archive: | ||
- python3 -m build --sdist --outdir ./fedora/ | ||
- bash -c "ls -1t ./fedora/*.tar.gz | head -n 1" | ||
get-current-version: python3 -m setuptools_scm | ||
pre-sync: | ||
# FMF has to be installed on system where you are calling this tool. | ||
- python3 plans/git_reference.py | ||
|
||
srpm_build_deps: | ||
- python3-build | ||
- python3-setuptools_scm | ||
packages: | ||
specfile: | ||
specfile_path: &specfile_path fedora/python-specfile.spec | ||
files_to_sync: | ||
- *specfile_path | ||
- .packit.yaml | ||
- src: plans/ | ||
dest: plans/ | ||
- src: .fmf/ | ||
dest: .fmf/ | ||
srpm_build_deps: | ||
- python3-build | ||
- python3-setuptools_scm | ||
actions: | ||
create-archive: | ||
- python3 -m build --sdist --outdir ./fedora/ | ||
- bash -c "ls -1t ./fedora/*.tar.gz | head -n 1" | ||
get-current-version: python3 -m setuptools_scm | ||
|
||
jobs: | ||
- job: propose_downstream | ||
trigger: release | ||
dist_git_branches: | ||
- fedora-all | ||
- epel-9 | ||
specfile-epel8: | ||
specfile_path: &specfile_path_epel8 epel8/python-specfile.spec | ||
files_to_sync: | ||
- *specfile_path_epel8 | ||
- .packit.yaml | ||
- src: plans/ | ||
dest: plans/ | ||
- src: .fmf/ | ||
dest: .fmf/ | ||
srpm_build_deps: | ||
- python3-setuptools_scm | ||
actions: | ||
create-archive: | ||
- python3 setup.py sdist --dist-dir ./epel8/ | ||
- bash -c "ls -1t ./epel8/*.tar.gz | head -n 1" | ||
get-current-version: python3 setup.py --version | ||
|
||
jobs: | ||
- job: copr_build | ||
trigger: pull_request | ||
packages: [specfile] | ||
targets: | ||
- fedora-all | ||
- epel-9 | ||
|
||
- job: tests | ||
- job: copr_build | ||
trigger: pull_request | ||
packages: [specfile-epel8] | ||
targets: | ||
- fedora-all | ||
- epel-9 | ||
- epel-8 | ||
|
||
- job: copr_build | ||
trigger: commit | ||
branch: main | ||
packages: [specfile] | ||
targets: | ||
- fedora-all | ||
- epel-9 | ||
project: packit-dev | ||
list_on_homepage: True | ||
preserve_project: True | ||
- job: copr_build | ||
trigger: commit | ||
branch: main | ||
packages: [specfile-epel8] | ||
targets: | ||
- epel-8 | ||
project: packit-dev | ||
list_on_homepage: True | ||
preserve_project: True | ||
|
||
- job: copr_build | ||
trigger: commit | ||
branch: stable | ||
packages: [specfile] | ||
targets: | ||
- fedora-stable | ||
- epel-9 | ||
project: packit-stable | ||
list_on_homepage: True | ||
preserve_project: True | ||
- job: copr_build | ||
trigger: commit | ||
branch: stable | ||
packages: [specfile-epel8] | ||
targets: | ||
- epel-8 | ||
project: packit-stable | ||
list_on_homepage: True | ||
preserve_project: True | ||
|
||
- job: copr_build | ||
trigger: release | ||
packages: [specfile] | ||
targets: | ||
- fedora-all | ||
- epel-9 | ||
project: packit-releases | ||
list_on_homepage: True | ||
preserve_project: True | ||
- job: copr_build | ||
trigger: release | ||
packages: [specfile-epel8] | ||
targets: | ||
- epel-8 | ||
project: packit-releases | ||
list_on_homepage: True | ||
preserve_project: True | ||
|
||
- job: tests | ||
trigger: pull_request | ||
packages: [specfile] | ||
targets: | ||
- fedora-all | ||
- epel-9 | ||
- job: tests | ||
trigger: pull_request | ||
packages: [specfile-epel8] | ||
targets: | ||
- epel-8 | ||
|
||
- job: propose_downstream | ||
trigger: release | ||
packages: [specfile] | ||
dist_git_branches: | ||
- fedora-all | ||
- epel-9 | ||
- job: propose_downstream | ||
trigger: release | ||
packages: [specfile-epel8] | ||
dist_git_branches: | ||
- epel-8 | ||
|
||
- job: pull_from_upstream | ||
trigger: release | ||
packages: [specfile] | ||
dist_git_branches: | ||
- fedora-all | ||
- epel-9 | ||
- job: pull_from_upstream | ||
trigger: release | ||
packages: [specfile-epel8] | ||
dist_git_branches: | ||
- epel-8 | ||
|
||
# downstream automation: | ||
- job: koji_build | ||
trigger: commit | ||
packit_instances: ["stg"] | ||
allowed_pr_authors: ["packit-stg", "packit"] | ||
dist_git_branches: | ||
- fedora-all | ||
- epel-9 | ||
- epel-8 | ||
|
||
- job: bodhi_update | ||
trigger: commit | ||
packit_instances: ["stg"] | ||
dist_git_branches: | ||
- fedora-branched # rawhide updates are created automatically | ||
- epel-9 | ||
- epel-8 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,91 @@ | ||
%global desc %{expand: | ||
Python library for parsing and manipulating RPM spec files. | ||
Main focus is on modifying existing spec files, any change should result | ||
in a minimal diff.} | ||
|
||
|
||
Name: python-specfile | ||
Version: 0.7.0 | ||
Release: 1%{?dist} | ||
|
||
Summary: A library for parsing and manipulating RPM spec files | ||
License: MIT | ||
URL: https://github.com/packit/specfile | ||
|
||
Source0: %{pypi_source specfile} | ||
|
||
BuildArch: noarch | ||
|
||
BuildRequires: python%{python3_pkgversion}-devel | ||
BuildRequires: %{py3_dist setuptools setuptools-scm setuptools-scm-git-archive} | ||
BuildRequires: %{py3_dist importlib-metadata dataclasses rpm typing-extensions} | ||
BuildRequires: %{py3_dist flexmock pytest} | ||
BuildRequires: git-core | ||
|
||
|
||
%description | ||
%{desc} | ||
|
||
|
||
%package -n python%{python3_pkgversion}-specfile | ||
Summary: %{summary} | ||
|
||
|
||
%description -n python%{python3_pkgversion}-specfile | ||
%{desc} | ||
|
||
|
||
%prep | ||
%autosetup -p1 -n specfile-%{version} | ||
# Use packaged RPM python bindings downstream | ||
sed -i 's/rpm-py-installer/rpm/' setup.cfg | ||
# Remove bundled egg-info | ||
rm -rf specfile.egg-info | ||
|
||
|
||
%build | ||
%py3_build | ||
|
||
|
||
%install | ||
%py3_install | ||
|
||
|
||
%check | ||
%pytest | ||
|
||
|
||
%files -n python%{python3_pkgversion}-specfile | ||
%license LICENSE | ||
%doc README.md | ||
%{python3_sitelib}/specfile | ||
%{python3_sitelib}/specfile-%{version}-py%{python3_version}.egg-info | ||
|
||
|
||
%changelog | ||
* Fri Oct 07 2022 Packit Team <[email protected]> - 0.7.0-1 | ||
- New upstream release 0.7.0 | ||
|
||
* Thu Aug 25 2022 Nikola Forró <[email protected]> - 0.6.0-1 | ||
- New upstream release 0.6.0 | ||
|
||
* Tue Aug 09 2022 Nikola Forró <[email protected]> - 0.5.1-1 | ||
- New upstream release 0.5.1 | ||
|
||
* Thu Jul 21 2022 Nikola Forró <[email protected]> - 0.5.0-1 | ||
- New upstream release 0.5.0 | ||
|
||
* Thu Jun 16 2022 Nikola Forró <[email protected]> - 0.4.0-1 | ||
- New upstream release 0.4.0 | ||
|
||
* Tue May 10 2022 Nikola Forró <[email protected]> - 0.3.0-1 | ||
- New upstream release 0.3.0 | ||
|
||
* Wed Mar 30 2022 Nikola Forró <[email protected]> - 0.2.0-1 | ||
- New upstream release 0.2.0 | ||
|
||
* Mon Feb 21 2022 Nikola Forró <[email protected]> - 0.1.1-1 | ||
- New upstream release 0.1.1 | ||
|
||
* Tue Feb 08 2022 Nikola Forró <[email protected]> - 0.1.0-1 | ||
- Initial package |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
#!/usr/bin/python3 | ||
|
||
# Copyright Contributors to the Packit project. | ||
# SPDX-License-Identifier: MIT | ||
|
||
from setuptools import setup | ||
|
||
setup(use_scm_version={"version_scheme": "post-release"}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.