diff --git a/.github/tools/github_actions_deno_deploy.ts b/.github/tools/github_actions_deno_deploy.ts index 04d6670..774a2c7 100644 --- a/.github/tools/github_actions_deno_deploy.ts +++ b/.github/tools/github_actions_deno_deploy.ts @@ -1,7 +1,6 @@ // Imports import * as JSONC from "@std/jsonc" import * as core from "@actions/core" -import { encodeBase64 } from "@std/encoding" // Parse deno.jsonc and print deno deploy flags // deno-lint-ignore no-explicit-any @@ -10,4 +9,6 @@ core.setOutput("project", config.deploy.project) core.setOutput("entrypoint", config.deploy.entrypoint) core.setOutput("include", config.deploy.include.join(",")) core.setOutput("exclude", config.deploy.exclude.join(",")) -core.setOutput("import_map", new URL(`data:application/json;base64,${encodeBase64(JSON.stringify(config.imports))}`).href) +core.setOutput("import_map", ".imports_map.json") + +await Deno.writeTextFile(".imports_map.json", JSON.stringify({ imports: config.imports })) diff --git a/.gitignore b/.gitignore index 1658fb3..f72cf30 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,6 @@ .cache .vercel +.imports_map.json coverage node_modules www/.pages \ No newline at end of file diff --git a/deno.jsonc b/deno.jsonc index d0ea787..e2083b0 100644 --- a/deno.jsonc +++ b/deno.jsonc @@ -77,7 +77,7 @@ // Deployment tasks "deploy:setup-github-actions": { "description": "", - "command": "deno run --allow-env --allow-read --allow-write=/home/runner/work/_temp .github/tools/github_actions_deno_deploy.ts" + "command": "deno run --allow-env --allow-read --allow-write=.imports_map.json,/home/runner/work/_temp .github/tools/github_actions_deno_deploy.ts" }, "deploy:preview": { "description": "Deploy website (preview)", @@ -145,7 +145,6 @@ "@actions/core": "npm:@actions/core@^1.11.1", "@astral/astral": "jsr:@astral/astral@~0.5", "@libs/run": "jsr:@libs/run@^3.0.2", - "@std/encoding": "jsr:@std/encoding@^1.0.5", "@std/fs": "jsr:@std/fs@^1.0.6", "@std/yaml": "jsr:@std/yaml@^1.0.5" }, diff --git a/deno.lock b/deno.lock index 93c8aec..28c06b7 100644 --- a/deno.lock +++ b/deno.lock @@ -4479,7 +4479,6 @@ "jsr:@std/assert@^1.0.9", "jsr:@std/async@^1.0.9", "jsr:@std/collections@^1.0.9", - "jsr:@std/encoding@^1.0.5", "jsr:@std/fmt@^1.0.3", "jsr:@std/fs@^1.0.6", "jsr:@std/html@^1.0.3",