projects
/
grml-etc-core.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
script-functions: adjusted reverse_list's and is_older_than's indention
[grml-etc-core.git]
/
etc
/
grml
/
script-functions
diff --git
a/etc/grml/script-functions
b/etc/grml/script-functions
index
0a389e9
..
659054c
100644
(file)
--- a/
etc/grml/script-functions
+++ b/
etc/grml/script-functions
@@
-146,17
+146,17
@@
mount_sys(){
# Returns the reversed order of list
#
reverse_list() {
# Returns the reversed order of list
#
reverse_list() {
-
local ret
-
ret=''
-
while [ "$#" -gt 0 ] ; do
-
if [ -z "${ret}" ] ; then
-
ret="$1"
-
else
-
ret="$1 ${ret}"
-
fi
-
shift
-
done
-
printf '%s' "${ret}"
+ local ret
+ ret=''
+ while [ "$#" -gt 0 ] ; do
+ if [ -z "${ret}" ] ; then
+ ret="$1"
+ else
+ ret="$1 ${ret}"
+ fi
+ shift
+ done
+ printf '%s' "${ret}"
}
#}}}
}
#}}}
@@
-167,19
+167,19
@@
reverse_list() {
#
# EXAMPLE: if is_older_than a.out *.o ; then ...
is_older_than() {
#
# EXAMPLE: if is_older_than a.out *.o ; then ...
is_older_than() {
-
local x
-
local ref="$1"
-
shift
+ local x
+ local ref="$1"
+ shift
-
for x in "$@" ; do
-
[ "${x}" -nt "${ref}" ] && return 0
+ for x in "$@" ; do
+ [ "${x}" -nt "${ref}" ] && return 0
-
if [ -d "${x}" ] ; then
-
is_older_than "${ref}" "${x}"/* && return 0
-
fi
-
done
+ if [ -d "${x}" ] ; then
+ is_older_than "${ref}" "${x}"/* && return 0
+ fi
+ done
-
return 1
+ return 1
}
#}}}
}
#}}}