diff --git python-bunch/python-bunch.spec python-bunch/python-bunch.spec.tmp index 5064bce001..7179f3a1ee 100644 --- python-bunch/python-bunch.spec +++ python-bunch/python-bunch.spec.tmp @@ -6,7 +6,7 @@ Name: python-bunch Version: 1.0.1 -Release: 11%{?dist} +Release: 12%{?dist} Summary: Python dictionary with attribute-style access Group: Development/Languages @@ -21,22 +21,30 @@ BuildRequires: dos2unix BuildRequires: python-setuptools BuildRequires: python-nose -%description -python-bunch provides a python class which can perform as a dict whose keys are -also accessible as attributes, similar to JavaScript objects. For instance:: +%global _description\ +python-bunch provides a python class which can perform as a dict whose keys are\ +also accessible as attributes, similar to JavaScript objects. For instance::\ +\ + >>> import bunch\ + >>> people = bunch.Bunch({'alice': 'here', 'bob': 'there'})\ + >>> print people['alice'], people.alice\ + here here\ +\ +The piece of python-bunch that sets it apart from similar modules found inside\ +other projects is the bunchify() function which recursively converts from\ +a dict to a Bunch::\ +\ + >>> multi_level = {'array': ['scalar', {'mapping': 'to show recursion'} ]}\ + >>> bunch.bunchify(multi_level)\ + Bunch(array=['scalar', Bunch(mapping='to show recursion')]) - >>> import bunch - >>> people = bunch.Bunch({'alice': 'here', 'bob': 'there'}) - >>> print people['alice'], people.alice - here here +%description %_description -The piece of python-bunch that sets it apart from similar modules found inside -other projects is the bunchify() function which recursively converts from -a dict to a Bunch:: +%package -n python2-bunch +Summary: %summary +%{?python_provide:%python_provide python2-bunch} - >>> multi_level = {'array': ['scalar', {'mapping': 'to show recursion'} ]} - >>> bunch.bunchify(multi_level) - Bunch(array=['scalar', Bunch(mapping='to show recursion')]) +%description -n python2-bunch %_description %prep %setup -q -n %{srcname}-%{version} @@ -58,13 +66,17 @@ rm -rf %{buildroot} PYTHONPATH=build/lib nosetests --with-doctest PYTHONPATH=build/lib python build/lib/bunch/test.py -%files +%files -n python2-bunch %defattr(-,root,root,-) %doc LICENSE.txt README.rst %{python_sitelib}/* %changelog +* Sat Aug 12 2017 Zbigniew Jędrzejewski-Szmek - 1.0.1-12 +- Python 2 binary package renamed to python2-bunch + See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3 + * Thu Jul 27 2017 Fedora Release Engineering - 1.0.1-11 - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild