Skip to content

Commit

Permalink
fix(@angular/cli): disable update commit creation by default
Browse files Browse the repository at this point in the history
Closes #16013
  • Loading branch information
clydin authored and vikerman committed Nov 7, 2019
1 parent 7e6e6f7 commit b2c62b2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions packages/angular/cli/commands/update-impl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -425,7 +425,7 @@ export class UpdateCommand extends Command<UpdateCommandSchema> {
packageName,
migrations,
migrationRange,
!options.skipCommits,
options.createCommits,
);

return success ? 0 : 1;
Expand Down Expand Up @@ -539,7 +539,7 @@ export class UpdateCommand extends Command<UpdateCommandSchema> {
migrateExternal: true,
});

if (success && !options.skipCommits) {
if (success && options.createCommits) {
this.createCommit('Angular CLI update\n' + packagesToUpdate.join('\n'), []);
}

Expand All @@ -558,7 +558,7 @@ export class UpdateCommand extends Command<UpdateCommandSchema> {
migration.package,
migration.collection,
new semver.Range('>' + migration.from + ' <=' + migration.to),
!options.skipCommits,
options.createCommits,
);

if (!result) {
Expand Down
4 changes: 2 additions & 2 deletions packages/angular/cli/commands/update.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@
"type": "boolean",
"default": false
},
"skipCommits": {
"description": "Do not create source control commits for updates and migrations.",
"createCommits": {
"description": "Create source control commits for updates and migrations.",
"type": "boolean",
"default": false,
"aliases": ["C"]
Expand Down

0 comments on commit b2c62b2

Please sign in to comment.