Skip to content

Commit

Permalink
fix(cli): import.meta.url
Browse files Browse the repository at this point in the history
  • Loading branch information
vicary committed Mar 13, 2024
1 parent 640ccc3 commit c0b183b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 13 deletions.
18 changes: 6 additions & 12 deletions cli.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,4 @@
import {
assert,
colors,
dirname,
fromFileUrl,
log,
resolvePath,
} from "./deps.ts";
import { assert, colors, log } from "./deps.ts";

log.setup({
handlers: {
Expand Down Expand Up @@ -112,10 +105,11 @@ async function patchDev() {
// Ensure file exists
await Deno.stat("dev.ts");

const diffFile = resolvePath(
dirname(fromFileUrl(import.meta.url)),
"dev.patch",
);
const diffFile = import.meta.resolve("./dev.patch");

if (Deno.env.has("FRSH_GQL_DEBUG")) {
console.debug(import.meta, { diffFile });
}

try {
await Deno.stat(diffFile);
Expand Down
2 changes: 1 addition & 1 deletion deno.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vicary/fresh-graphql",
"version": "0.2.1",
"version": "0.2.5",
"exports": "./mod.ts",
"lock": false,
"nodeModulesDir": false
Expand Down

0 comments on commit c0b183b

Please sign in to comment.