UNPKG

lerna

Version:

Lerna is a fast, modern build system for managing and publishing multiple JavaScript/TypeScript packages from the same repository

102 lines (100 loc) • 3.36 kB
import { command_default as command_default15 } from "./chunk-4BEUOGCT.js"; import { command_default as command_default12 } from "./chunk-LD6CAXOM.js"; import "./chunk-CZ4AGWZJ.js"; import { command_default as command_default14 } from "./chunk-JEYOSJT4.js"; import { command_default as command_default11 } from "./chunk-4SYO2AQM.js"; import { command_default as command_default10 } from "./chunk-YZ2UJEYO.js"; import { command_default as command_default6 } from "./chunk-AF2HFCX3.js"; import { command_default as command_default7 } from "./chunk-TFEFGHTG.js"; import { command_default as command_default8 } from "./chunk-N2L4MMPS.js"; import { command_default as command_default9 } from "./chunk-FQ55JMPV.js"; import { command_default as command_default3 } from "./chunk-AETHTADV.js"; import { command_default as command_default4 } from "./chunk-HGVLYZUU.js"; import { command_default as command_default5 } from "./chunk-CK22IVVT.js"; import "./chunk-BG6OARM2.js"; import { command_default as command_default13 } from "./chunk-WNNF5J4F.js"; import { command_default } from "./chunk-DHWWY6YE.js"; import { command_default as command_default2 } from "./chunk-6Z5HPKNS.js"; import { lernaCLI, npmlog_default } from "./chunk-UFWJYOZK.js"; import "./chunk-MLKGABMK.js"; // packages/lerna/src/index.ts import pkg from "../package.json" with { type: "json" }; import yargsFactory from "yargs/yargs"; process.env["NX_ISOLATE_PLUGINS"] = "false"; process.env["NX_TUI"] = "false"; function main(argv) { const context = { lernaVersion: pkg.version }; const cli = lernaCLI().version(pkg.version).command(command_default13).command(command_default).command(command_default2).command(command_default3).command(command_default4).command(command_default5).command(command_default6).command(command_default7).command(command_default8).command(command_default9).command(command_default11).command(command_default14).command(command_default12).command(command_default15).command(command_default10); explicitlyHandleLegacyPackageManagementCommands(cli); return cli.parse(argv, context); } function explicitlyHandleLegacyPackageManagementCommands(yargsInstance) { ["add", "bootstrap", "link"].forEach((commandName) => { yargsInstance.command({ command: commandName === "add" ? "add <pkg> [globs..]" : commandName, describe: `The "${commandName}" command was removed by default in v7, and is no longer maintained.`, builder: (yargs) => { const parsed = yargsFactory(process.argv.slice(2)).argv; for (const x of Object.keys(parsed)) { if (x !== "_" && x !== "$0") { yargs.option(x, {}); } } return yargs; }, handler() { npmlog_default.error( commandName, `The "${commandName}" command was removed by default in v7 with a notice that it was no longer maintained. In v9, over 2 years later, it was finally removed.` ); npmlog_default.error( commandName, // TODO: Update the docs to be explicit about the removal in v9 `Learn more about this change at https://lerna.js.org/docs/legacy-package-management` ); process.exit(1); } }); }); } var index_default = main; export { index_default as default, main, main as "module.exports" };