You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
#!/usr/bin/env node
|
|
|
|
|
|
|
|
'use strict';
|
|
|
|
|
|
|
|
const clean = require('./clean.js');
|
|
|
|
const sync = require('./sync.js');
|
|
|
|
const create = require('./create.js');
|
|
|
|
|
|
|
|
if (process.argv[2] == 'clean') {
|
|
|
|
const files = [];
|
|
|
|
for (let i = 3; i < process.argv.length; i++) {
|
|
|
|
files.push(process.argv[i]);
|
|
|
|
}
|
|
|
|
clean(files);
|
|
|
|
} else if (process.argv[2] == 'create') {
|
|
|
|
create();
|
|
|
|
} else if (process.argv[2] == 'sync') {
|
|
|
|
sync();
|
|
|
|
} else {
|
|
|
|
console.info(`
|
|
|
|
用法: npx platform [-options]
|
|
|
|
其中选项包括:
|
|
|
|
create 创建模版工程
|
|
|
|
sync 同步工程配置文件
|
|
|
|
`);
|
|
|
|
}
|