Bob Mottram 8 years ago
parent
commit
b0fd5f1cee
1 changed files with 11 additions and 11 deletions
  1. 11
    11
      src/freedombone-app-gnusocial

+ 11
- 11
src/freedombone-app-gnusocial View File

@@ -368,7 +368,7 @@ function install_gnusocial_main {
368 368
         exit 7359
369 369
     fi
370 370
 
371
-    if grep -Fxq "install_gnusocial_main" $COMPLETION_FILE; then
371
+    if [[ $(app_is_installed gnusocial_main) == "1" ]]; then
372 372
         return
373 373
     fi
374 374
 
@@ -625,7 +625,7 @@ function install_gnusocial_main {
625 625
     echo "GNU Social onion domain:${MICROBLOG_ONION_HOSTNAME}" >> $COMPLETION_FILE
626 626
 
627 627
     echo "GNU Social domain:$MICROBLOG_DOMAIN_NAME" >> $COMPLETION_FILE
628
-    echo 'install_gnusocial_main' >> $COMPLETION_FILE
628
+    install_completed gnusocial_main
629 629
 }
630 630
 
631 631
 function install_gnusocial_plugin_sharings {
@@ -640,7 +640,7 @@ function install_gnusocial_plugin_sharings {
640 640
     function_check set_repo_commit
641 641
     set_repo_commit /var/www/$MICROBLOG_DOMAIN_NAME/htdocs/local/plugins "GNU Social sharings plugin commit" "$SHARINGS_COMMIT" $SHARINGS_REPO
642 642
 
643
-    if grep -Fxq "install_gnusocial_plugin_sharings" $COMPLETION_FILE; then
643
+    if [[ $(app_is_installed gnusocial_plugin_sharings) == "1" ]]; then
644 644
         return
645 645
     fi
646 646
 
@@ -697,7 +697,7 @@ function install_gnusocial_plugin_sharings {
697 697
     else
698 698
         sed -i "s|GNU Social sharings plugin commit.*|GNU Social sharings plugin commit:$SHARINGS_COMMIT|g" $COMPLETION_FILE
699 699
     fi
700
-    echo 'install_gnusocial_plugin_sharings' >> $COMPLETION_FILE
700
+    install_completed gnusocial_plugin_sharings
701 701
 }
702 702
 
703 703
 function install_gnusocial_plugin_sharings_theme {
@@ -710,7 +710,7 @@ function install_gnusocial_plugin_sharings_theme {
710 710
     function_check set_repo_commit
711 711
     set_repo_commit /var/www/$MICROBLOG_DOMAIN_NAME/htdocs/local/plugins "GNU Social sharings theme plugin commit" "$SHARINGS_THEME_COMMIT" $SHARINGS_THEME_REPO
712 712
 
713
-    if grep -Fxq "install_gnusocial_plugin_sharings_theme" $COMPLETION_FILE; then
713
+    if [[ $(app_is_installed gnusocial_plugin_sharings_theme) == "1" ]]; then
714 714
         return
715 715
     fi
716 716
 
@@ -743,7 +743,7 @@ function install_gnusocial_plugin_sharings_theme {
743 743
     else
744 744
         sed -i "s|GNU Social sharings plugin theme commit.*|GNU Social sharings plugin theme commit:$SHARINGS_THEME_COMMIT|g" $COMPLETION_FILE
745 745
     fi
746
-    echo 'install_gnusocial_plugin_sharings_theme' >> $COMPLETION_FILE
746
+    install_completed gnusocial_plugin_sharings_theme
747 747
 }
748 748
 
749 749
 function expire_gnusocial_posts {
@@ -813,7 +813,7 @@ function install_gnusocial_theme {
813 813
         fi
814 814
     fi
815 815
 
816
-    if grep -Fxq "install_gnusocial_theme" $COMPLETION_FILE; then
816
+    if [[ $(app_is_installed gnusocial_theme) == "1" ]]; then
817 817
         return
818 818
     fi
819 819
 
@@ -897,7 +897,7 @@ function install_gnusocial_theme {
897 897
 
898 898
     chown -R www-data:www-data /var/www/$MICROBLOG_DOMAIN_NAME/htdocs
899 899
 
900
-    echo 'install_gnusocial_theme' >> $COMPLETION_FILE
900
+    install_completed gnusocial_theme
901 901
 }
902 902
 
903 903
 function install_gnusocial_markdown {
@@ -907,7 +907,7 @@ function install_gnusocial_markdown {
907 907
     function_check set_repo_commit
908 908
     set_repo_commit $MICROBLOG_PATH/local/plugins/Markdown "GNU Social Markdown commit" "$MICROBLOG_MARKDOWN_COMMIT" $MICROBLOG_MARKDOWN_REPO
909 909
 
910
-    if grep -Fxq "install_gnusocial_markdown" $COMPLETION_FILE; then
910
+    if [[ $(app_is_installed gnusocial_markdown) == "1" ]]; then
911 911
         return
912 912
     fi
913 913
 
@@ -938,7 +938,7 @@ function install_gnusocial_markdown {
938 938
 
939 939
     chown -R www-data:www-data $MICROBLOG_PATH
940 940
 
941
-    echo 'install_gnusocial_markdown' >> $COMPLETION_FILE
941
+    install_completed gnusocial_markdown
942 942
 }
943 943
 
944 944
 function install_gnusocial_plugin_nsfw {
@@ -984,7 +984,7 @@ function install_gnusocial_plugin_nsfw {
984 984
     else
985 985
         sed -i "s|GNU Social NSFW plugin commit.*|GNU Social NSFW plugin commit:$GNUSOCIAL_NSFW_COMMIT|g" $COMPLETION_FILE
986 986
     fi
987
-    echo 'install_gnusocial_plugin_nsfw' >> $COMPLETION_FILE
987
+    install_completed gnusocial_plugin_nsfw
988 988
 }
989 989
 
990 990
 function install_gnusocial {