From: Hugo Villeneuve Date: Sun, 18 May 2014 22:34:18 +0000 (-0400) Subject: Fix trailing whitespace X-Git-Url: http://gitweb.hugovil.com/?a=commitdiff_plain;h=ff51e86b74e8e6256f01eca359b5b7b8c570b68d;p=hvlinux.git Fix trailing whitespace --- diff --git a/stage1/bootscripts/functions b/stage1/bootscripts/functions index 7db7545..f7dfc18 100644 --- a/stage1/bootscripts/functions +++ b/stage1/bootscripts/functions @@ -19,7 +19,7 @@ if [ -z "${COLUMNS}" ]; then fi # When using remote connections, such as a serial port, stty size returns 0 -if [ "${COLUMNS}" = "0" ]; then +if [ "${COLUMNS}" = "0" ]; then COLUMNS=80 fi @@ -76,7 +76,7 @@ print_status() echo "Usage: print_status {success|warning|failure}" return ${EXIT_CODE_FAILURE} fi - + case "$1" in success) ${SUCCESS} @@ -268,7 +268,7 @@ loadproc() pid="${pid} ${apid}" fi done - + # If the $pid variable contains anything (from the previous for loop) it # means the daemon is already running. if [ ! -n "${pid}" ]; then @@ -301,7 +301,7 @@ killproc() fi killproc_path ${1} /var/run ${2} - + return ${?} } @@ -316,7 +316,7 @@ killproc_path() msg_log "Usage: killproc_path {program} {pid-directory} [signal]" return ${EXIT_CODE_FAILURE} fi - + # Find the basename of the first parameter (the daemon's name without the # path). base=$(/usr/bin/basename ${1}) @@ -330,7 +330,7 @@ killproc_path() else nolevel=1 fi - + # The pidlist variable will contains the output of the pidof command. pidof # will try to find the PID's that belong to a certain string; $base in this # case. @@ -342,7 +342,7 @@ killproc_path() pid="${pid} ${apid}" fi done - + # If $pid contains something from the previous for loop it means one or # more PID's were found that belongs to the processes to be killed. if [ -n "${pid}" ]; then @@ -414,7 +414,7 @@ reloadproc() msg_log "Usage: reloadproc {program} [signal]" return ${EXIT_CODE_FAILURE} fi - + # Find the basename of the first parameter (the daemon's name without # the path that was provided so /usr/sbin/syslogd becomes plain 'syslogd' # after basename ran). @@ -429,7 +429,7 @@ reloadproc() else killlevel="-SIGHUP" fi - + # The pidlist variable will contains the output of the pidof command. pidof # will try to find the PID's that belong to a certain string; $base in this # case. @@ -441,7 +441,7 @@ reloadproc() pid="${pid} ${apid}" fi done - + # If $pid contains something from the previous for loop it means one or # more PID's were found that belongs to the processes to be reloaded. if [ -n "${pid}" ]; then @@ -458,7 +458,7 @@ reloadproc() msg_log "Not running" return ${EXIT_CODE_WARNING} fi - + return ${EXIT_CODE_SUCCESS} } @@ -474,7 +474,7 @@ statusproc() fi statusproc_path ${1} /var/run - + return ${?} } @@ -489,7 +489,7 @@ statusproc_path() msg_log "Usage: status {program} {pid-directory}" return ${EXIT_CODE_FAILURE} fi - + # Find the basename of the first parameter (the daemon's name without the # path). base=$(/usr/bin/basename ${1}) diff --git a/stage1/bootscripts/rc b/stage1/bootscripts/rc index 1d0a721..a85b893 100755 --- a/stage1/bootscripts/rc +++ b/stage1/bootscripts/rc @@ -43,12 +43,12 @@ check_script_status() echo "$1 is not a valid symlink" return ${EXIT_CODE_FAILURE} fi - + if [ ! -x $1 ]; then echo "$1 is not executable, skipping" return ${EXIT_CODE_FAILURE} fi - + return ${EXIT_CODE_SUCCESS} } @@ -81,14 +81,14 @@ if [ ! -d /etc/rc.d/rc${runlevel}.d ]; then fi # First, attempt to stop all services started by previous runlevel, -# and killed in this runlevel (K8 scripts +# and killed in this runlevel (K* scripts # If so, first collect all the K* scripts in the new run level. if [ ${previous} != N ]; then for kill_script in $(ls /etc/rc.d/rc${runlevel}.d/K* 2> /dev/null); do if [ -f ${kill_script} ]; then # "suffix" will contain the script name without the leading Kxx. suffix="${kill_script##*/K[0-9][0-9]}" - + # If there is a S script in the previous runlevel corresponding # to this K script, determine what it's full path is. previous_start="/etc/rc.d/rc${previous}.d/S[0-9][0-9]${suffix}"