]>
Commit | Line | Data |
---|---|---|
ef792ce5 ER |
1 | %define plugin eventum |
2 | Summary: DokuWiki Eventum Plugin | |
3 | Summary(pl.UTF-8): Wtyczka Include (dołączania) dla Eventum | |
4 | Name: dokuwiki-plugin-%{plugin} | |
642c4c93 | 5 | Version: 20101105 |
242a2a01 | 6 | Release: 1 |
ef792ce5 | 7 | License: GPL v2 |
642c4c93 ER |
8 | Source0: http://github.com/glensc/%{name}/zipball/master#/%{plugin}.zip |
9 | # Source0-md5: 28fb65873bec4a3456245dc57282edc9 | |
ef792ce5 | 10 | Group: Applications/WWW |
4e634456 ER |
11 | URL: http://www.dokuwiki.org/plugin:eventum |
12 | BuildRequires: rpmbuild(macros) >= 1.520 | |
242a2a01 | 13 | Requires: dokuwiki >= 20080505 |
28ff99ea | 14 | Requires: php-pear-XML_RPC |
ef792ce5 ER |
15 | BuildArch: noarch |
16 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
17 | ||
642c4c93 | 18 | %define dokuconf /etc/webapps/dokuwiki |
ef792ce5 ER |
19 | %define dokudir /usr/share/dokuwiki |
20 | %define plugindir %{dokudir}/lib/plugins/%{plugin} | |
4e634456 | 21 | %define find_lang %{_usrlibrpm}/dokuwiki-find-lang.sh %{buildroot} |
ef792ce5 ER |
22 | |
23 | %description | |
242a2a01 | 24 | Adds Eventum link button to edit toolbar. |
ef792ce5 | 25 | |
1cbc2090 ER |
26 | Also adds extra info to Eventum interwiki links fetched from Eventum |
27 | via XML_RPC. | |
28ff99ea | 28 | |
ef792ce5 | 29 | %prep |
4e634456 ER |
30 | %setup -qc |
31 | mv *-%{plugin}-*/* . | |
642c4c93 | 32 | rm *-%{plugin}-*/.gitignore |
ef792ce5 | 33 | |
de06070b | 34 | version=$(awk '/date/{print $2}' plugin.info.txt) |
1cbc2090 ER |
35 | if [ "$(echo "$version" | tr -d -)" != %{version} ]; then |
36 | : %%{version} mismatch | |
37 | exit 1 | |
38 | fi | |
39 | ||
ef792ce5 ER |
40 | %install |
41 | rm -rf $RPM_BUILD_ROOT | |
42 | install -d $RPM_BUILD_ROOT%{plugindir} | |
43 | cp -a . $RPM_BUILD_ROOT%{plugindir} | |
4e634456 ER |
44 | |
45 | # find locales | |
46 | %find_lang %{name}.lang | |
ef792ce5 ER |
47 | |
48 | %clean | |
49 | rm -rf $RPM_BUILD_ROOT | |
50 | ||
642c4c93 ER |
51 | %post |
52 | # force js/css cache refresh | |
53 | if [ -f %{dokuconf}/local.php ]; then | |
54 | touch %{dokuconf}/local.php | |
55 | fi | |
56 | ||
4e634456 | 57 | %files -f %{name}.lang |
ef792ce5 ER |
58 | %defattr(644,root,root,755) |
59 | %dir %{plugindir} | |
60 | %{plugindir}/*.php | |
de06070b | 61 | %{plugindir}/*.txt |
642c4c93 | 62 | %{plugindir}/*.css |
4e634456 | 63 | %{plugindir}/conf |
642c4c93 | 64 | %{plugindir}/images |