Attempt to get script working

This commit is contained in:
Pieter Vander Vennet 2025-06-19 18:51:46 +02:00
parent 1fadc5d7fe
commit aad1a461d3
3 changed files with 11 additions and 3 deletions

View file

@ -35,6 +35,9 @@ jobs:
- name: install deps - name: install deps
run: npm ci run: npm ci
- run: npm run init
- name: Move dependency (@capacitor) into android repo - name: Move dependency (@capacitor) into android repo
run: | run: |
cd android cd android
@ -54,8 +57,6 @@ jobs:
sed -i "s/versionName \".*\"/versionName \"$new_versionname\"/" "build.gradle" sed -i "s/versionName \".*\"/versionName \"$new_versionname\"/" "build.gradle"
git add build.gradle git add build.gradle
- run: npm run init
- name: Run tests - name: Run tests
run: npm run test run: npm run test

@ -1 +1 @@
Subproject commit e3e82a546e1f25901f09bee4a05c9dc29602af14 Subproject commit f62d2704a0632a47c70055b145dcff95107ba547

View file

@ -300,6 +300,9 @@ class GenerateLayouts extends Script {
if (url.endsWith(".pmtiles")) { if (url.endsWith(".pmtiles")) {
continue continue
} }
try{
console.log("Downloading ", url)
const styleSpec = await Utils.downloadJsonCached(url, 1000 * 120, { const styleSpec = await Utils.downloadJsonCached(url, 1000 * 120, {
Origin: "https://mapcomplete.org", Origin: "https://mapcomplete.org",
}) })
@ -324,6 +327,10 @@ class GenerateLayouts extends Script {
urls.push(...(styleSpec["tiles"] ?? [])) urls.push(...(styleSpec["tiles"] ?? []))
urls.push(styleSpec["sprite"]) urls.push(styleSpec["sprite"])
urls.push(styleSpec["glyphs"]) urls.push(styleSpec["glyphs"])
}catch (e) {
console.error("ERROR: could not download a resource, some sprites might not be whitelisted and thus not load")
}
} }
} }
this.eliUrlsCached = urls this.eliUrlsCached = urls