| |
@@ -1,11 +1,3 @@
|
| |
- %if 0%{?fedora}
|
| |
- %global py2 2
|
| |
- %global with_python3 1
|
| |
- %else
|
| |
- # On EL7 define %%{py2} as the empty string.
|
| |
- %define py2 %{nil}
|
| |
- %endif
|
| |
-
|
| |
%{!?_licensedir: %global license %%doc}
|
| |
|
| |
%global modname sync2jira
|
| |
@@ -24,27 +16,16 @@
|
| |
|
| |
BuildRequires: systemd
|
| |
|
| |
- BuildRequires: python%{py2}-devel
|
| |
- BuildRequires: python%{py2}-setuptools
|
| |
- BuildRequires: python%{py2}-fedmsg-core
|
| |
- BuildRequires: python%{py2}-requests
|
| |
- BuildRequires: python%{py2}-nose
|
| |
- BuildRequires: python%{py2}-mock
|
| |
- BuildRequires: python%{py2}-arrow
|
| |
- %if 0%{?fedora}
|
| |
- BuildRequires: python%{py2}-jira
|
| |
- %endif
|
| |
-
|
| |
- %if 0%{?with_python3}
|
| |
BuildRequires: python3-devel
|
| |
BuildRequires: python3-setuptools
|
| |
BuildRequires: python3-fedmsg-core
|
| |
+ BuildRequires: python3-github3py
|
| |
BuildRequires: python3-requests
|
| |
BuildRequires: python3-nose
|
| |
+ BuildRequires: python3-pytest
|
| |
BuildRequires: python3-mock
|
| |
BuildRequires: python3-jira
|
| |
BuildRequires: python3-arrow
|
| |
- %endif
|
| |
|
| |
%description
|
| |
This is a process that listens to activity on upstream repos on pagure and
|
| |
@@ -54,25 +35,6 @@
|
| |
allows you to match one upstream repo (say, 'pungi' on pagure) to a downstream
|
| |
project/component pair in Jira (say, 'COMPOSE', and 'Pungi').
|
| |
|
| |
- %package -n python2-%{modname}
|
| |
- Summary: %{sum}
|
| |
- %{?python_provide:%python_provide python2-%{modname}}
|
| |
-
|
| |
- Requires: python%{py2}-requests
|
| |
- Requires: python%{py2}-fedmsg-core
|
| |
- %if 0%{?fedora}
|
| |
- Requires: python%{py2}-jira
|
| |
- %endif
|
| |
-
|
| |
- %description -n python2-%{modname}
|
| |
- This is a process that listens to activity on upstream repos on pagure and
|
| |
- github via fedmsg, and syncs new issues there to a Jira instance elsewhere.
|
| |
-
|
| |
- Configuration is in /etc/fedmsg.d/. You can maintain a mapping there that
|
| |
- allows you to match one upstream repo (say, 'pungi' on pagure) to a downstream
|
| |
- project/component pair in Jira (say, 'COMPOSE', and 'Pungi').
|
| |
-
|
| |
- %if 0%{?with_python3}
|
| |
%package -n python3-%{modname}
|
| |
Summary: %{sum}
|
| |
%{?python_provide:%python_provide python3-%{modname}}
|
| |
@@ -80,6 +42,7 @@
|
| |
Requires: python3-requests
|
| |
Requires: python3-jira
|
| |
Requires: python3-fedmsg-core
|
| |
+ Requires: python3-github3py
|
| |
|
| |
%description -n python3-%{modname}
|
| |
This is a process that listens to activity on upstream repos on pagure and
|
| |
@@ -88,7 +51,6 @@
|
| |
Configuration is in /etc/fedmsg.d/. You can maintain a mapping there that
|
| |
allows you to match one upstream repo (say, 'pungi' on pagure) to a downstream
|
| |
project/component pair in Jira (say, 'COMPOSE', and 'Pungi').
|
| |
- %endif
|
| |
|
| |
%prep
|
| |
%setup -q -n %{modname}-%{upstream_version}
|
| |
@@ -103,40 +65,23 @@
|
| |
rm -rf *.egg*
|
| |
|
| |
%build
|
| |
- %py2_build
|
| |
- %if 0%{?with_python3}
|
| |
%py3_build
|
| |
- %endif
|
| |
|
| |
%install
|
| |
- %py2_install
|
| |
- %if 0%{?with_python3}
|
| |
%py3_install
|
| |
- %endif
|
| |
|
| |
%{__mkdir_p} %{buildroot}%{_unitdir}
|
| |
%{__install} -pm644 systemd/sync2jira.service \
|
| |
%{buildroot}%{_unitdir}/sync2jira.service
|
| |
|
| |
%check
|
| |
- %{__python2} setup.py test
|
| |
- %if 0%{?with_python3}
|
| |
%{__python3} setup.py test
|
| |
- %endif
|
| |
-
|
| |
- %files -n python2-%{modname}
|
| |
- %doc README.rst
|
| |
- %license LICENSE
|
| |
- %{python2_sitelib}/%{modname}/
|
| |
- %{python2_sitelib}/%{modname}-*.egg*
|
| |
|
| |
- %if 0%{?with_python3}
|
| |
%files -n python3-%{modname}
|
| |
%doc README.rst
|
| |
%license LICENSE
|
| |
%{python3_sitelib}/%{modname}/
|
| |
%{python3_sitelib}/%{modname}-*.egg*
|
| |
- %endif
|
| |
|
| |
# If built with py3, provide executables in py3 subpackage
|
| |
%{_bindir}/sync2jira
|
| |
A couple different changes in here.