[python-flask-rstpages] initial

Richard Marko rmarko at fedoraproject.org
Mon Nov 24 12:56:24 UTC 2014


commit 7c9ec9612e593be63a042154268f243600ea569a
Author: Richard Marko <rmarko at fedoraproject.org>
Date:   Mon Nov 24 13:56:17 2014 +0100

    initial
    
    Signed-off-by: Richard Marko <rmarko at fedoraproject.org>

 .gitignore                 |    1 +
 python-flask-rstpages.spec |  108 ++++++++++++++++++++++++++++++++++++++++++++
 sources                    |    1 +
 3 files changed, 110 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..2b0c888 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/Flask-RSTPages-0.3.tar.gz
diff --git a/python-flask-rstpages.spec b/python-flask-rstpages.spec
new file mode 100644
index 0000000..bc73a67
--- /dev/null
+++ b/python-flask-rstpages.spec
@@ -0,0 +1,108 @@
+# Created by pyp2rpm-1.1.1
+%global pypi_name Flask-RSTPages
+%global with_python3 1
+
+Name:           python-flask-rstpages
+Version:        0.3
+Release:        2%{?dist}
+Summary:        Adds support for reStructuredText to a Flask application
+License:        BSD
+URL:            http://flask-rstpages.readthedocs.org/
+Source0:        https://pypi.python.org/packages/source/F/%{pypi_name}/%{pypi_name}-%{version}.tar.gz
+BuildArch:      noarch
+Provides:       Flask-RSTPages
+
+BuildRequires:  python-devel
+BuildRequires:  python-flask
+BuildRequires:  python-sphinx
+
+%if 0%{?with_python3}
+BuildRequires:  python3-devel
+BuildRequires:  python3-flask
+BuildRequires:  python3-sphinx
+%endif # if with_python3
+
+Requires:       python-flask
+Requires:       python-pygments
+Requires:       python-docutils
+
+%description
+Flask-RSTPages adds support for reStructuredText
+to your Flask application.
+
+%if 0%{?with_python3}
+%package -n     python3-flask-rstpages
+Summary:        Adds support for reStructuredText to a Flask application
+Requires:       python3-flask
+Requires:       python3-pygments
+Requires:       python3-docutils
+
+%description -n python3-flask-rstpages
+Flask-RSTPages adds support for reStructuredText
+to your Flask application.
+%endif # with_python3
+
+
+%prep
+%setup -q -n %{pypi_name}-%{version}
+# Remove bundled egg-info
+rm -rf %{pypi_name}.egg-info
+
+# generate html docs
+sphinx-build docs html
+# remove the sphinx-build leftovers
+rm -rf html/.{doctrees,buildinfo}
+
+%if 0%{?with_python3}
+rm -rf %{py3dir}
+cp -a . %{py3dir}
+find %{py3dir} -name '*.py' | xargs sed -i '1s|^#!python|#!%{__python3}|'
+# generate html docs
+sphinx-build-3 docs html
+# remove the sphinx-build leftovers
+rm -rf html/.{doctrees,buildinfo}
+
+%endif # with_python3
+
+find -name '*.py' | xargs sed -i '1s|^#!python|#!%{__python2}|'
+
+%build
+%{__python2} setup.py build
+
+%if 0%{?with_python3}
+pushd %{py3dir}
+%{__python3} setup.py build
+popd
+%endif # with_python3
+
+
+%install
+# Must do the subpackages' install first because the scripts in /usr/bin are
+# overwritten with every setup.py install (and we want the python2 version
+# to be the default for now).
+%if 0%{?with_python3}
+pushd %{py3dir}
+%{__python3} setup.py install --skip-build --root %{buildroot}
+popd
+%endif # with_python3
+
+%{__python2} setup.py install --skip-build --root %{buildroot}
+
+%files
+%doc html LICENSE
+%{python2_sitelib}/flask_rstpages
+%{python2_sitelib}/Flask_RSTPages-%{version}-py?.?.egg-info
+%if 0%{?with_python3}
+%files -n python3-flask-rstpages
+%doc html LICENSE
+%{python3_sitelib}/flask_rstpages
+%{python3_sitelib}/Flask_RSTPages-%{version}-py?.?.egg-info
+%endif # with_python3
+
+
+%changelog
+* Thu Oct 16 2014 Richard Marko <rmarko at fedoraproject.org> - 0.3-2
+- Corrected packaging errors.
+
+* Wed Oct 01 2014 Richard Marko <rmarko at fedoraproject.org> - 0.3-1
+- Initial package.
diff --git a/sources b/sources
index e69de29..3326e90 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+662d48b5057ab8072d84239e94afb63b  Flask-RSTPages-0.3.tar.gz


More information about the scm-commits mailing list