-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.js
More file actions
19 lines (15 loc) · 786 Bytes
/
index.js
File metadata and controls
19 lines (15 loc) · 786 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#!/usr/bin/env node
const path = require('path')
const { Command } = require('commander')
const updateNotifier = require('update-notifier')
const pkg = require('./package.json')
updateNotifier({ pkg, updateCheckInterval: 3600 }).notify()
const program = new Command()
program
.version(pkg.version)
program
.command('deploy [path]', 'Performs a deployment', { isDefault: true, executableFile: path.join(__dirname, 'deploy.js') })
.command('config', 'Config leaf', { executableFile: path.join(__dirname, 'config.js') })
.command('logs [name]', 'Get the serverless logs', { executableFile: path.join(__dirname, 'logs.js') })
.command('profile [name]', 'Set leaf config according to the profile', { executableFile: path.join(__dirname, 'profile.js') })
program.parse(process.argv)