Blame SPECS/python-pycodestyle.spec

e137dc
%global module_name pycodestyle
e137dc
e137dc
%if 0%{?fedora} >= 32 || 0%{?rhel} >= 9
e137dc
%bcond_with python2
e137dc
%else
e137dc
%bcond_without python2
e137dc
%endif
e137dc
e137dc
Name:           python-%{module_name}
e137dc
# WARNING: When updating pycodestyle, check not to break flake8!
e137dc
Version:        2.6.0
e137dc
Release:        4%{?dist}
e137dc
Summary:        Python style guide checker
e137dc
License:        MIT
e137dc
URL:            https://pypi.python.org/pypi/%{module_name}
e137dc
Source0:        %{pypi_source %{module_name}}
e137dc
e137dc
BuildArch:      noarch
e137dc
e137dc
%description
e137dc
pycodestyle is a tool to check your Python code against some of the style
e137dc
conventions in PEP 8. It has a plugin architecture, making new checks easy, and
e137dc
its output is parseable, making it easy to jump to an error location in your
e137dc
editor.
e137dc
e137dc
%if %{with python2}
e137dc
%package -n python2-%{module_name}
e137dc
Summary:        Python style guide checker
e137dc
%{?python_provide:%python_provide python2-%{module_name}}
e137dc
e137dc
BuildRequires:  python2-devel
e137dc
BuildRequires:  python2-setuptools
e137dc
Requires:       python2-setuptools
e137dc
e137dc
e137dc
%description -n python2-%{module_name}
e137dc
pycodestyle is a tool to check your Python code against some of the style
e137dc
conventions in PEP 8. It has a plugin architecture, making new checks easy, and
e137dc
its output is parseable, making it easy to jump to an error location in your
e137dc
editor.
e137dc
%endif
e137dc
e137dc
e137dc
%package -n python%{python3_pkgversion}-pycodestyle
e137dc
Summary:    Python style guide checker
e137dc
%{?python_provide:%python_provide python%{python3_pkgversion}-%{module_name}}
e137dc
Conflicts:      python-pycodestyle < %{version}-%{release}
e137dc
e137dc
BuildRequires:  python%{python3_pkgversion}-devel
e137dc
BuildRequires:  python%{python3_pkgversion}-setuptools
e137dc
BuildRequires:  python%{python3_pkgversion}-sphinx
e137dc
BuildRequires:  python%{python3_pkgversion}-sphinx_rtd_theme
e137dc
BuildRequires:  make
e137dc
e137dc
%description -n python%{python3_pkgversion}-pycodestyle
e137dc
pycodestyle is a tool to check your Python code against some of the style
e137dc
conventions in PEP 8. It has a plugin architecture, making new checks easy, and
e137dc
its output is parseable, making it easy to jump to an error location in your
e137dc
editor.
e137dc
e137dc
This is a version for Python %{python3_pkgversion}.
e137dc
e137dc
e137dc
%prep
e137dc
%autosetup -n %{module_name}-%{version}
e137dc
e137dc
# Remove #! from pycodestyle.py
e137dc
sed --in-place "s:#!\s*/usr.*::" pycodestyle.py
e137dc
e137dc
e137dc
%build
e137dc
%if %{with python2}
e137dc
%py2_build
e137dc
%endif
e137dc
%py3_build
e137dc
e137dc
make -C docs man SPHINXBUILD=sphinx-build-%{python3_version}
e137dc
e137dc
e137dc
%install
e137dc
%if %{with python2}
e137dc
%py2_install
e137dc
mv %{buildroot}%{_bindir}/pycodestyle %{buildroot}%{_bindir}/pycodestyle-%{python2_version}
e137dc
ln -s ./pycodestyle-%{python2_version} %{buildroot}%{_bindir}/pycodestyle-2
e137dc
%endif
e137dc
e137dc
%py3_install
e137dc
mv %{buildroot}%{_bindir}/pycodestyle %{buildroot}%{_bindir}/pycodestyle-%{python3_version}
e137dc
ln -s ./pycodestyle-%{python3_version} %{buildroot}%{_bindir}/pycodestyle-3
e137dc
ln -s ./pycodestyle-3 %{buildroot}%{_bindir}/pycodestyle
e137dc
e137dc
e137dc
install -D docs/_build/man/%{module_name}.1 %{buildroot}%{_mandir}/man1/%{module_name}.1
e137dc
e137dc
e137dc
%check
e137dc
%if %{with python2}
e137dc
%{__python2} pycodestyle.py --max-doc-length=72 --testsuite testsuite
e137dc
%{__python2} pycodestyle.py --max-doc-length=72 --doctest
e137dc
%endif
e137dc
%{__python3} pycodestyle.py --max-doc-length=72 --testsuite testsuite
e137dc
%{__python3} pycodestyle.py --max-doc-length=72 --doctest
e137dc
e137dc
e137dc
%if %{with python2}
e137dc
%files -n python2-%{module_name}
e137dc
%doc CHANGES.txt README.rst
e137dc
%license LICENSE
e137dc
%{_bindir}/pycodestyle-2
e137dc
%{_bindir}/pycodestyle-2.7
e137dc
%{python2_sitelib}/%{module_name}.py*
e137dc
%{python2_sitelib}/%{module_name}-%{version}-*.egg-info
e137dc
%endif
e137dc
e137dc
%files -n python%{python3_pkgversion}-pycodestyle
e137dc
%doc README.rst CHANGES.txt
e137dc
%license LICENSE
e137dc
%{_mandir}/man1/%{module_name}.1.gz
e137dc
%{_bindir}/pycodestyle
e137dc
%{_bindir}/pycodestyle-3
e137dc
%{_bindir}/pycodestyle-%{python3_version}
e137dc
%pycached %{python3_sitelib}/%{module_name}.py
e137dc
%{python3_sitelib}/%{module_name}-%{version}-*.egg-info/
e137dc
e137dc
%changelog
e137dc
* Thu Feb 18 2021 Miro Hrončok <mhroncok@redhat.com> - 2.6.0-4
e137dc
- Properly BuildRequire make
e137dc
e137dc
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 2.6.0-3
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
e137dc
e137dc
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2.6.0-2
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
e137dc
e137dc
* Sun May 31 2020 Miro Hrončok <mhroncok@redhat.com> - 2.6.0-1
e137dc
- Update to 2.6.0 (#1827430)
e137dc
e137dc
* Sun May 24 2020 Miro Hrončok <mhroncok@redhat.com> - 2.5.0-8
e137dc
- Rebuilt for Python 3.9
e137dc
e137dc
* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2.5.0-7
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
e137dc
e137dc
* Fri Nov 15 2019 Orion Poplawski <orion@nwra.com> - 2.5.0-6
e137dc
- Drop python2 for Fedora 32+
e137dc
e137dc
* Thu Oct 03 2019 Miro Hrončok <mhroncok@redhat.com> - 2.5.0-5
e137dc
- Rebuilt for Python 3.8.0rc1 (#1748018)
e137dc
e137dc
* Sat Aug 17 2019 Miro Hrončok <mhroncok@redhat.com> - 2.5.0-4
e137dc
- Rebuilt for Python 3.8
e137dc
e137dc
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.5.0-3
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
e137dc
e137dc
* Wed Jul 17 2019 Miro Hrončok <mhroncok@redhat.com> - 2.5.0-2
e137dc
- Make /usr/bin/pycodestyle Python 3
e137dc
e137dc
* Wed Feb 20 2019 Matthias Runge <mrunge@redhat.com> - 2.5.0-1
e137dc
- update to 2.5.0 and fix FTBFS
e137dc
e137dc
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.4.0-4
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
e137dc
e137dc
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.4.0-3
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
e137dc
e137dc
* Mon Jun 18 2018 Miro Hrončok <mhroncok@redhat.com> - 2.4.0-2
e137dc
- Rebuilt for Python 3.7
e137dc
e137dc
* Sat Jun 02 2018 Miro Hrončok <mhroncok@redhat.com> - 2.4.0-1
e137dc
- Update to 2.4.0 (#1565613)
e137dc
e137dc
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.3.1-2
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
e137dc
e137dc
* Thu Aug 24 2017 Lumír Balhar <lbalhar@redhat.com> 2.3.1-1
e137dc
- New upstream version 2.3.1
e137dc
- Use 'python2' instead of just 'python' in the names of dependencies
e137dc
e137dc
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.0-6
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
e137dc
e137dc
* Fri Mar 10 2017 Orion Poplawski <orion@cora.nwra.com> - 2.0.0-5
e137dc
- Fix python3 builds for EPEL
e137dc
- Cleanup spec
e137dc
e137dc
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.0-4
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
e137dc
e137dc
* Tue Dec 13 2016 Charalampos Stratakis <cstratak@redhat.com> - 2.0.0-3
e137dc
- Rebuild for Python 3.6
e137dc
e137dc
* Thu Aug  4 2016 Luke Macken <lmacken@redhat.com> - 2.0.0-2
e137dc
- Use the new python setup/build/install macros
e137dc
- Remove Obsoletes/Provides for pep8, since it is currently not a drop-in replacement.
e137dc
  https://bugzilla.redhat.com/show_bug.cgi?id=1342839#c10
e137dc
e137dc
* Sun Jun 05 2016 Luke Macken <lmacken@redhat.com> - 2.0.0-1
e137dc
- The pep8 project has been renamed to pycodestyle
e137dc
- Create python2 subpackage
e137dc
- Update the source url to use pypi.io
e137dc
- Build a man page instead of html docs
e137dc
e137dc
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.6.2-4
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
e137dc
e137dc
* Thu Nov 12 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.6.2-3
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Changes/python3.5
e137dc
e137dc
* Wed Nov 11 2015 Robert Kuska <rkuska@redhat.com> - 1.6.2-2
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Changes/python3.5
e137dc
e137dc
* Wed Nov 11 2015 Matthias Runge <mrunge@redhat.com> - 1.6.2-1
e137dc
- update to 1.6.2
e137dc
e137dc
* Fri Nov 06 2015 Robert Kuska <rkuska@redhat.com> - 1.5.7-3
e137dc
- Rebuilt for Python3.5 rebuild
e137dc
e137dc
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.5.7-2
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
e137dc
e137dc
* Mon Oct 20 2014 Matthias Runge <mrunge@redhat.com> - 1.5.7-1
e137dc
- update to 1.5.7
e137dc
e137dc
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.5.6-3
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
e137dc
e137dc
* Thu May 15 2014 Bohuslav Kabrda <bkabrda@redhat.com> - 1.5.6-2
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Changes/Python_3.4
e137dc
e137dc
* Wed May 14 2014 Matthias Runge <mrunge@redhat.com> - 1.5.6-1
e137dc
- update to 1.5.6 (rhbz#1087351)
e137dc
e137dc
* Tue Apr 08 2014 Matthias Runge <mrunge@redhat.com> - 1.5.4-1
e137dc
- require python3-setuptools (rhbz#1084756)
e137dc
- update to 1.5.4 (rhbz#1081516)
e137dc
e137dc
* Wed Feb 26 2014 Matthias Runge <mrunge@redhat.com> -1.4.6-2
e137dc
- rename py3 version of pep8 to python3-pep8 (rhbz#1060408)
e137dc
e137dc
* Tue Aug 13 2013 Ian Weller <iweller@redhat.com> - 1.4.6-1
e137dc
- update to 1.4.6
e137dc
e137dc
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.4.5-2
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
e137dc
e137dc
* Fri Jun 14 2013 Matthias Runge <mrunge@redhat.com> - 1.4.5-1
e137dc
- update to 1.4.5 (rhbz#918924)
e137dc
- introduce py3 package (rhbz#971941)
e137dc
e137dc
* Tue Feb 26 2013 Ian Weller <iweller@redhat.com> - 1.4.4-1
e137dc
- Update to 1.4.4
e137dc
e137dc
* Mon Feb 11 2013 Ian Weller <iweller@redhat.com> - 1.4.2-1
e137dc
- Update to 1.4.2
e137dc
e137dc
* Tue Jan 29 2013 Ian Weller <iweller@redhat.com> - 1.4.1-1
e137dc
- Update to 1.4.1
e137dc
- Add Sphinx docs
e137dc
e137dc
* Fri Sep 07 2012 Ian Weller <iweller@redhat.com> - 1.3.3-3
e137dc
- Run test suite using the pep8.py that has been installed
e137dc
e137dc
* Fri Sep 07 2012 Ian Weller <iweller@redhat.com> - 1.3.3-2
e137dc
- Add test suite
e137dc
e137dc
* Thu Sep 06 2012 Ian Weller <iweller@redhat.com> - 1.3.3-1
e137dc
- Update to 1.3.3
e137dc
e137dc
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.3-2
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
e137dc
e137dc
* Sat Jun 16 2012 Ian Weller <iweller@redhat.com> - 1.3-1
e137dc
- Update to 1.3
e137dc
e137dc
* Sat Apr 07 2012 Ian Weller <iweller@redhat.com> - 1.0.1-1
e137dc
- Update to 1.0.1
e137dc
e137dc
* Fri Jan 27 2012 Ian Weller <iweller@redhat.com> - 0.6.1-1
e137dc
- Update to 0.6.1
e137dc
e137dc
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.0-4
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
e137dc
e137dc
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.0-3
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
e137dc
e137dc
* Fri Jan 21 2011 Ian Weller <iweller@redhat.com> - 0.6.0-2
e137dc
- RHBZ 633102: Requires: python-setuptools
e137dc
e137dc
* Tue Nov 16 2010 Ian Weller <iweller@redhat.com> - 0.6.0-1
e137dc
- Changed upstream (same code, new maintainer, new URL)
e137dc
- New release
e137dc
e137dc
* Thu Jul 22 2010 David Malcolm <dmalcolm@redhat.com> - 0.4.2-3
e137dc
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
e137dc
e137dc
* Mon Nov  9 2009 Ian Weller <ian@ianweller.org> - 0.4.2-2
e137dc
- Add BR: python-setuptools
e137dc
- Change URL to the correct upstream
e137dc
e137dc
* Sun Nov  8 2009 Ian Weller <ian@ianweller.org> - 0.4.2-1
e137dc
- Initial package build