diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..c7aab8e --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/python-debianbts-2.8.2.tar.gz diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..9b36f16 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2018 Bastian Venthur + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/python-debianbts.spec b/python-debianbts.spec new file mode 100644 index 0000000..b07cc30 --- /dev/null +++ b/python-debianbts.spec @@ -0,0 +1,65 @@ +%global rpmname debianbts +%global pypi_name python-debianbts + +Name: %{pypi_name} +Version: 2.8.2 +Release: 1%{?dist} +Summary: Python interface to Debian's Bug Tracking System + +License: MIT +URL: https://github.com/venthur/python-debianbts +Source0: %{pypi_source} +Source1: https://raw.githubusercontent.com/venthur/python-debianbts/master/LICENSE +BuildArch: noarch + +BuildRequires: python3-devel +BuildRequires: python3dist(flake8) +BuildRequires: python3dist(pytest) +BuildRequires: python3dist(pytest-cov) +BuildRequires: python3dist(setuptools) + +%description +Python-debianbts is a Python library that allows for querying +Debian's Bug Tracking System. + +%package -n python3-%{rpmname} +Summary: %{summary} +%{?python_provide:%python_provide python3-%{rpmname}} + +Requires: python3dist(mock) +Requires: python3dist(pysimplesoap) +Requires: python3dist(setuptools) + +%description -n python3-%{rpmname} +python-debianbts is a Python library that allows for querying +Debian's Bug Tracking System. + +%prep +%autosetup -n %{pypi_name}-%{version} +for lib in debianbts/*.py; do + sed -e '1{\@^#! /usr/bin/env python@d}' -e '1{\@^#!/usr/bin/env python@d}' \ + -e '1{\@^#!/usr/bin/python@d}' $lib > $lib.new && + touch -r $lib $lib.new && + mv $lib.new $lib +done +cp -p %{SOURCE1} . + +# Remove bundled egg-info +#rm -rf %{pypi_name}.egg-info + +%build +%py3_build + +%install +%py3_install + +%files -n python3-%{rpmname} +%doc README.md +%license LICENSE +%{_bindir}/debianbts +%{python3_sitelib}/debianbts +%{python3_sitelib}/python_debianbts-%{version}-py%{python3_version}.egg-info + +%changelog +* Sat Aug 10 2019 Huzaifa Sidhpurwala - 2.8.2-1 +- Initial package. diff --git a/sources b/sources new file mode 100644 index 0000000..5a511e1 --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (python-debianbts-2.8.2.tar.gz) = ffb8f1a2dc85887e2b9d9d21aa7d9bec354bfa48a0b63cf5f54d97833a0c28fadebfb530fecba868f4361214e0ce921bdd9fbd404e17fb66b4a311e9c42ad0fb