diff options
author | Luka Perkov <luka@openwrt.org> | 2013-12-09 11:30:14 +0000 |
---|---|---|
committer | Luka Perkov <luka@openwrt.org> | 2013-12-09 11:30:14 +0000 |
commit | 3ceb6b3274d75fb5dc05b9eb42f2a98ee445f122 (patch) | |
tree | 30f8751c74750a210d9321522993e8fa17ffcd1c /package/base-files/files/lib/functions | |
parent | 18dd10190370853c3efc10b33711313a3ecb9a09 (diff) | |
download | mtk-20170518-3ceb6b3274d75fb5dc05b9eb42f2a98ee445f122.zip mtk-20170518-3ceb6b3274d75fb5dc05b9eb42f2a98ee445f122.tar.gz mtk-20170518-3ceb6b3274d75fb5dc05b9eb42f2a98ee445f122.tar.bz2 |
base-files: fix whitespaces
Signed-off-by: Luka Perkov <luka@openwrt.org>
SVN-Revision: 39006
Diffstat (limited to 'package/base-files/files/lib/functions')
-rw-r--r-- | package/base-files/files/lib/functions/network.sh | 18 | ||||
-rw-r--r-- | package/base-files/files/lib/functions/service.sh | 39 |
2 files changed, 27 insertions, 30 deletions
diff --git a/package/base-files/files/lib/functions/network.sh b/package/base-files/files/lib/functions/network.sh index ead69aa..0ff11c3 100644 --- a/package/base-files/files/lib/functions/network.sh +++ b/package/base-files/files/lib/functions/network.sh @@ -222,7 +222,7 @@ __network_ipaddr() # determine first IPv4 address of given logical interface # 1: destination variable # 2: interface -network_get_ipaddr() { __network_ipaddr "$1" "$2" "address4" "%%/*" 0; } +network_get_ipaddr() { __network_ipaddr "$1" "$2" "address4" "%%/*" 0; } # determine first IPv6 address of given logical interface # 1: destination variable @@ -232,7 +232,7 @@ network_get_ipaddr6() { __network_ipaddr "$1" "$2" "address6" "%%/*" 0; } # determine first IPv4 subnet of given logical interface # 1: destination variable # 2: interface -network_get_subnet() { __network_ipaddr "$1" "$2" "address4" "%% *" 0; } +network_get_subnet() { __network_ipaddr "$1" "$2" "address4" "%% *" 0; } # determine first IPv6 subnet of given logical interface # 1: destination variable @@ -247,7 +247,7 @@ network_get_prefix6() { __network_ipaddr "$1" "$2" "prefix6" "%% *" 0; } # determine all IPv4 addresses of given logical interface # 1: destination variable # 2: interface -network_get_ipaddrs() { __network_ipaddr "$1" "$2" "address4" "%%/*" 1; } +network_get_ipaddrs() { __network_ipaddr "$1" "$2" "address4" "%%/*" 1; } # determine all IPv6 addresses of given logical interface # 1: destination variable @@ -257,7 +257,7 @@ network_get_ipaddrs6() { __network_ipaddr "$1" "$2" "address6" "%%/*" 1; } # determine all IPv4 subnets of given logical interface # 1: destination variable # 2: interface -network_get_subnets() { __network_ipaddr "$1" "$2" "address4" "" 1; } +network_get_subnets() { __network_ipaddr "$1" "$2" "address4" "" 1; } # determine all IPv6 subnets of given logical interface # 1: destination variable @@ -292,9 +292,9 @@ __network_gateway() # 1: destination variable # 2: interface # 3: consider inactive gateway if "true" (optional) -network_get_gateway() { __network_gateway "$1" "$2" 4 "${3:-0}"; } +network_get_gateway() { __network_gateway "$1" "$2" 4 "${3:-0}"; } -# determine IPv6 gateway of given logical interface +# determine IPv6 gateway of given logical interface # 1: destination variable # 2: interface # 3: consider inactive gateway if "true" (optional) @@ -354,7 +354,7 @@ __network_wan() # find the logical interface which holds the current IPv4 default route # 1: destination variable # 2: consider inactive default routes if "true" (optional) -network_find_wan() { __network_wan "$1" 4 "${2:-0}"; } +network_find_wan() { __network_wan "$1" 4 "${2:-0}"; } # find the logical interface which holds the current IPv6 default route # 1: destination variable @@ -384,12 +384,12 @@ network_is_up() # determine the layer 3 linux network device of the given logical interface # 1: destination variable # 2: interface -network_get_device() { __network_device "$1" "$2" l3_device; } +network_get_device() { __network_device "$1" "$2" l3_device; } # determine the layer 2 linux network device of the given logical interface # 1: destination variable # 2: interface -network_get_physdev() { __network_device "$1" "$2" device; } +network_get_physdev() { __network_device "$1" "$2" device; } __network_defer() diff --git a/package/base-files/files/lib/functions/service.sh b/package/base-files/files/lib/functions/service.sh index cbb717d..d352a44 100644 --- a/package/base-files/files/lib/functions/service.sh +++ b/package/base-files/files/lib/functions/service.sh @@ -4,27 +4,27 @@ # Usage: service ACTION EXEC ARGS... # # Action: -# -C check if EXEC is alive -# -S start EXEC, passing it ARGS as its arguments -# -K kill EXEC, sending it a TERM signal if not specified otherwise +# -C check if EXEC is alive +# -S start EXEC, passing it ARGS as its arguments +# -K kill EXEC, sending it a TERM signal if not specified otherwise # # Environment variables exposed: -# SERVICE_DAEMONIZE run EXEC in background -# SERVICE_WRITE_PID create a pid-file and use it for matching -# SERVICE_MATCH_EXEC use EXEC command-line for matching (default) -# SERVICE_MATCH_NAME use EXEC process name for matching -# SERVICE_USE_PID assume EXEC create its own pid-file and use it for matching -# SERVICE_NAME process name to use (default to EXEC file part) -# SERVICE_PID_FILE pid file to use (default to /var/run/$SERVICE_NAME.pid) -# SERVICE_SIG signal to send when using -K -# SERVICE_SIG_RELOAD default signal used when reloading -# SERVICE_SIG_STOP default signal used when stopping -# SERVICE_STOP_TIME time to wait for a process to stop gracefully before killing it -# SERVICE_UID user EXEC should be run as -# SERVICE_GID group EXEC should be run as +# SERVICE_DAEMONIZE run EXEC in background +# SERVICE_WRITE_PID create a pid-file and use it for matching +# SERVICE_MATCH_EXEC use EXEC command-line for matching (default) +# SERVICE_MATCH_NAME use EXEC process name for matching +# SERVICE_USE_PID assume EXEC create its own pid-file and use it for matching +# SERVICE_NAME process name to use (default to EXEC file part) +# SERVICE_PID_FILE pid file to use (default to /var/run/$SERVICE_NAME.pid) +# SERVICE_SIG signal to send when using -K +# SERVICE_SIG_RELOAD default signal used when reloading +# SERVICE_SIG_STOP default signal used when stopping +# SERVICE_STOP_TIME time to wait for a process to stop gracefully before killing it +# SERVICE_UID user EXEC should be run as +# SERVICE_GID group EXEC should be run as # -# SERVICE_DEBUG don't do anything, but show what would be done -# SERVICE_QUIET don't print anything +# SERVICE_DEBUG don't do anything, but show what would be done +# SERVICE_QUIET don't print anything # SERVICE_QUIET=1 @@ -124,6 +124,3 @@ __END_OF_WARNING__ while grep -qs "$name" "/proc/$pid/cmdline"; do sleep 1; done done } - - - |