|
@@ -44,8 +44,6 @@ function android_update_apps {
|
44
|
44
|
echo '{' > "$plinth_api"
|
45
|
45
|
echo ' "shortcuts": [' >> "$plinth_api"
|
46
|
46
|
|
47
|
|
- echo 'android app' > /var/log/androidapp.log
|
48
|
|
-
|
49
|
47
|
android_ctr=0
|
50
|
48
|
app_index=0
|
51
|
49
|
# shellcheck disable=SC2068,SC2034
|
|
@@ -53,19 +51,14 @@ function android_update_apps {
|
53
|
51
|
do
|
54
|
52
|
app_name=${APPS_INSTALLED_NAMES[$app_index]}
|
55
|
53
|
if [ "$app_name" ]; then
|
56
|
|
- echo "Starting app ${APPS_INSTALLED_NAMES[$app_index]}" >> /var/log/androidapp.log
|
57
|
|
- echo "App installed $app_name" >> /var/log/androidapp.log
|
58
|
54
|
app_filename="/usr/share/${PROJECT_NAME}/apps/${PROJECT_NAME}-app-${app_name}"
|
59
|
55
|
if [ -f "$app_filename" ]; then
|
60
|
|
- echo "File exists $app_filename" >> /var/log/androidapp.log
|
61
|
56
|
# get the icon for the app
|
62
|
57
|
icon_filename="/usr/share/${PROJECT_NAME}/android-app/${app_name}.png"
|
63
|
58
|
if [ -f "$icon_filename" ]; then
|
64
|
59
|
cp "$icon_filename" "/var/www/${local_hostname}/htdocs/icons/${app_name}.png"
|
65
|
|
- echo "icon copied" >> /var/log/androidapp.log
|
66
|
60
|
else
|
67
|
61
|
icon_filename=
|
68
|
|
- echo "icon not copied" >> /var/log/androidapp.log
|
69
|
62
|
fi
|
70
|
63
|
|
71
|
64
|
app_name_upper=$(echo "$app_name" | awk '{print toupper($0)}')
|