multi-clasp2
Version:
Google Clasp wrapper to push changes to multiple Apps Script projects at once.
61 lines • 2.58 kB
JavaScript
;
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const commander_1 = require("commander");
const common_1 = require("./common");
const run_1 = __importDefault(require("./run"));
const push_1 = __importDefault(require("./push"));
const package_json_1 = require("../package.json");
const program = new commander_1.Command();
program
.command('status')
.description('Lists files that will be pushed by clasp')
.option('--json', 'Show status in JSON form')
.action(common_1.genericAction);
program
.command('push')
.description('Update the remote project')
.option('-f, --force', 'Forcibly overwrites the remote manifest.')
.option('--retry <n>', 'If the push of an App Script fail with it will retry n times. Default is 1.', '1')
.action(push_1.default);
program
.command('open')
.description('Open a script')
.option('--webapp', 'Open web application in the browser')
.option('--creds', 'Open the URL to create credentials')
.option('--addon', 'List parent IDs and open the URL of the first one')
.action(common_1.genericAction);
program.command('deployments')
.description('List deployment ids of a script')
.action(common_1.genericAction);
program
.command('deploy')
.description('Deploy a project')
.option('-V, --versionNumber <version>', 'The project version') // We can't use `version` in subcommand
.option('-d, --description <description>', 'The deployment description')
.action(common_1.genericAction);
program
.command('undeploy')
.description('Undeploy a deployment of a project')
.option('-a, --all', 'Undeploy all deployments')
.action(common_1.genericAction);
program
.command('run [functionName]')
.description('Run a function in your Apps Scripts project')
.option('--nondev', 'Run script function in non-devMode')
.option('-p, --params [StringArray]', 'Add parameters required for the function as a JSON String Array')
.action(run_1.default);
program
.command('version [description]')
.description('Creates an immutable version of the script')
.action(common_1.genericAction);
program
.command('versions')
.description('List versions of a script')
.action(common_1.genericAction);
program.version(package_json_1.version || 'unknown', '-v, --version', 'output the current version');
program.parse();
//# sourceMappingURL=index.js.map