@@ -7,10 +7,11 @@ Group: Development/Tools/Other
7
7
URL: https://github.com/dmach/git-obs-hooks
8
8
Source: https://github.com/dmach/git-obs-hooks/archive/refs/tags/%{version }.tar.gz#/%{name}-%{version}.tar.gz
9
9
10
+ BuildRequires: fdupes
10
11
BuildArch: noarch
11
12
BuildRoot: %{_tmppath }/%{name }-%{version }-build
12
13
13
- %define hook_dir %{_datarootdir }/git-obs-hooks
14
+ %define hook_dir %{_datadir }/git-obs-hooks
14
15
15
16
%description
16
17
Framework for running git hooks in git-obs and osc.
@@ -22,9 +23,21 @@ To enable git-obs-hooks in the current git repo, run: install-git-obs-hooks
22
23
23
24
See githooks(5) man page for more help on the hooks.
24
25
26
+ %package script-convert-changes
27
+ Summary: working script for %{name } converting last record of *.changes to git commit
28
+ Requires: %{name } = %{version }
29
+
30
+ %description script-convert-changes
31
+ Working script for %{name }, which causes `git commit` to generate
32
+ default commit message based on the last last record in the
33
+ `*.changes`.
34
+
25
35
%prep
26
36
%autosetup -p1
27
37
38
+ %build
39
+ :
40
+
28
41
%install
29
42
install -D install-git-obs-hooks %{buildroot }%{_bindir }/install-git-obs-hooks
30
43
@@ -70,6 +83,12 @@ install -D git-obs-hook-template %{buildroot}%{hook_dir}/sendemail-validate
70
83
install -d %{buildroot }%{hook_dir }/update.d
71
84
install -D git-obs-hook-template %{buildroot }%{hook_dir }/update
72
85
86
+ for scriptlet in scripts/*/*.sh ; do
87
+ cp -p "${scriptlet}" "%{buildroot }%{hook_dir }/${scriptlet#*/}"
88
+ done
89
+
90
+ %fdupes %{buildroot }%{hook_dir }
91
+
73
92
%files
74
93
%defattr(-,root,root,-)
75
94
%attr(0755, root, root) %{_bindir }/install-git-obs-hooks
@@ -92,4 +111,7 @@ install -D git-obs-hook-template %{buildroot}%{hook_dir}/update
92
111
%license LICENSE
93
112
%doc README.md
94
113
114
+ %files script-convert-changes
115
+ %{hook_dir }/prepare-commit-msg.d
116
+
95
117
%changelog
0 commit comments