diff --git a/src/freedombone b/src/freedombone index 384810bf..6efbc14d 100755 --- a/src/freedombone +++ b/src/freedombone @@ -281,10 +281,8 @@ if [ ! "$?" = "0" ]; then fi setup_utils -setup_mesh setup_email setup_web -script_for_attaching_usb_drive setup_apps setup_final diff --git a/src/freedombone-app-batman b/src/freedombone-app-batman index 1fad96fd..af5ef436 100755 --- a/src/freedombone-app-batman +++ b/src/freedombone-app-batman @@ -32,7 +32,7 @@ ENABLE_BATMAN="no" BATMAN_CELLID='any' -function configure_firewall_for_batman { +function configure_firewall_for_batma { if grep -Fxq "configure_firewall_for_batman" $COMPLETION_FILE; then return fi diff --git a/src/freedombone-app-cjdns b/src/freedombone-app-cjdns index 663e15e7..ecef185e 100755 --- a/src/freedombone-app-cjdns +++ b/src/freedombone-app-cjdns @@ -129,7 +129,7 @@ function remove_cjdns { sed -i '/configure_firewall_for_cjdns/d' $COMPLETION_FILE } -function install_cjdns { +function install_cjdns_main { if [[ $ENABLE_CJDNS != "yes" ]]; then return fi @@ -138,7 +138,7 @@ function install_cjdns { function_check set_repo_commit set_repo_commit /etc/cjdns "cjdns commit" "$CJDNS_COMMIT" $CJDNS_REPO - if grep -Fxq "install_cjdns" $COMPLETION_FILE; then + if grep -Fxq "install_cjdns_main" $COMPLETION_FILE; then return fi @@ -418,7 +418,7 @@ function install_cjdns { function_check configure_firewall_for_cjdns configure_firewall_for_cjdns - echo 'install_cjdns' >> $COMPLETION_FILE + echo 'install_cjdns_main' >> $COMPLETION_FILE } function install_cjdns_tools { @@ -480,4 +480,13 @@ function install_cjdns_tools { echo 'install_cjdns_tools' >> $COMPLETION_FILE } +function install_cjdns { + if grep -Fxq "install_cjdns" $COMPLETION_FILE; then + return + fi + install_cjdns_main + install_cjdns_tools + echo 'install_cjdns' >> $COMPLETION_FILE +} + # NOTE: deliberately no exit 0 diff --git a/src/freedombone-app-dlna b/src/freedombone-app-dlna index 4f2e3e76..56f1f990 100755 --- a/src/freedombone-app-dlna +++ b/src/freedombone-app-dlna @@ -50,7 +50,7 @@ function configure_firewall_for_dlna { } function backup_dlna { - echo '' + echo '' } function remove_dlna { @@ -69,8 +69,8 @@ function remove_dlna { sed -i '/install_dlna/d' $COMPLETION_FILE } -function install_dlna { - if grep -Fxq "install_dlna" $COMPLETION_FILE; then +function install_dlna_main { + if grep -Fxq "install_dlna_main" $COMPLETION_FILE; then return fi if [[ $SYSTEM_TYPE == "$VARIANT_CLOUD" || $SYSTEM_TYPE == "$VARIANT_MAILBOX" || $SYSTEM_TYPE == "$VARIANT_CHAT" || $SYSTEM_TYPE == "$VARIANT_WRITER" || $SYSTEM_TYPE == "$VARIANT_SOCIAL" || $SYSTEM_TYPE == "$VARIANT_DEVELOPER" || $SYSTEM_TYPE == "$VARIANT_MESH" ]]; then @@ -121,7 +121,7 @@ function install_dlna { function_check configure_firewall_for_dlna configure_firewall_for_dlna - echo 'install_dlna' >> $COMPLETION_FILE + echo 'install_dlna_main' >> $COMPLETION_FILE } function script_for_attaching_usb_drive { @@ -163,4 +163,13 @@ function script_for_attaching_usb_drive { echo 'script_for_attaching_usb_drive' >> $COMPLETION_FILE } +function install_dlna { + if grep -Fxq "install_dlna" $COMPLETION_FILE; then + return + fi + install_dlna_main + script_for_attaching_usb_drive + echo 'install_dlna' >> $COMPLETION_FILE +} + # NOTE: deliberately no exit 0 diff --git a/src/freedombone-app-rss b/src/freedombone-app-rss index 60742549..fe827e44 100755 --- a/src/freedombone-app-rss +++ b/src/freedombone-app-rss @@ -443,9 +443,13 @@ function install_rss_mobile_reader { } function install_rss { + if grep -Fxq "install_rss" $COMPLETION_FILE; then + return + fi install_rss_main install_rss_gnusocial install_rss_mobile_reader + echo 'install_rss' >> $COMPLETION_FILE } # NOTE: deliberately no exit 0 diff --git a/src/freedombone-app-vpn b/src/freedombone-app-vpn index f8ac4fb8..6291fedc 100755 --- a/src/freedombone-app-vpn +++ b/src/freedombone-app-vpn @@ -29,14 +29,18 @@ # along with this program. If not, see . function backup_vpn { - echo '' + echo '' } function remove_vpn { apt-get -y remove --purge fastd + sed -i '/install_vpn/d' $COMPLETION_FILE } function install_vpn { + if grep -Fxq "install_vpn" $COMPLETION_FILE; then + return + fi if ! grep -q "repo.universe-factory.net" /etc/apt/sources.list; then echo 'deb http://repo.universe-factory.net/debian/ sid main' >> /etc/apt/sources.list gpg --keyserver pgpkeys.mit.edu --recv-key 16EF3F64CB201D9C @@ -50,6 +54,7 @@ function install_vpn { exit 52026 fi fi + echo 'install_vpn' >> $COMPLETION_FILE } # NOTE: deliberately there is no "exit 0" diff --git a/src/freedombone-app-xmpp b/src/freedombone-app-xmpp index 0c649777..7cecb185 100755 --- a/src/freedombone-app-xmpp +++ b/src/freedombone-app-xmpp @@ -408,8 +408,12 @@ function install_xmpp_client { } function install_xmpp { + if grep -Fxq "install_xmpp" $COMPLETION_FILE; then + return + fi install_xmpp_main install_xmpp_client + echo 'install_xmpp' >> $COMPLETION_FILE } # NOTE: deliberately no exit 0 diff --git a/src/freedombone-app-zeronet b/src/freedombone-app-zeronet index e9ab5ad0..4954aea4 100755 --- a/src/freedombone-app-zeronet +++ b/src/freedombone-app-zeronet @@ -459,10 +459,14 @@ function install_zeronet_main { } function install_zeronet { + if grep -Fxq "install_zeronet" $COMPLETION_FILE; then + return + fi install_zeronet_main install_zeronet_blog install_zeronet_mail install_zeronet_forum + echo 'install_zeronet' >> $COMPLETION_FILE } # NOTE: deliberately no exit 0 diff --git a/src/freedombone-utils-selector b/src/freedombone-utils-selector index daaec9aa..53b57426 100755 --- a/src/freedombone-utils-selector +++ b/src/freedombone-utils-selector @@ -111,3 +111,5 @@ function install_apps { app_index=$[app_index+1] done } + +# NOTE: deliberately no exit 0 diff --git a/src/freedombone-utils-setup b/src/freedombone-utils-setup index 651aca02..0ca30761 100755 --- a/src/freedombone-utils-setup +++ b/src/freedombone-utils-setup @@ -291,13 +291,6 @@ function setup_utils { upgrade_golang } -function setup_mesh { - install_cjdns - install_cjdns_tools - install_batman - install_babel -} - function setup_email { install_email create_procmail