- added configuration autospliter
authorluzik <luzik@pld-linux.org>
Mon, 3 Nov 2008 13:25:11 +0000 (13:25 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    collectd.spec -> 1.49

collectd.spec

index 52428d0b7a50b9dcf932a16fae5604789c07e5b3..a1fa3c452fc812da07c4807aa17ae603241c228b 100644 (file)
@@ -798,6 +798,11 @@ install %{SOURCE3} $RPM_BUILD_ROOT%{_webappdir}/httpd.conf
 install %{SOURCE4} $RPM_BUILD_ROOT%{_webappdir}/lighttpd.conf
 
 ### Configs instalation ###
+for i in `egrep "^LoadPlugin" src/collectd.conf |awk '{print $NF}' ` ; do
+       egrep "LoadPlugin $i$" src/collectd.conf > $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/$i.conf
+       grep -v LoadPlugin src/collectd.conf |sed -e '/./{H;$!d;}' -e "x;/ $i>/!d;" >> $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/$i.conf
+done
+
 # Example config in sources: src/collectd.conf
 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.conf
 install %{SOURCE10} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/ascent.conf
This page took 0.042832 seconds and 4 git commands to generate.