MCPcopy Create free account
hub / github.com/Gin-Quin/gravity / updateWorkspacesVersion

Function updateWorkspacesVersion

scripts/utilities/updateWorkspacesVersion.ts:4–14  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2import { packages } from "./workspace";
3
4export function updateWorkspacesVersion() {
5 const file = "package.json";
6 const version = JSON.parse(fs.readFileSync(file, "utf8")).version;
7
8 for (const packageName of packages) {
9 const workspaceFile = `${packageName}/package.json`;
10 const packageInfos = JSON.parse(fs.readFileSync(workspaceFile, "utf8"));
11 packageInfos.version = version;
12 fs.writeFileSync(workspaceFile, JSON.stringify(packageInfos, null, "\t"));
13 }
14}

Callers 1

deployFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected