shellcheck
This commit is contained in:
parent
9d8a0dae66
commit
50156bd7cd
1 changed files with 3 additions and 1 deletions
|
@ -35,6 +35,8 @@ owner=$(cat "$__object/parameter/owner")
|
||||||
group=$(cat "$__object/parameter/group")
|
group=$(cat "$__object/parameter/group")
|
||||||
mode=$(cat "$__object/parameter/mode")
|
mode=$(cat "$__object/parameter/mode")
|
||||||
|
|
||||||
|
[ -f "$__object/parameter/recursive" ] && recursive='--recursive' || recursive=''
|
||||||
|
|
||||||
[ "$state_should" = "$state_is" ] \
|
[ "$state_should" = "$state_is" ] \
|
||||||
&& [ "$owner" = "$owner_is" ] \
|
&& [ "$owner" = "$owner_is" ] \
|
||||||
&& [ "$group" = "$group_is" ] \
|
&& [ "$group" = "$group_is" ] \
|
||||||
|
@ -43,7 +45,7 @@ mode=$(cat "$__object/parameter/mode")
|
||||||
case $state_should in
|
case $state_should in
|
||||||
present)
|
present)
|
||||||
if [ "$state_should" != "$state_is" ]; then
|
if [ "$state_should" != "$state_is" ]; then
|
||||||
echo git clone --quiet $([ -f "$__object/parameter/recursive" ] && echo '--recursive') --branch "$branch" "$source" "$destination"
|
echo git clone --quiet "$recursive" --branch "$branch" "$source" "$destination"
|
||||||
fi
|
fi
|
||||||
if { [ -n "$owner" ] && [ "$owner_is" != "$owner" ]; } || \
|
if { [ -n "$owner" ] && [ "$owner_is" != "$owner" ]; } || \
|
||||||
{ [ -n "$group" ] && [ "$group_is" != "$group" ]; }; then
|
{ [ -n "$group" ] && [ "$group_is" != "$group" ]; }; then
|
||||||
|
|
Loading…
Reference in a new issue