@farris/cli 1.0.24 → 1.0.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ci/cli.js +17 -10
- package/package.json +1 -1
    
        package/ci/cli.js
    CHANGED
    
    | @@ -245,12 +245,13 @@ function updateMonoWorkspaceVersion(monoWorkspace, updateVersionType, commitUrl) | |
| 245 245 | 
             
                childProcess.execSync('git', ['commit', '-m', `Update MonoWorkspace version to v${packageConfig.version}. [skip ci]`]);
         | 
| 246 246 | 
             
                console.log(`Update MonoWorkspace version to v${packageConfig.version}`);
         | 
| 247 247 | 
             
                const branch = childProcess.execSync("git", ["rev-parse", "--abbrev-ref", "HEAD"]);
         | 
| 248 | 
            -
                console.log(`executing git push ${branch}`);
         | 
| 249 248 | 
             
                // 提交变更集
         | 
| 250 249 | 
             
                if (commitUrl) {
         | 
| 251 | 
            -
                     | 
| 250 | 
            +
                    console.log(`executing git push ${branch} to ${commitUrl}`);
         | 
| 251 | 
            +
                    return childProcess.exec("git", ["push", commitUrl]);
         | 
| 252 252 | 
             
                } else {
         | 
| 253 | 
            -
                     | 
| 253 | 
            +
                    console.log(`executing git push ${branch}`);
         | 
| 254 | 
            +
                    return childProcess.exec('git', ['push']);
         | 
| 254 255 | 
             
                }
         | 
| 255 256 | 
             
            }
         | 
| 256 257 |  | 
| @@ -267,7 +268,7 @@ function builderVersionChangeMessage(prefix, updatedVersions, suffix = '') { | |
| 267 268 | 
             
            }
         | 
| 268 269 |  | 
| 269 270 | 
             
            function commitVersionChanges(updatedVersions, commitUrl) {
         | 
| 270 | 
            -
                const commitMessage = builderVersionChangeMessage('Update', updatedVersions, ' | 
| 271 | 
            +
                const commitMessage = builderVersionChangeMessage('Update', updatedVersions, ' [skip ci]');
         | 
| 271 272 |  | 
| 272 273 | 
             
                if (commitMessage) {
         | 
| 273 274 | 
             
                    // 向git缓冲区中添加变更
         | 
| @@ -278,12 +279,14 @@ function commitVersionChanges(updatedVersions, commitUrl) { | |
| 278 279 | 
             
                    console.log(commitMessage);
         | 
| 279 280 |  | 
| 280 281 | 
             
                    const branch = childProcess.execSync("git", ["rev-parse", "--abbrev-ref", "HEAD"]);
         | 
| 281 | 
            -
             | 
| 282 | 
            +
             | 
| 282 283 | 
             
                    // 提交变更集
         | 
| 283 284 | 
             
                    if (commitUrl) {
         | 
| 284 | 
            -
                         | 
| 285 | 
            +
                        console.log(`executing git push ${branch} to ${commitUrl}`);
         | 
| 286 | 
            +
                        return childProcess.exec("git", ["push", commitUrl]);
         | 
| 285 287 | 
             
                    } else {
         | 
| 286 | 
            -
                         | 
| 288 | 
            +
                        console.log(`executing git push ${branch}`);
         | 
| 289 | 
            +
                        return childProcess.exec('git', ['push']);
         | 
| 287 290 | 
             
                    }
         | 
| 288 291 | 
             
                }
         | 
| 289 292 | 
             
            }
         | 
| @@ -399,9 +402,13 @@ function publish(commitUrl, updateVersionType) { | |
| 399 402 | 
             
                                return workspace;
         | 
| 400 403 | 
             
                            }, monoWorkspace);
         | 
| 401 404 | 
             
                            const updatedVersions = monoWorkspace.updateResult;
         | 
| 402 | 
            -
                            commitVersionChanges(updatedVersions, commitUrl) | 
| 403 | 
            -
             | 
| 404 | 
            -
             | 
| 405 | 
            +
                            return commitVersionChanges(updatedVersions, commitUrl)
         | 
| 406 | 
            +
                                .then((result) => {
         | 
| 407 | 
            +
                                    return updateMonoWorkspaceVersion(monoWorkspace, updateVersionType, commitUrl);
         | 
| 408 | 
            +
                                })
         | 
| 409 | 
            +
                                .then((reulst) => {
         | 
| 410 | 
            +
                                    return Promise.resolve(monoWorkspace);
         | 
| 411 | 
            +
                                });
         | 
| 405 412 | 
             
                        });
         | 
| 406 413 | 
             
                });
         | 
| 407 414 | 
             
                // 5. 编译所有Angular工作区
         |