UNPKG

@onboardbase/cli

Version:

[![Version](https://img.shields.io/npm/v/@onboardbase/cli.svg)](https://www.npmjs.com/package/@onboardbase/cli) [![Downloads/week](https://img.shields.io/npm/dw/@onboardbase/cli.svg)](https://www.npmjs.com/package/@onboardbase/cli) [![License](https://img

61 lines (60 loc) 2.01 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const command_1 = require("@oclif/command"); const run_1 = require("./run"); /** * @deprecated * * Please use the `onboardbase run` command instead. */ class Build extends command_1.Command { async run() { this.warn(`The build command will be deprecated in favor of run command`); const { args, flags } = this.parse(Build); const commandChain = []; if (flags.command) commandChain.push("--command", flags.command); if (flags.project) commandChain.push("--project", flags.project); if (flags.environment) commandChain.push("--environment", flags.environment); if (flags.passphrase) commandChain.push("--passphrase", flags.passphrase); if (flags.prefix) commandChain.push("--prefix", flags.prefix); if (flags["live-reload"]) commandChain.push("--live-reload"); if (args.command) commandChain.push(args.command); await run_1.default.run(commandChain); } } exports.default = Build; Build.description = "Run a command with secrets injected into the environment"; Build.flags = { help: command_1.flags.help({ char: "h" }), project: command_1.flags.string({ char: "p", description: "name of project", }), environment: command_1.flags.string({ char: "e", description: "Environment to run by default", }), command: command_1.flags.string({ char: "c", description: "Command to run", required: false, }), prefix: command_1.flags.string({ char: "k", description: "Prefix", required: false }), passphrase: command_1.flags.string({ char: "s", description: "Passphrase", required: false, }), "live-reload": command_1.flags.boolean({ description: "Live Reload", required: false, }), }; Build.args = [{ name: "command" }];