diff --git a/apps.json b/apps.json index 1455a2b13..4efd5318a 100644 --- a/apps.json +++ b/apps.json @@ -1,4 +1,8 @@ --- +# uncomment the following line if you only want explicitly listed +# apps to be available on your site + +# restricted: ["boot", "launch", "antonclk", "health", "setting", "about", "widbat", "widbt", "widlock", "widid"] --- {% comment %} ================================================================= @@ -12,14 +16,21 @@ ================================================================= {% endcomment %} -{%- assign apps = site.static_files | where: "name", "metadata.json" -%} +{%- if page.restricted == nil -%} + {%- assign apps = site.static_files | where: "name", "metadata.json" | map: "path" -%} +{%- else -%} + {%- capture temp -%} + {%- for app in page.restricted %} /apps/{{app}}/metadata.json {%- endfor -%} + {%- endcapture -%} + {%- assign apps = temp | strip | split: " " -%} +{%- endif -%} [ -{%- include_relative {{ apps.first.path }} -%} +{%- include_relative {{ apps.first }} -%} {%- for app in apps offset:1 -%} -,{%- include_relative {{ app.path }} -%} +,{%- include_relative {{ app }} -%} {%- endfor -%} ]