MCPcopy Create free account
hub / github.com/ProNextJS/declarative-routing / getPackageInfo

Function getPackageInfo

src/shared/utils.ts:11–17  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

9import boxen from "boxen";
10
11export function getPackageInfo() {
12 const __filename = fileURLToPath(import.meta.url);
13 const __dirname = path.dirname(__filename);
14
15 const packageJsonPath = path.resolve(__dirname, "../package.json");
16 return fs.readJSONSync(packageJsonPath) as PackageJson;
17}
18
19export function addPackageJSONScripts(scripts: Record<string, string>) {
20 const packageJsonPath = path.resolve("./package.json");

Callers 1

mainFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected