diff --git a/cssutils-1.0.2.tar.gz b/cssutils-1.0.2.tar.gz deleted file mode 100644 index 6719f8e..0000000 --- a/cssutils-1.0.2.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:a2fcf06467553038e98fea9cfe36af2bf14063eb147a70958cfcaa8f5786acaf -size 367038 diff --git a/cssutils-2.6.0.tar.gz b/cssutils-2.6.0.tar.gz new file mode 100644 index 0000000..d04d3e4 --- /dev/null +++ b/cssutils-2.6.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f7dcd23c1cec909fdf3630de346e1413b7b2555936dec14ba2ebb9913bf0818e +size 723259 diff --git a/python-cssutils.changes b/python-cssutils.changes index d89a0f0..9e62a2e 100644 --- a/python-cssutils.changes +++ b/python-cssutils.changes @@ -1,3 +1,16 @@ +------------------------------------------------------------------- +Fri Sep 9 08:34:38 UTC 2022 - Atri Bhattacharya + +- Update to version 2.0.6: + * [gh#jaraco/cssutils#14] Added support for custom CSS + variables with -- prefix. +- Generate a basic setup.py file in-place to use with + %%python_setup; upstream no longer supplies one. +- Use fdupes to link duplicate files. +- Add %{name}.rpmlintrc file to suppress errors about zero-length + files which are nevertheless required. +- Update URL to new upstream home. + ------------------------------------------------------------------- Tue Dec 4 12:47:04 UTC 2018 - Matej Cepl diff --git a/python-cssutils.rpmlintrc b/python-cssutils.rpmlintrc new file mode 100644 index 0000000..1c18300 --- /dev/null +++ b/python-cssutils.rpmlintrc @@ -0,0 +1,2 @@ +# We need to keep these zero-length place-holder files for the examples to work +addFilter("zero-length") diff --git a/python-cssutils.spec b/python-cssutils.spec index 52d2646..05e59ed 100644 --- a/python-cssutils.spec +++ b/python-cssutils.spec @@ -1,7 +1,7 @@ # # spec file for package python-cssutils # -# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2022 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -17,24 +17,22 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} -%define oldpython python Name: python-cssutils -Version: 1.0.2 +Version: 2.6.0 Release: 0 Summary: A CSS Cascading Style Sheets library for Python License: LGPL-3.0-or-later Group: Development/Languages/Python -URL: http://cthedot.de/cssutils/ -Source: https://files.pythonhosted.org/packages/source/c/cssutils/cssutils-%{version}.tar.gz +URL: https://github.com/jaraco/cssutils +Source0: https://files.pythonhosted.org/packages/source/c/cssutils/cssutils-%{version}.tar.gz +Source1: %{name}.rpmlintrc +BuildRequires: %{python_module setuptools_scm} BuildRequires: %{python_module setuptools} +BuildRequires: fdupes BuildRequires: python-rpm-macros Requires(post): update-alternatives -Requires(postun): update-alternatives +Requires(postun):update-alternatives BuildArch: noarch -%ifpython2 -Provides: %{oldpython}-css-utils-doc = %{version} -Obsoletes: %{oldpython}-css-utils-doc < %{version} -%endif %python_subpackages %description @@ -42,8 +40,16 @@ A Python package to parse and build CSS Cascading Style Sheets. DOM only, not an %prep %setup -q -n cssutils-%{version} -sed -i "1d" src/cssutils/{parse,codec,sac,serialize,scripts/csscapture,_codec2,errorhandler,scripts/cssparse,_codec3,scripts/csscombine,tokenize2,__init__}.py # Fix non-executable scripts -sed -i "s/\r//" src/cssutils/{sac,scripts/csscombine,tokenize2}.py COPYING COPYING.LESSER examples/{website,minify,imports,cssencodings,style,testutil,codec}.py # Fix EOL encodings + +# SECTION Generate a basic setup.py as upstream only supplies setup.cfg +cat << EOF > setup.py +import setuptools + +if __name__ == "__main__": + setuptools.setup() + +EOF +# /SECTION %build %python_build @@ -54,6 +60,8 @@ sed -i "s/\r//" src/cssutils/{sac,scripts/csscombine,tokenize2}.py COPYING COPYI %python_clone -a %{buildroot}%{_bindir}/csscombine %python_clone -a %{buildroot}%{_bindir}/cssparse +%python_expand %fdupes %{buildroot}%{$python_sitelib}/ + %post %{python_install_alternative csscapture csscombine cssparse} @@ -62,11 +70,11 @@ sed -i "s/\r//" src/cssutils/{sac,scripts/csscombine,tokenize2}.py COPYING COPYI %files %{python_files} %license COPYING COPYING.LESSER -%doc README.txt examples +%doc README.rst examples %python_alternative %{_bindir}/csscapture %python_alternative %{_bindir}/csscombine %python_alternative %{_bindir}/cssparse -%{python_sitelib}/cssutils-%{version}-py*.egg-info/ +%{python_sitelib}/cssutils-%{version}-py%{python_version}.egg-info/ %{python_sitelib}/cssutils/ %{python_sitelib}/encutils/