[gnome-search-tool] Use GConf rpm macros instead of open coded scriplets

rtcm rtcm at fedoraproject.org
Mon Mar 12 14:02:56 UTC 2012


commit f02847ba26a0735c1cf7bd2c2ad1b0bc74787279
Author: Rui Matos <rmatos at redhat.com>
Date:   Mon Mar 12 15:00:53 2012 +0100

    Use GConf rpm macros instead of open coded scriplets

 gnome-search-tool.spec |   18 +++++++-----------
 1 files changed, 7 insertions(+), 11 deletions(-)
---
diff --git a/gnome-search-tool.spec b/gnome-search-tool.spec
index 59d5626..cd7db18 100644
--- a/gnome-search-tool.spec
+++ b/gnome-search-tool.spec
@@ -1,6 +1,6 @@
 Name:           gnome-search-tool
 Version:        3.3.1
-Release:        2%{?dist}
+Release:        3%{?dist}
 Summary:        Utility for finding files for GNOME
 
 License:        GPLv2+ and GFDL
@@ -51,20 +51,13 @@ desktop-file-validate $RPM_BUILD_ROOT%{_datadir}/applications/%{name}.desktop
 
 
 %pre
-if [ "$1" -gt 1 ]; then
-  export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source`
-  gconftool-2 --makefile-uninstall-rule %{_sysconfdir}/gconf/schemas/%{name}.schemas > /dev/null || :
-fi
+%gconf_schema_prepare %{name}
 
 %post
-export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source`
-gconftool-2 --makefile-install-rule %{_sysconfdir}/gconf/schemas/%{name}.schemas > /dev/null || :
+%gconf_schema_upgrade %{name}
 
 %preun
-if [ "$1" -eq 0 ]; then
-  export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source`
-  gconftool-2 --makefile-uninstall-rule %{_sysconfdir}/gconf/schemas/%{name}.schemas > /dev/null || :
-fi
+%gconf_schema_remove %{name}
 
 
 %files -f %{name}.lang
@@ -77,6 +70,9 @@ fi
 
 
 %changelog
+* Mon Mar 12 2012 Rui Matos <rmatos at redhat.com> - 3.3.1-3
+- Use GConf rpm macros instead of open coded scriplets
+
 * Mon Mar  5 2012 Rui Matos <rmatos at redhat.com> - 3.3.1-2
 - spec file cleanup
 


More information about the scm-commits mailing list