Skip to content

Commit

Permalink
chore: updated diff task to accept tag parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
GarthDB committed Sep 25, 2023
1 parent 0461bf3 commit d332fe6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/tokens/tasks/diff.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import tmp from "tmp-promise";

const execP = promisify(exec);

const tag = "latest";
const tag = process.argv[2] || "latest";
const tokenPath = "dist/json/variables.json";
const localRootDir = join(dirname(fileURLToPath(import.meta.url)), "..");
const localTokenPath = join(localRootDir, tokenPath);
Expand Down Expand Up @@ -71,6 +71,7 @@ async function getOldTokens() {
});
const oldTokenPath = join(tmpDir.path, "package", tokenPath);
await access(oldTokenPath);
console.log(`Comparing against ${stdout.trim()}`);
return JSON.parse(await readFile(oldTokenPath, { encoding: "utf8" }));
}

Expand Down

0 comments on commit d332fe6

Please sign in to comment.