polyci 0.0.31 → 0.0.33

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.
Files changed (2) hide show
  1. package/dist/main.js +10 -5
  2. package/package.json +1 -1
package/dist/main.js CHANGED
@@ -186,12 +186,13 @@ function appendModuleBuildJob(lines, module) {
186
186
  lines.push(` - echo "PLI_MODULE_NAME=${module.moduleName}" > polyci.env`);
187
187
  lines.push(` - echo "PLI_MODULE_PATH=${module.modulePath}" >> polyci.env`);
188
188
  lines.push(` - echo "PLI_MODULE_TYPE=${module.moduleType}" >> polyci.env`);
189
+ lines.push(` - cat polyci.env`);
189
190
  lines.push(` - source polyci.env`);
190
191
  lines.push(` - source "ci/${module.moduleType}/build.sh"`);
191
192
  lines.push(` artifacts:`);
192
193
  lines.push(` paths:`);
193
194
  lines.push(` - ${module.modulePath}/dist`);
194
- lines.push(` - ${module.modulePath}/policy.env`);
195
+ lines.push(` - ${module.modulePath}/polyci.env`);
195
196
  lines.push(` expire_in: 1 day`);
196
197
  lines.push(``);
197
198
  }
@@ -207,12 +208,13 @@ function appendModuleTestJob(lines, module) {
207
208
  lines.push(` script:`);
208
209
  lines.push(` - cp -r ci "${module.modulePath}/ci"`);
209
210
  lines.push(` - cd ${module.modulePath}`);
211
+ lines.push(` - cat polyci.env`);
210
212
  lines.push(` - source polyci.env`);
211
213
  lines.push(` - source "ci/${module.moduleType}/test.sh"`);
212
214
  lines.push(` artifacts:`);
213
215
  lines.push(` paths:`);
214
216
  lines.push(` - ${module.modulePath}/dist`);
215
- lines.push(` - ${module.modulePath}/policy.env`);
217
+ lines.push(` - ${module.modulePath}/polyci.env`);
216
218
  lines.push(``);
217
219
  }
218
220
  function appendModuleReleaseJob(lines, module, tagPattern, mainBranch, versionTemplate, branchVersionTemplate, tagTemplate) {
@@ -249,7 +251,7 @@ function appendModuleReleaseJob(lines, module, tagPattern, mainBranch, versionTe
249
251
  lines.push(` fi`);
250
252
  lines.push(` fi`);
251
253
  lines.push(` - |`);
252
- lines.push(` if [ -n "$PLI_MODULE_VERSION" && -n "$PLI_MODULE_TAG" ]; then`);
254
+ lines.push(` if [ -n "$PLI_MODULE_VERSION" ] && [ -n "$PLI_MODULE_TAG" ]; then`);
253
255
  lines.push(` echo "PLI_MODULE_VERSION=$PLI_MODULE_VERSION" >> ${module.modulePath}/polyci.env`);
254
256
  lines.push(` echo "PLI_MODULE_TAG=$PLI_MODULE_TAG" >> ${module.modulePath}/polyci.env`);
255
257
  lines.push(` fi`);
@@ -281,10 +283,11 @@ function appendGlobalReleaseJob(lines, modules) {
281
283
  for (const module of modules) {
282
284
  lines.push(` - |`);
283
285
  lines.push(` if [ -f "${module.modulePath}/polyci.env" ]; then`);
284
- lines.push(` unset PLI_MODULE_NAME`);
286
+ lines.push(` unset PLI_MODULE_VERSION`);
285
287
  lines.push(` unset PLI_MODULE_TAG`);
288
+ lines.push(` cat "${module.modulePath}/polyci.env"`);
286
289
  lines.push(` source "${module.modulePath}/polyci.env"`);
287
- lines.push(` if [ -n "$PLI_MODULE_NAME" && -n "$PLI_MODULE_TAG" ]; then`);
290
+ lines.push(` if [ -n "$PLI_MODULE_VERSION" ] && [ -n "$PLI_MODULE_TAG" ]; then`);
288
291
  lines.push(` cp -r ci "${module.modulePath}/ci"`);
289
292
  lines.push(` ROOT_REPO_DIR="\${pwd}"`);
290
293
  lines.push(` cd "${module.modulePath}"`);
@@ -330,6 +333,7 @@ function appendModulePublishJob(lines, module) {
330
333
  lines.push(` script:`);
331
334
  lines.push(` - cp -r ci "${module.modulePath}/ci"`);
332
335
  lines.push(` - cd ${module.modulePath}`);
336
+ lines.push(` - cat polyci.env`);
333
337
  lines.push(` - source polyci.env`);
334
338
  lines.push(` - source "ci/${module.moduleType}/publish.sh"`);
335
339
  lines.push(` artifacts:`);
@@ -350,6 +354,7 @@ function appendModuleDeployJob(lines, module) {
350
354
  lines.push(` script:`);
351
355
  lines.push(` - cp -r ci "${module.modulePath}/ci"`);
352
356
  lines.push(` - cd ${module.modulePath}`);
357
+ lines.push(` - cat polyci.env`);
353
358
  lines.push(` - source polyci.env`);
354
359
  lines.push(` - source "ci/${module.moduleType}/deploy.sh"`);
355
360
  lines.push(``);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "polyci",
3
3
  "description": "Monorepo CI/CD utilities.",
4
- "version": "0.0.31",
4
+ "version": "0.0.33",
5
5
  "type": "module",
6
6
  "private": false,
7
7
  "author": "Alexander Tsarev",