@clickview/ship-it 0.0.35-dev.14 → 0.0.35-dev.16

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.
@@ -359,22 +359,6 @@ var GitLabApiClient = /** @class */ (function () {
359
359
  });
360
360
  });
361
361
  };
362
- GitLabApiClient.prototype.updateFiles = function (projectId, branchName, commitMessage, files) {
363
- return __awaiter(this, void 0, void 0, function () {
364
- return __generator(this, function (_a) {
365
- switch (_a.label) {
366
- case 0: return [4 /*yield*/, this.client.Commits.create(projectId, branchName, commitMessage, files.map(function (f) { return ({
367
- action: 'update',
368
- filePath: f.filePath,
369
- content: f.content
370
- }); }))];
371
- case 1:
372
- _a.sent();
373
- return [2 /*return*/];
374
- }
375
- });
376
- });
377
- };
378
362
  GitLabApiClient.prototype.commit = function (projectId, branchName, files, commitMessage) {
379
363
  return __awaiter(this, void 0, void 0, function () {
380
364
  return __generator(this, function (_a) {
package/lib/src/index.js CHANGED
File without changes
@@ -353,9 +353,6 @@ var GitLabService = /** @class */ (function () {
353
353
  GitLabService.prototype.updateFile = function (projectId, filePath, branchName, content, commit) {
354
354
  return this.apiClient.updateFile(projectId, filePath, branchName, content, commit);
355
355
  };
356
- GitLabService.prototype.updateFiles = function (projectId, branchName, commitMessage, files) {
357
- return this.apiClient.updateFiles(projectId, branchName, commitMessage, files);
358
- };
359
356
  GitLabService.prototype.commit = function (projectId, branchName, commitMessage, files) {
360
357
  return __awaiter(this, void 0, void 0, function () {
361
358
  return __generator(this, function (_a) {
@@ -69,13 +69,14 @@ var BumpPackagesTask = /** @class */ (function () {
69
69
  }
70
70
  BumpPackagesTask.prototype.run = function (options) {
71
71
  return __awaiter(this, void 0, void 0, function () {
72
- var _a, branch, isValid, commitFiles;
72
+ var _a, branch, isValid, commitFiles, _i, commitFiles_1, file;
73
73
  return __generator(this, function (_b) {
74
74
  switch (_b.label) {
75
75
  case 0:
76
76
  utils_1.Logger.logTask('Bumping clickview npm package versions');
77
77
  this.isReleaseBranch = RELEASE_BRANCH_REGEX.test(options.branchName);
78
78
  this.isHotfixBranch = HOTFIX_BRANCH_REGEX.test(options.branchName);
79
+ utils_1.Logger.logTask('Detected that monorepo is currently in a pre-release state');
79
80
  _a = this;
80
81
  return [4 /*yield*/, this.getIsInPrerelease(options.branchName)];
81
82
  case 1:
@@ -90,11 +91,21 @@ var BumpPackagesTask = /** @class */ (function () {
90
91
  isValid = this.validateOptions(options);
91
92
  if (!isValid)
92
93
  return [2 /*return*/, false];
94
+ utils_1.Logger.logInfo('Options are valid! Proceeding to bump package versions.');
93
95
  commitFiles = this.getCommitFiles(options);
94
- return [4 /*yield*/, this.service.commit(utils_1.ProjectIds.MONOREPO_PROJECT_ID, options.branchName, 'Bump package versions', commitFiles)];
95
- case 3:
96
- _b.sent();
97
- utils_1.Logger.logSuccess('Successfully executed Lerna versioning command.');
96
+ utils_1.Logger.logInfo('Writing new versions to package.json files...');
97
+ for (_i = 0, commitFiles_1 = commitFiles; _i < commitFiles_1.length; _i++) {
98
+ file = commitFiles_1[_i];
99
+ (0, fs_1.writeFileSync)(file.filePath, file.content);
100
+ }
101
+ // Logger.logInfo('Committing new versions...');
102
+ // await this.service.commit(
103
+ // ProjectIds.MONOREPO_PROJECT_ID,
104
+ // options.branchName,
105
+ // 'Bump package versions',
106
+ // commitFiles
107
+ // );
108
+ utils_1.Logger.logSuccess('Successfully updated version numbers.');
98
109
  return [2 /*return*/, true];
99
110
  }
100
111
  });
@@ -143,7 +154,6 @@ var BumpPackagesTask = /** @class */ (function () {
143
154
  var content = '';
144
155
  try {
145
156
  content = (0, fs_1.readFileSync)(filePath, { encoding: 'utf8' });
146
- utils_1.Logger.logInfo('file', filePath, content);
147
157
  }
148
158
  catch (_a) {
149
159
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@clickview/ship-it",
3
- "version": "0.0.35-dev.14",
3
+ "version": "0.0.35-dev.16",
4
4
  "description": "Release Manager",
5
5
  "main": "./lib/index.js",
6
6
  "bin": {