]> git.pld-linux.org Git - packages/rpm-build-macros.git/commitdiff
- escaping for systemd macros
authorElan Ruusamäe <glen@pld-linux.org>
Sun, 4 Dec 2011 00:01:59 +0000 (00:01 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    rpm-build-macros.spec -> 1.302
    rpm.macros -> 1.622

rpm-build-macros.spec
rpm.macros

index d1f469e4a0ff48826bc42974c328a96435209600..13ccf9b7f4b09607078d76c0b043c068e1b19f18 100644 (file)
@@ -1,4 +1,4 @@
-%define                rpm_macros_rev  1.620
+%define                rpm_macros_rev  1.622
 %define                find_lang_rev   1.35
 Summary:       PLD Linux RPM build macros
 Summary(pl.UTF-8):     Makra do budowania pakietów RPM dla Linuksa PLD
index 4af2ad8713be5c23333e2ab0bbb0929f5068a8b2..eb68d2168472c349502dca8f4ae449bb1890a1d5 100644 (file)
@@ -2052,10 +2052,10 @@ else: \
 #
 # Sample:
 # %post systemd
-# %systemd_post %{name}
+# %systemd_post
 # or if service must be enabled by default:
 # %post systemd
-# %systemd_post %{name}
+# %systemd_post
 # %systemd_enable %{name}
 #
 # %preun systemd
@@ -2065,33 +2065,29 @@ else: \
 # %systemd_postun %{name}
 #
 # Requirements:
-# BuildRequires: rpmbuild(macros) >= 1.620
+# BuildRequires: rpmbuild(macros) >= 1.622
 # Requires:     rc-scripts >= ...
 
-%systemd_enable() {
-if [ $1 -eq 1 ] ; then 
-    /bin/systemctl enable %1 >/dev/null 2>&1 || : \
-fi \
-}
+%systemd_enable() \
+       if [ $1 -eq 1 ]; then  \
+               /bin/systemctl enable %1 >/dev/null 2>&1 || : \
+       fi
 
-%systemd_post() {
-if [ $1 -eq 1 ] ; then 
-    /bin/systemctl daemon-reload >/dev/null 2>&1 || : \
-fi \
-}
+%systemd_post() \
+       if [ $1 -eq 1 ]; then \
+               /bin/systemctl daemon-reload >/dev/null 2>&1 || : \
+       fi
 
-%systemd_preun() {
-if [ $1 -eq 0 ] ; then \
-    /bin/systemctl --no-reload disable %1 > /dev/null 2>&1 || : \
-    /bin/systemctl stop %1 > /dev/null 2>&1 || : \
-fi \
-}
-                    
-%systemd_postun() {
+%systemd_preun() \
+       if [ $1 -eq 0 ]; then \
+               /bin/systemctl --no-reload disable %1 > /dev/null 2>&1 || : \
+               /bin/systemctl stop %1 > /dev/null 2>&1 || : \
+       fi
+
+%systemd_postun() \
     /bin/systemctl daemon-reload >/dev/null 2>&1 || : \
-    if [ $1 -ge 1 ] ; then \
-    /bin/systemctl try-restart %1 >/dev/null 2>&1 || : \
-fi \
-}
+    if [ $1 -ge 1 ]; then \
+               /bin/systemctl try-restart %1 >/dev/null 2>&1 || : \
+       fi
 
 # EOF
This page took 0.1003 seconds and 4 git commands to generate.