Skip to content

Commit b0fa2e7

Browse files
committedApr 30, 2020
Add spec file
I want to be able to install 'git-pw' from the Fedora repos. However, all my experiments to date have attempted to use pyp2rpm and have failed. Add our own handwritten specfile, which is mostly the output of 'pyp2rpm git-pw' but with the description modified to strip out rST noise, the man pages installed and the requirements modified to use ranges instead of the compatible operator (which RPM doesn't support). Signed-off-by: Stephen Finucane <stephen@that.guru>
1 parent 0179765 commit b0fa2e7

File tree

2 files changed

+54
-6
lines changed

2 files changed

+54
-6
lines changed
 

‎.gitignore

-6
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,6 @@ var/
2424
.installed.cfg
2525
*.egg
2626

27-
# PyInstaller
28-
# Usually these files are written by a python script from a template
29-
# before PyInstaller builds the exe, so as to inject date/other infos into it.
30-
*.manifest
31-
*.spec
32-
3327
# SublimeText
3428
*.sublime-project
3529
*.sublime-workspace

‎rpm/git-pw.spec

+54
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
%global name git-pw
2+
%define version 1.9.0
3+
4+
Name: %{name}
5+
Version: %{version}
6+
Release: 1%{?dist}
7+
Summary: Git-Patchwork integration tool
8+
9+
License: MIT
10+
URL: https://github.com/getpatchwork/git-pw
11+
Source0: https://github.com/getpatchwork/git-pw/releases/download/%{version}/%{name}-%{version}.tar.gz
12+
13+
BuildArch: noarch
14+
15+
BuildRequires: python3-devel
16+
BuildRequires: python3-pbr
17+
BuildRequires: python3-setuptools
18+
19+
Requires: git
20+
Requires: python3-arrow
21+
Requires: python3-click
22+
Requires: python3-requests
23+
Requires: python3-setuptools
24+
Requires: python3-six
25+
Requires: python3-tabulate
26+
27+
%description
28+
git-pw is a tool for integrating Git with Patchwork, the web-based patch \
29+
tracking system.
30+
31+
%prep
32+
%autosetup -n %{name}-%{version}
33+
# Remove bundled egg-info
34+
rm -rf %{name}.egg-info
35+
36+
%build
37+
%py3_build
38+
39+
%install
40+
%py3_install
41+
mkdir -p %{buildroot}%{_mandir}/man1
42+
install -p -D -m 644 man/*.1 %{buildroot}%{_mandir}/man1/
43+
44+
%files
45+
%license LICENSE
46+
%doc README.rst
47+
%{_bindir}/git-pw
48+
%{_mandir}/man1/git-pw*.1.gz
49+
%{python3_sitelib}/git_pw/
50+
%{python3_sitelib}/git_pw-%{version}-py%{python3_version}*.egg-info
51+
52+
%changelog
53+
* Sun Apr 26 2020 Stephen Finucane <stephen@that.guru> - 1.9.0-1
54+
- Initial package.

0 commit comments

Comments
 (0)