Skip to content
Snippets Groups Projects
Commit a1a7e92d authored by Bob Mottram's avatar Bob Mottram
Browse files

Avoid bad app sequence

parent c98b2f2e
No related branches found
No related tags found
No related merge requests found
......@@ -163,14 +163,16 @@ function remove_apps_selected {
# shellcheck disable=SC2068
for a in ${APPS_INSTALLED[@]}
do
if [[ ${APPS_INSTALLED[$app_index]} == "1" ]]; then
if [[ ${APPS_CHOSEN[$app_index]} == "0" ]]; then
if [ ${n} -gt 0 ]; then
removals="$removals ${APPS_AVAILABLE[$app_index]}"
else
removals="${APPS_AVAILABLE[$app_index]}"
if [[ $(app_not_on_onion_only "$a") != "0" ]]; then
if [[ ${APPS_INSTALLED[$app_index]} == "1" ]]; then
if [[ ${APPS_CHOSEN[$app_index]} == "0" ]]; then
if [ ${n} -gt 0 ]; then
removals="$removals ${APPS_AVAILABLE[$app_index]}"
else
removals="${APPS_AVAILABLE[$app_index]}"
fi
n=$((n+1))
fi
n=$((n+1))
fi
fi
app_index=$((app_index+1))
......@@ -208,14 +210,16 @@ function install_apps_selected {
# shellcheck disable=SC2068
for a in ${APPS_INSTALLED[@]}
do
if [[ ${APPS_INSTALLED[$app_index]} == "0" ]]; then
if [[ ${APPS_CHOSEN[$app_index]} == "1" ]]; then
if [ ${n} -gt 0 ]; then
installs="$installs ${APPS_AVAILABLE[$app_index]}"
else
installs="${APPS_AVAILABLE[$app_index]}"
if [[ $(app_not_on_onion_only "$a") != "0" ]]; then
if [[ ${APPS_INSTALLED[$app_index]} == "0" ]]; then
if [[ ${APPS_CHOSEN[$app_index]} == "1" ]]; then
if [ ${n} -gt 0 ]; then
installs="$installs ${APPS_AVAILABLE[$app_index]}"
else
installs="${APPS_AVAILABLE[$app_index]}"
fi
n=$((n+1))
fi
n=$((n+1))
fi
fi
app_index=$((app_index+1))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment