public commit

This commit is contained in:
dswbx
2024-11-16 12:01:47 +01:00
commit 90f80c4280
582 changed files with 49291 additions and 0 deletions

View File

@@ -0,0 +1,20 @@
import path from "node:path";
import url from "node:url";
import { getDistPath, getRelativeDistPath, getRootPath } from "cli/utils/sys";
import type { CliCommand } from "../types";
export const debug: CliCommand = (program) => {
program
.command("debug")
.description("debug path resolution")
.action(() => {
console.log("paths", {
rootpath: getRootPath(),
distPath: getDistPath(),
relativeDistPath: getRelativeDistPath(),
cwd: process.cwd(),
dir: path.dirname(url.fileURLToPath(import.meta.url)),
resolvedPkg: path.resolve(getRootPath(), "package.json")
});
});
};