[projects/rc-scripts] Use is_yes, so ONBOOT can be on, yes etc.

arekm arekm at pld-linux.org
Mon Nov 6 11:59:17 CET 2017


commit cf38a080eb13e798c5a1abe84e941e614dc78e52
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date:   Mon Nov 6 11:59:13 2017 +0100

    Use is_yes, so ONBOOT can be on, yes etc.

 rc.d/init.d/network | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)
---
diff --git a/rc.d/init.d/network b/rc.d/init.d/network
index 3592a2b4..960c9a06 100755
--- a/rc.d/init.d/network
+++ b/rc.d/init.d/network
@@ -143,7 +143,7 @@ find_boot_interfaces() {
 				DEVICE=""; ONBOOT=""; USERS=""; . "$i" 2>/dev/null
 				[ "${DEVICE:+set}" != "set" ] && continue
 				[ ${USERS:-no} != no ] && continue
-				[ ${ONBOOT:-no} = yes ] && echo "${i##*/ifcfg-}"
+				is_yes ${ONBOOT:-no} && echo "${i##*/ifcfg-}"
 			done
 		`
 	else
@@ -155,7 +155,7 @@ find_boot_interfaces() {
 				DEVICE=""; ONBOOT=""; USERS=""; . "$i" 2>/dev/null
 				[ "${DEVICE:+set}" != "set" ] && continue
 				[ ${USERS:-no} != no ] && continue
-				[ ${ONBOOT:-no} = yes ] && echo "${i##*/ifcfg-}"
+				is_yes ${ONBOOT:-no} && echo "${i##*/ifcfg-}"
 			done
 		`
 
@@ -168,7 +168,7 @@ find_boot_interfaces() {
 				DEVICE=""; ONBOOT=""; USERS=""; . "$i" 2>/dev/null
 				[ "${DEVICE:+set}" != "set" ] && continue
 				[ ${USERS:-no} != no ] && continue
-				[ ${ONBOOT:-no} = yes ] && echo "${i##*/ifcfg-}"
+				is_yes [ ${ONBOOT:-no} && echo "${i##*/ifcfg-}"
 			done
 		`
 
@@ -181,7 +181,7 @@ find_boot_interfaces() {
 				DEVICE=""; ONBOOT=""; USERS=""; . "$i" 2>/dev/null
 				[ "${DEVICE:+set}" != "set" ] && continue
 				[ ${USERS:-no} != no ] && continue
-				[ ${ONBOOT:-no} = yes ] && echo "${i##*/ifcfg-}"
+				is_yes ${ONBOOT:-no} && echo "${i##*/ifcfg-}"
 			done
 		`
 
@@ -194,7 +194,7 @@ find_boot_interfaces() {
 				DEVICE=""; ONBOOT=""; USERS=""; . "$i" 2>/dev/null
 				[ "${DEVICE:+set}" != "set" ] && continue
 				[ ${USERS:-no} != no ] && continue
-				[ ${ONBOOT:-no} = yes ] && echo "${i##*/ifcfg-}"
+				is_yes ${ONBOOT:-no} && echo "${i##*/ifcfg-}"
 			done
 		`
 
@@ -207,7 +207,7 @@ find_boot_interfaces() {
 				DEVICE=""; ONBOOT=""; USERS=""; . "$i" 2>/dev/null
 				[ "${DEVICE:+set}" != "set" ] && continue
 				[ ${USERS:-no} != no ] && continue
-				[ ${ONBOOT:-no} = yes ] && echo "${i##*/ifcfg-}"
+				is_yes ${ONBOOT:-no} && echo "${i##*/ifcfg-}"
 			done
 		`
 	fi
@@ -217,7 +217,7 @@ find_boot_interfaces() {
 			DEVICE=""; ONBOOT=""; USERS=""; . "$i" 2>/dev/null
 			[ "${DEVICE:+set}" != "set" ] && continue
 			[ ${USERS:-no} != no ] && continue
-			[ ${ONBOOT:-no} = yes ] && echo "${i##*/tnlcfg-}"
+			is_yes ${ONBOOT:-no} && echo "${i##*/tnlcfg-}"
 		done
 	)
 }
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/projects/rc-scripts.git/commitdiff/cf38a080eb13e798c5a1abe84e941e614dc78e52



More information about the pld-cvs-commit mailing list