Files
penpot/mcp/bin/mcp-local.js
Dominik Jain c9d9e493e7 🎉 Prepare npm package for MCP server (#8473)
* 🎉 Prepare npm package for MCP server

* 🐛 Re-establish Windows compatibility of MCP server build script

Use node instead of cp to copy files

*  Set version for MCP npm tarball based on git tag

* Add scripts/set-version to set the version in package.json
  based on git describe information
* Add scripts/pack to perform the packaging
2026-03-04 08:41:28 +01:00

23 lines
485 B
JavaScript

#!/usr/bin/env node
const { execSync } = require("child_process");
const path = require("path");
const root = path.resolve(__dirname, "..");
function run(command) {
execSync(command, { cwd: root, stdio: "inherit" });
}
try {
run("corepack pnpm run bootstrap");
} catch (error) {
if (error.code === "ENOENT") {
console.error(
"corepack is required but was not found. It ships with Node.js >= 16."
);
process.exit(1);
}
process.exit(error.status ?? 1);
}