From 9b0464e989932c81ae4bc44f9cbcdbf27e4705d7 Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: Aug 01 2017 03:38:16 +0000 Subject: import python-prettytable-0.7.2-3.el7 --- diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..63fad7c --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +SOURCES/prettytable-0.7.2.tar.gz diff --git a/.python-prettytable.metadata b/.python-prettytable.metadata new file mode 100644 index 0000000..670fdc9 --- /dev/null +++ b/.python-prettytable.metadata @@ -0,0 +1 @@ +b7d0bf0feee0d23108a044ffae44aff5c5935250 SOURCES/prettytable-0.7.2.tar.gz diff --git a/README.md b/README.md deleted file mode 100644 index 5231011..0000000 --- a/README.md +++ /dev/null @@ -1,8 +0,0 @@ -The master branch has no content - -Look at the c7 branch if you are working with CentOS-7, or the c4/c5/c6 branch -for CentOS-4, 5 or 6. If you find this file in a distro specific branch, it -means that no content has been checked in yet - -More information on how these git repositories are setup, is available at -http://wiki.centos.org/Sources diff --git a/SOURCES/disable-encoding-check.patch b/SOURCES/disable-encoding-check.patch new file mode 100644 index 0000000..581c8f5 --- /dev/null +++ b/SOURCES/disable-encoding-check.patch @@ -0,0 +1,12 @@ +diff -Naur -Naru prettytable-0.7.2.orig/prettytable_test.py prettytable-0.7.2/prettytable_test.py +--- prettytable-0.7.2.orig/prettytable_test.py 2013-04-06 23:43:12.000000000 +0000 ++++ prettytable-0.7.2/prettytable_test.py 2014-01-07 18:49:26.017977139 +0000 +@@ -582,7 +582,7 @@ + + def testPrint(self): + print() +- print(self.x) ++ #print(self.x) + + if __name__ == "__main__": + unittest.main() diff --git a/SPECS/python-prettytable.spec b/SPECS/python-prettytable.spec new file mode 100644 index 0000000..38e2be3 --- /dev/null +++ b/SPECS/python-prettytable.spec @@ -0,0 +1,143 @@ +%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")} + +%if 0%{?fedora} > 12 || 0%{?rhel} > 7 +%global with_python3 1 +%endif + +%global modname prettytable + + +Name: python-%{modname} +Version: 0.7.2 +Release: 3%{?dist} +Summary: Python library to display tabular data in tables + +Group: Development/Languages +License: BSD +Source0: http://pypi.python.org/packages/source/P/PrettyTable/%{modname}-%{version}.tar.gz +URL: http://pypi.python.org/pypi/PrettyTable + +Patch0: disable-encoding-check.patch + +BuildArch: noarch +BuildRequires: python-devel +BuildRequires: python-setuptools + +%if 0%{?with_python3} +BuildRequires: python3-devel +BuildRequires: python3-setuptools +%endif + +Provides: python2-prettytable + +%description +PrettyTable is a simple Python library designed to make it quick and easy to +represent tabular data in visually appealing ASCII tables. It was inspired by +the ASCII tables used in the PostgreSQL shell psql. PrettyTable allows for +selection of which columns are to be printed, independent alignment of columns +(left or right justified or centred) and printing of "sub-tables" by specifying +a row range. + +%if 0%{?with_python3} +%package -n python3-%{modname} +Summary: Python library to display tabular data in tables +Group: Development/Languages + +%description -n python3-%{modname} +PrettyTable is a simple Python library designed to make it quick and easy to +represent tabular data in visually appealing ASCII tables. It was inspired by +the ASCII tables used in the PostgreSQL shell psql. PrettyTable allows for +selection of which columns are to be printed, independent alignment of columns +(left or right justified or centred) and printing of "sub-tables" by specifying +a row range. +%endif + + +%prep +%setup -q -n %{modname}-%{version} + +%patch0 -p1 + +%if 0%{?with_python3} +rm -rf %{py3dir} +cp -a . %{py3dir} +%endif + + +%build +%{__python} setup.py build + +%if 0%{?with_python3} +pushd %{py3dir} +%{__python3} setup.py build +popd +%endif + +%check +%{__python} %{modname}_test.py + +%if 0%{?with_python3} +pushd %{py3dir} +%{__python3} %{modname}_test.py +popd +%endif + + +%install +%if 0%{?with_python3} +pushd %{py3dir} +%{__python3} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT +popd +%endif + +%{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT + + +%files +%doc README COPYING CHANGELOG +%{python_sitelib}/%{modname}.py* +%{python_sitelib}/%{modname}-%{version}* + +%if 0%{?with_python3} +%files -n python3-%{modname} +%doc README COPYING CHANGELOG +%{python3_sitelib}/%{modname}.py* +%{python3_sitelib}/__pycache__/%{modname}* +%{python3_sitelib}/%{modname}-%{version}* +%endif + + +%changelog +* Thu Apr 13 2017 Charalampos Stratakis - 0.7.2-3 +- Import to RHEL 7 +- Bump release for rebuild +Resolves: rhbz#1434891 + +* Tue Jan 07 2014 Pádraig Brady - 0.7.2-1 +- Latest upstream + +* Sun Aug 04 2013 Fedora Release Engineering - 0.6.1-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild + +* Thu Feb 14 2013 Fedora Release Engineering - 0.6.1-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild + +* Tue Aug 07 2012 Ralph Bean - 0.6.1-1 +- New upstream version +- Added support for python3 +- Included README, COPYING, and CHANGELOG in docs + +* Tue Aug 07 2012 Pádraig Brady - 0.6-1 +- Update to 0.6 + +* Sat Jul 21 2012 Fedora Release Engineering - 0.5-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild + +* Sat Jan 14 2012 Fedora Release Engineering - 0.5-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild + +* Tue Jul 05 2011 Chris Lalancette - 0.5-2 +- BuildRequire python-setuptools + +* Wed Jun 29 2011 Chris Lalancette - 0.5-1 +- Initial package.