SOURCES (AC-branch): rpm.macros, rpm.macros - allow specify nice n...

glen glen at pld-linux.org
Sat Oct 22 21:11:26 CEST 2005


Author: glen                         Date: Sat Oct 22 19:11:25 2005 GMT
Module: SOURCES                       Tag: AC-branch
---- Log message:
- allow specify nice name for %service macro for the service, as third argument (in shell syntax)

---- Files affected:
SOURCES:
   rpm.macros (1.158.4.67 -> 1.158.4.68) 
SOURCES:
   rpm.macros (1.245 -> 1.246) 

---- Diffs:

================================================================
Index: SOURCES/rpm.macros
diff -u SOURCES/rpm.macros:1.158.4.67 SOURCES/rpm.macros:1.158.4.68
--- SOURCES/rpm.macros:1.158.4.67	Sat Oct 15 19:50:08 2005
+++ SOURCES/rpm.macros	Sat Oct 22 21:11:20 2005
@@ -777,7 +777,7 @@
 # All rights reserved. Permission to copy is hereby granted.. yada, yada, yada
 #
 # Usage:
-#   %service [-q] SERVICE ACTION
+#   %service [-q] SERVICE ACTION ["SERVICE NICE DESCRIPTION"]
 #
 #  -q be silent when service isn't started (for postun scriplets)
 #
@@ -792,10 +792,10 @@
 	if [ $(skip_auto_restart) = no ]; then \
 		/etc/rc.d/init.d/%1 %2 1>&2; \
 	else \
-		echo 'Run "/etc/rc.d/init.d/%1 %2" to %2 %1 service.'; \
+		echo 'Run "/etc/rc.d/init.d/%1 %2" to %2 %{!?3:%1 service}%{?3:%(set -- %{*}; echo "$3")}.'; \
 	fi \
 else \
-	%{!-q:echo 'Run "/etc/rc.d/init.d/%1 start" to start %1 service.';} \
+	%{!-q:echo 'Run "/etc/rc.d/init.d/%1 start" to start %{!?3:%1 service}%{?3:%(set -- %{*}; echo "$3")}.';} \
 	%{-q::;} \
 fi }; }
 

================================================================
Index: SOURCES/rpm.macros
diff -u SOURCES/rpm.macros:1.245 SOURCES/rpm.macros:1.246
--- SOURCES/rpm.macros:1.245	Sat Oct 15 19:50:09 2005
+++ SOURCES/rpm.macros	Sat Oct 22 21:11:20 2005
@@ -778,7 +778,7 @@
 # All rights reserved. Permission to copy is hereby granted.. yada, yada, yada
 #
 # Usage:
-#   %service [-q] SERVICE ACTION
+#   %service [-q] SERVICE ACTION ["SERVICE NICE DESCRIPTION"]
 #
 #  -q be silent when service isn't started (for postun scriplets)
 #
@@ -793,10 +793,10 @@
 	if [ $(skip_auto_restart) = no ]; then \
 		/etc/rc.d/init.d/%1 %2 1>&2; \
 	else \
-		echo 'Run "/etc/rc.d/init.d/%1 %2" to %2 %1 service.'; \
+		echo 'Run "/etc/rc.d/init.d/%1 %2" to %2 %{!?3:%1 service}%{?3:%(set -- %{*}; echo "$3")}.'; \
 	fi \
 else \
-	%{!-q:echo 'Run "/etc/rc.d/init.d/%1 start" to start %1 service.';} \
+	%{!-q:echo 'Run "/etc/rc.d/init.d/%1 start" to start %{!?3:%1 service}%{?3:%(set -- %{*}; echo "$3")}.';} \
 	%{-q::;} \
 fi }; }
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SOURCES/rpm.macros?r1=1.158.4.67&r2=1.158.4.68&f=u
    http://cvs.pld-linux.org/SOURCES/rpm.macros?r1=1.245&r2=1.246&f=u




More information about the pld-cvs-commit mailing list