浏览代码

Read domain variables from configuration file

Bob Mottram 6 年前
父节点
当前提交
b96ab2849d
共有 1 个文件被更改,包括 4 次插入3 次删除
  1. 4
    3
      src/freedombone-utils-android

+ 4
- 3
src/freedombone-utils-android 查看文件

81
                 { echo '    {';
81
                 { echo '    {';
82
                   echo "      \"name\": \"${app_name}\",";
82
                   echo "      \"name\": \"${app_name}\",";
83
                   echo "      \"short_description\": \"$SHORT_DESCRIPTION\",";
83
                   echo "      \"short_description\": \"$SHORT_DESCRIPTION\",";
84
-                  echo "      \"description\": \"$DESCRIPTION))\",";
84
+                  echo "      \"description\": \"$DESCRIPTION\",";
85
                   echo "      \"icon_url\": \"$ICON_URL\",";
85
                   echo "      \"icon_url\": \"$ICON_URL\",";
86
                   echo "      \"clients\": ["; } >> "$plinth_api"
86
                   echo "      \"clients\": ["; } >> "$plinth_api"
87
 
87
 
88
+                read_config_param "${app_name_upper}_DOMAIN_NAME"
88
                 domain_name=$(("${app_name_upper}_DOMAIN_NAME"))
89
                 domain_name=$(("${app_name_upper}_DOMAIN_NAME"))
89
-                if [[ "$domain_name" && "$app_name" != 'matrix' ]]; then
90
+                if [[ "$domain_name" != "0" && "$app_name" != 'matrix' ]]; then
90
                     { echo '        {';
91
                     { echo '        {';
91
                       echo "          \"name\": \"${app_name}\",";
92
                       echo "          \"name\": \"${app_name}\",";
92
                       echo "          \"platforms\": [";
93
                       echo "          \"platforms\": [";
99
                 fi
100
                 fi
100
 
101
 
101
                 if [ "$MOBILE_APP_URL" ]; then
102
                 if [ "$MOBILE_APP_URL" ]; then
102
-                    if [[ "$domain_name" && "$app_name" != 'matrix' ]]; then
103
+                    if [[ "$domain_name" != "0" && "$app_name" != 'matrix' ]]; then
103
                         echo ',' >> "$plinth_api"
104
                         echo ',' >> "$plinth_api"
104
                     fi
105
                     fi
105
                     { echo '        {';
106
                     { echo '        {';