diff --git a/python-dunamai.spec b/python-dunamai.spec index 5aff60e..e21e390 100644 --- a/python-dunamai.spec +++ b/python-dunamai.spec @@ -1,22 +1,3 @@ -# See this for all pyproject macros: https://src.fedoraproject.org/rpms/pyproject-rpm-macros -# New guidelines: https://fedoraproject.org/wiki/Changes/PythonPackagingGuidelines202x - -# Enabled by default -# If the package needs to download data for the test which cannot be done in -# koji, these can be disabled in koji by using `bcond_with` instead, but the -# tests must be validated in mock with network enabled like so: -# mock -r fedora-rawhide-x86_64 rebuild --enable-network --rpmbuild-opts="--with tests" -%bcond_without tests - -# Replace "dunamai" with the appropriate value using your editor's -# search and replace function. It is preferred to using macros like %{pypi_name} -# because they make the spec harder to read especially in cases where the -# canonical ("pretty name") of the module is different from its name on pypi - - -# for github etc. use the forgemacros -# https://docs.fedoraproject.org/en-US/packaging-guidelines/SourceURL/#_using_forges_hosted_revision_control - %global _description %{expand: Dunamai is a Python 3.5+ library and command line tool for producing dynamic, standards-compliant version strings, derived from tags in your version control @@ -31,7 +12,7 @@ Summary: Dynamic version generation License: MIT URL: https://pypi.org/pypi/dunamai -Source0: %{pypi_source dunamai} +Source: https://github.com/mtkennerly/dunamai/archive/v%{version}/%{name}-%{version}.tar.gz BuildArch: noarch @@ -39,9 +20,18 @@ BuildArch: noarch %package -n python3-dunamai Summary: %{summary} -# pyproject-rpm-macros is also pulled in by python3-devel BuildRequires: python3-devel +BuildRequires: python3-pytest +BuildRequires: /usr/bin/git +BuildRequires: /usr/bin/hg +BuildRequires: /usr/bin/darcs +BuildRequires: /usr/bin/svn +BuildRequires: /usr/bin/bzr +BuildRequires: /usr/bin/fossil +# pijul is not in Fedora yet +#BuildRequires: /usr/bin/pijul + %description -n python3-dunamai %_description %prep @@ -64,15 +54,20 @@ BuildRequires: python3-devel %pyproject_save_files dunamai %check -%if %{with tests} +# set up git +git config --global user.email "you@example.com" +git config --global user.name "Your Name" +# set up bzr +brz whoami "Your Name " +# set up darcs +export DARCS_EMAIL="Yep something " + %{pytest} -# or %%{tox} -%endif -# LICENSE/COPYING are included in the dist-info, so we do not need to -# explicitly list them again %files -n python3-dunamai -f %{pyproject_files} -%doc README.rst +%doc README.md CHANGELOG.md CONTRIBUTING.md +%license LICENSE +%{_bindir}/dunamai %changelog %autochangelog