Commit ba00cb05 authored by rockyl's avatar rockyl

更新

parent 5ab92118
...@@ -2,11 +2,18 @@ const program = require('commander'); ...@@ -2,11 +2,18 @@ const program = require('commander');
const {exit, executeBuildProcess, updateProjectConfig} = require('./tools'); const {exit, executeBuildProcess, updateProjectConfig} = require('./tools');
program program
.option('-u, --upload-auto', 'Auto upload after publish success', false)
.parse(process.argv); .parse(process.argv);
async function execute() { async function execute() {
const version = await executeBuildProcess('publish'); const version = await executeBuildProcess('publish');
//console.log('detected version:', version);
updateProjectConfig('version', version); updateProjectConfig('version', version);
if(program.uploadAuto){
console.log('\nAuto uploading...');
require('./game-cli-upload');
}
} }
execute().catch(e => { execute().catch(e => {
......
...@@ -18,6 +18,7 @@ async function execute() { ...@@ -18,6 +18,7 @@ async function execute() {
} }
if(version){ if(version){
console.log('upload version:', version);
if(remotePath){ if(remotePath){
try { try {
await ossUpload({ await ossUpload({
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment