generated from me/template-mit
Double wrap the updater commands so that the DONE code does not appear in the terminl.
This commit is contained in:
54
rc_shared.sh
54
rc_shared.sh
@@ -590,32 +590,34 @@ eval "$(declare -F | grep -v _ | sed 's/-f /-fx /')"
|
|||||||
|
|
||||||
# Run update checker in background.
|
# Run update checker in background.
|
||||||
(
|
(
|
||||||
if [[ -d "$PROJECT_SHARED" ]]; then
|
(
|
||||||
git -C "$PROJECT_SHARED" fetch >/dev/null 2>&1 \
|
if [[ -d "$PROJECT_SHARED" ]]; then
|
||||||
&& git -C "$PROJECT_SHARED" status \
|
git -C "$PROJECT_SHARED" fetch >/dev/null 2>&1 \
|
||||||
| grep "is behind" \
|
&& git -C "$PROJECT_SHARED" status \
|
||||||
| while read status; do
|
| grep "is behind" \
|
||||||
title=TBD
|
| while read status; do
|
||||||
message=TBD
|
title=TBD
|
||||||
success=0
|
message=TBD
|
||||||
reload-shared || success=1
|
success=0
|
||||||
if [[ $success == 0 ]]; then
|
reload-shared || success=1
|
||||||
title="env-shared Updated"
|
if [[ $success == 0 ]]; then
|
||||||
message="Updated with 'reload-shared'."
|
title="env-shared Updated"
|
||||||
else
|
message="Updated with 'reload-shared'."
|
||||||
title="env-shared Updates Available"
|
else
|
||||||
message="Update with 'reload-shared'."
|
title="env-shared Updates Available"
|
||||||
fi
|
message="Update with 'reload-shared'."
|
||||||
if [[ -d /sdcard ]]; then
|
fi
|
||||||
termux-notification \
|
if [[ -d /sdcard ]]; then
|
||||||
-t "$title" \
|
termux-notification \
|
||||||
-c "$message"
|
-t "$title" \
|
||||||
else
|
-c "$message"
|
||||||
notify-send "$title" "$message"
|
else
|
||||||
fi
|
notify-send "$title" "$message"
|
||||||
done
|
fi
|
||||||
fi
|
done
|
||||||
) >> "$HOME"/Reports/env-shared.log 2>&1 &
|
fi
|
||||||
|
) >> "$HOME"/Reports/env-shared.log 2>&1 &
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
## Complete! ##
|
## Complete! ##
|
||||||
|
|||||||
Reference in New Issue
Block a user