]> git.pld-linux.org Git - packages/python-reno.git/blob - python-reno.spec
- version comment
[packages/python-reno.git] / python-reno.spec
1 # TODO: fix tests and doc
2 #
3 # Conditional build:
4 %bcond_with     doc     # Sphinx documentation [broken, requires git repo?]
5 %bcond_with     tests   # subunit tests (requires git repo?)
6 %bcond_without  python2 # CPython 2.x module
7 %bcond_without  python3 # CPython 3.x module
8
9 Summary:        reno: a New Way to manage Release Notes
10 Summary(pl.UTF-8):      reno: nowy sposób zarządzania informacjami o wydaniu (Release Notes)
11 Name:           python-reno
12 # keep 2.x here for python2 support
13 Version:        2.11.3
14 Release:        2
15 License:        Apache v2.0
16 Group:          Libraries/Python
17 #Source0Download: https://pypi.python.org/simple/reno
18 Source0:        https://files.pythonhosted.org/packages/source/r/reno/reno-%{version}.tar.gz
19 # Source0-md5:  c582cf344169a91f8d9a86b22ae3660a
20 Patch0:         %{name}-mock.patch
21 URL:            http://docs.openstack.org/developer/reno/
22 %if %{with python2}
23 BuildRequires:  python-modules >= 1:2.7
24 BuildRequires:  python-pbr >= 1.4
25 BuildRequires:  python-setuptools
26 %if %{with tests}
27 BuildRequires:  python-PyYAML >= 3.10.0
28 BuildRequires:  python-Sphinx >= 1.6.1
29 BuildRequires:  python-coverage >= 4.0
30 BuildRequires:  python-dulwich >= 0.15.0
31 BuildRequires:  python-mock >= 1.2
32 BuildRequires:  python-six >= 1.9.0
33 BuildRequires:  python-testtools >= 1.4.0
34 %endif
35 %endif
36 %if %{with python3}
37 BuildRequires:  python3-modules >= 1:3.4
38 BuildRequires:  python3-pbr >= 1.4
39 BuildRequires:  python3-setuptools
40 %if %{with tests}
41 BuildRequires:  python3-PyYAML >= 3.10.0
42 BuildRequires:  python3-Sphinx >= 1.6.1
43 BuildRequires:  python3-coverage >= 4.0
44 BuildRequires:  python3-dulwich >= 0.15.0
45 BuildRequires:  python3-six >= 1.9.0
46 BuildRequires:  python3-testtools >= 1.4.0
47 %endif
48 %endif
49 %if %{with doc}
50 BuildRequires:  python3-docutils >= 0.11
51 BuildRequires:  python3-openstackdocstheme >= 1.11.0
52 BuildRequires:  sphinx-pdg >= 1.6.1
53 %endif
54 BuildRequires:  rpm-pythonprov
55 BuildRequires:  rpmbuild(macros) >= 1.714
56 Requires:       python-modules >= 1:2.7
57 BuildArch:      noarch
58 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
59
60 %description
61 Reno is a release notes manager designed with high throughput in mind,
62 supporting fast distributed development teams without introducing
63 additional development processes. The goal is to encourage detailed
64 and accurate release notes for every release.
65
66 %description -l pl.UTF-8
67 Reno to zarządca informacji o wydaniu, zaprojektowany z myślą o dużym
68 przepływie, obsługujący szybkie, rozproszone zespoły programistów bez
69 wprowadzania dodatkowych procesów. Celem jest wspieranie szczegółowych
70 i dokładnych informacji dla każdego wydania.
71
72 %package -n python3-reno
73 Summary:        reno: a New Way to manage Release Notes
74 Summary(pl.UTF-8):      reno: nowy sposób zarządzania informacjami o wydaniu (Release Notes)
75 Group:          Libraries/Python
76 Requires:       python3-modules >= 1:3.4
77
78 %description -n python3-reno
79 Reno is a release notes manager designed with high throughput in mind,
80 supporting fast distributed development teams without introducing
81 additional development processes. The goal is to encourage detailed
82 and accurate release notes for every release.
83
84 %description -n python3-reno -l pl.UTF-8
85 Reno to zarządca informacji o wydaniu, zaprojektowany z myślą o dużym
86 przepływie, obsługujący szybkie, rozproszone zespoły programistów bez
87 wprowadzania dodatkowych procesów. Celem jest wspieranie szczegółowych
88 i dokładnych informacji dla każdego wydania.
89
90 %package apidocs
91 Summary:        API documentation for reno
92 Summary(pl.UTF-8):      Dokumentacja API modułu reno
93 Group:          Documentation
94
95 %description apidocs
96 API documentation for reno.
97
98 %description apidocs -l pl.UTF-8
99 Dokumentacja API modułu reno.
100
101 %prep
102 %setup -q -n reno-%{version}
103 %patch0 -p1
104
105 %build
106 %if %{with python2}
107 %py_build
108
109 %if %{with tests}
110 %{__python} -m unittest discover -s reno/tests
111 %endif
112 %endif
113
114 %if %{with python3}
115 %py3_build
116
117 %if %{with tests}
118 %{__python3} -m unittest discover -s reno/tests
119 %endif
120 %endif
121
122 %if %{with doc}
123 PYTHONPATH=$(pwd) \
124 sphinx-build-3 -b html doc/source doc/source/_build/html
125 %endif
126
127 %install
128 rm -rf $RPM_BUILD_ROOT
129
130 %if %{with python2}
131 %py_install
132
133 %{__mv} $RPM_BUILD_ROOT%{_bindir}/reno{,-2}
134
135 %py_postclean
136 %endif
137
138 %if %{with python3}
139 %py3_install
140
141 %{__mv} $RPM_BUILD_ROOT%{_bindir}/reno{,-3}
142 ln -s reno-3 $RPM_BUILD_ROOT%{_bindir}/reno
143 %endif
144
145 %clean
146 rm -rf $RPM_BUILD_ROOT
147
148 %if %{with python2}
149 %files
150 %defattr(644,root,root,755)
151 %doc AUTHORS ChangeLog README.rst
152 %attr(755,root,root) %{_bindir}/reno-2
153 %{py_sitescriptdir}/reno
154 %{py_sitescriptdir}/reno-%{version}-py*.egg-info
155 %endif
156
157 %if %{with python3}
158 %files -n python3-reno
159 %defattr(644,root,root,755)
160 %doc AUTHORS ChangeLog README.rst
161 %attr(755,root,root) %{_bindir}/reno
162 %attr(755,root,root) %{_bindir}/reno-3
163 %{py3_sitescriptdir}/reno
164 %{py3_sitescriptdir}/reno-%{version}-py*.egg-info
165 %endif
166
167 %if %{with doc}
168 %files apidocs
169 %defattr(644,root,root,755)
170 %doc docs/_build/html/*
171 %endif
This page took 0.088461 seconds and 3 git commands to generate.