polyci 0.0.33 → 0.0.35

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 +4 -2
  2. package/package.json +1 -1
package/dist/main.js CHANGED
@@ -7,7 +7,7 @@ const log = pino(pretty());
7
7
  const DEFAULT_TAG_TEMPLATE = "{module}-v{version}";
8
8
  const DEFAULT_VERSION_TEMPLATE = "{version}";
9
9
  const DEFAULT_BRANCH_VERSION_TEMPLATE = "{version}-{branch}-{increment}";
10
- const DEFAULT_TAG_PATTERN = "^$MODULE_NAME-v(?<version>\\d+(\\.\\d+)*)-$CI_COMMIT_BRANCH-(?<increment>\\d+(\\.\\d+)*)$";
10
+ const DEFAULT_TAG_PATTERN = "^$PLI_MODULE_NAME-v(?<version>\\d+(\\.\\d+)*)(-$CI_COMMIT_BRANCH-(?<increment>\\d+(\\.\\d+)*))?$";
11
11
  const ALLOWED_TAG_PLACEHOLDERS = new Set(["module", "version"]);
12
12
  const ALLOWED_VERSION_PLACEHOLDERS = new Set(["branch", "version", "increment"]);
13
13
  function applyVersionTemplate(template) {
@@ -230,6 +230,8 @@ function appendModuleReleaseJob(lines, module, tagPattern, mainBranch, versionTe
230
230
  lines.push(` script:`);
231
231
  lines.push(` - apk update`);
232
232
  lines.push(` - apk add $GIT_PACKAGE`);
233
+ lines.push(` - cat "${module.modulePath}/polyci.env"`);
234
+ lines.push(` - source "${module.modulePath}/polyci.env"`);
233
235
  lines.push(` - npx semalease --cwd "${module.modulePath}" --tag-pattern "${tagPattern}" ${module.modulePath}/semalease.env`);
234
236
  lines.push(` - |`);
235
237
  lines.push(` if [ -f "${module.modulePath}/semalease.env" ]; then`);
@@ -289,7 +291,7 @@ function appendGlobalReleaseJob(lines, modules) {
289
291
  lines.push(` source "${module.modulePath}/polyci.env"`);
290
292
  lines.push(` if [ -n "$PLI_MODULE_VERSION" ] && [ -n "$PLI_MODULE_TAG" ]; then`);
291
293
  lines.push(` cp -r ci "${module.modulePath}/ci"`);
292
- lines.push(` ROOT_REPO_DIR="\${pwd}"`);
294
+ lines.push(` ROOT_REPO_DIR="\${PWD}"`);
293
295
  lines.push(` cd "${module.modulePath}"`);
294
296
  lines.push(` echo "Release ${module.moduleName} version $PLI_MODULE_VERSION."`);
295
297
  lines.push(` source "ci/${module.moduleType}/release.sh"`);
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.33",
4
+ "version": "0.0.35",
5
5
  "type": "module",
6
6
  "private": false,
7
7
  "author": "Alexander Tsarev",