1 %define plugin datatemplate
2 %define php_min_version 5.1.0
3 %include /usr/lib/rpm/macros.php
4 Summary: DokuWiki plugin to add template capabilities to the data plugin
5 Name: dokuwiki-plugin-%{plugin}
9 Group: Applications/WWW
10 Source0: https://github.com/ccl/dokuwiki-plugin-datatemplate/tarball/master#/%{plugin}.tgz
11 # Source0-md5: 24fa802fa2cc5a3b6337fe24f1b75a18
12 URL: http://www.dokuwiki.org/plugin:datatemplate
13 BuildRequires: rpm-php-pearprov >= 4.4.2-11
14 BuildRequires: rpmbuild(macros) >= 1.520
15 Requires: dokuwiki >= 20090214
16 Requires: dokuwiki-plugin-data
17 Requires: php-common >= 4:%{php_min_version}
20 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22 %define dokuconf /etc/webapps/dokuwiki
23 %define dokudir /usr/share/dokuwiki
24 %define plugindir %{dokudir}/lib/plugins/%{plugin}
26 # this is data plugin dependency
27 %define _noautophp php-sqlite
29 # put it together for rpmbuild
30 %define _noautoreq %{?_noautophp} %{?_noautopear}
33 This plugin adds the possibility to display the structered data of the
34 data plugin using templates. Templates can be applied to individual
35 data entries or lists of multiple entries. Additionally, this plugin
36 offers a custom search form, pagination and result caching.
41 rm *-%{plugin}-*/.gitignore
43 version=$(awk '/^date/{print $2}' plugin.info.txt)
44 if [ "$(echo "$version" | tr -d -)" != %{version} ]; then
45 : %%{version} mismatch
50 rm -rf $RPM_BUILD_ROOT
51 install -d $RPM_BUILD_ROOT%{plugindir}
52 cp -a . $RPM_BUILD_ROOT%{plugindir}
55 rm -rf $RPM_BUILD_ROOT
57 # use this post section if you package .css or .js files
59 # force js/css cache refresh
60 if [ -f %{dokuconf}/local.php ]; then
61 touch %{dokuconf}/local.php
65 %defattr(644,root,root,755)