1 %define module git_slug
2 Summary: Tools to interact with PLD Linux git repositories
3 Summary(pl.UTF-8): Narzędzia do pracy z repozytoriami gita w PLD Linuksa
8 Group: Development/Building
9 Source0: %{name}-%{version}.tar.gz
10 # Source0-md5: 94d40c83999c0ea1d085fb436beede19
11 Source1: slug_watch.init
13 Source3: slug_watch.sysconfig
14 Source4: slug_watch-cron
15 URL: https://git.pld-linux.org/gitweb.cgi/?p=projects/git-slug.git;a=summary
16 BuildRequires: asciidoc
17 BuildRequires: docbook-dtd45-xml
18 BuildRequires: git-core >= 2.7.1-3
19 BuildRequires: python3-modules >= 1:3.3.0
20 BuildRequires: rpm-pythonprov
21 BuildRequires: rpmbuild(macros) >= 1.714
24 Requires: python3-modules
25 Suggests: openssh-clients
28 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
30 %define gitcoredir %(git --exec-path)
33 Python tools to interact with PLD Linux git repositories.
35 %description -l pl.UTF-8
36 Narzędzia w Pythonie do pracy z repozytoriami gita w PLD.
39 Summary: Daemon to update Refs repository for git-slug
40 Summary(pl.UTF-8): Demon uaktualniający repozytorium Refs dla git-slug
41 Group: Development/Building
42 Requires(post,preun): /sbin/chkconfig
43 Requires: git-core-slug
44 Requires: pld-gitolite
45 Requires: python3-pyinotify
50 Daemon to update Refs repository for git-slug. It is to be run on PLD
53 %description watch -l pl.UTF-8
54 Demon uaktualniający repozytorium Refs dla git-slug. Jest przeznaczony
55 do uruchamiania na serwerze gitolite PLD.
65 rm -rf $RPM_BUILD_ROOT
67 --install-data=/home/services/git \
69 %{__make} man-install \
70 DESTDIR=$RPM_BUILD_ROOT
72 install -d $RPM_BUILD_ROOT%{gitcoredir}
73 ln -s %{_bindir}/slug.py $RPM_BUILD_ROOT%{gitcoredir}/git-pld
74 echo ".so slug.py.1" > $RPM_BUILD_ROOT%{_mandir}/man1/git-pld.1
76 install -Dp %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/slug_watch
77 install -d $RPM_BUILD_ROOT/home/services/git/.gitolite/hooks/common
78 cp -rp post-receive.python.d $RPM_BUILD_ROOT/home/services/git/.gitolite/hooks/common
79 install -d $RPM_BUILD_ROOT/home/services/git/{watchdir,Refs}
80 touch $RPM_BUILD_ROOT/home/services/git/{watchdir,Refs}
82 install -Dp %{SOURCE2} $RPM_BUILD_ROOT/etc/cron.d/slug_watch
83 install -Dp %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/slug_watch
84 install -Dp %{SOURCE4} $RPM_BUILD_ROOT%{_bindir}
87 rm -rf $RPM_BUILD_ROOT
90 /sbin/chkconfig --add slug_watch
91 %service slug_watch restart
94 if [ "$1" = "0" ]; then
95 %service -q slug_watch stop
96 /sbin/chkconfig --del slug_watch
100 %defattr(644,root,root,755)
102 %attr(755,root,root) %{_bindir}/slug.py
103 %{gitcoredir}/git-pld
104 %{_mandir}/man1/git-pld.1*
105 %{_mandir}/man1/slug.py.1*
106 %{py3_sitescriptdir}/%{module}
107 %{py3_sitescriptdir}/git_core_slug-*.egg-info
110 %defattr(644,root,root,755)
111 %attr(755,root,root) %{_bindir}/slug_watch
112 %attr(755,root,root) %{_bindir}/slug_watch-cron
113 %attr(754,root,root) /etc/rc.d/init.d/slug_watch
114 %config(noreplace) %verify(not md5 mtime size) /etc/cron.d/slug_watch
115 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/slug_watch
116 %{py3_sitescriptdir}/Daemon
118 %defattr(644,git,git,755)
119 %attr(755,git,git) /home/services/git/adc/bin/trash
120 %attr(755,git,git) /home/services/git/adc/bin/move
121 /home/services/git/adc/bin/copy
122 %dir /home/services/git/.gitolite/hooks/common/post-receive.python.d
123 /home/services/git/.gitolite/hooks/common/post-receive.python.d/slug_hook.py
124 %dir /home/services/git/watchdir
125 %dir /home/services/git/Refs