diff --git a/test/ecmascript/update-all-data.mjs b/test/ecmascript/update-all-data.mjs index 4c0375df..77dcc643 100644 --- a/test/ecmascript/update-all-data.mjs +++ b/test/ecmascript/update-all-data.mjs @@ -1,11 +1,13 @@ import { readdir, writeFile } from 'fs/promises'; -const dir = new URL('./', import.meta.url); +const dir = new URL('./', import.meta.url); const files = await readdir(dir); + for (const file of files.filter(f => f.startsWith('data-'))) { const url = `https://raw.githubusercontent.com/kangax/compat-table/gh-pages/${file}`; const res = await fetch(url); const text = await res.text(); await writeFile(new URL(file, dir), text); } + console.log('Update complete!')