github-action-readme-generator 1.12.4 → 1.12.5

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/CHANGELOG.md CHANGED
@@ -1,3 +1,10 @@
1
+ ## [1.12.5](https://github.com/bitflight-devops/github-action-readme-generator/compare/v1.12.4...v1.12.5) (2026-08-15)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * **versioning:** preserve parsed falsy branch refs ([#663](https://github.com/bitflight-devops/github-action-readme-generator/issues/663)) ([1bf6d0e](https://github.com/bitflight-devops/github-action-readme-generator/commit/1bf6d0e8d549e79823db0e242ef2fd3bb5ae9e9d))
7
+
1
8
  ## [1.12.4](https://github.com/bitflight-devops/github-action-readme-generator/compare/v1.12.3...v1.12.4) (2026-08-15)
2
9
 
3
10
 
package/README.md CHANGED
@@ -177,7 +177,7 @@ This configuration will automatically regenerate your README whenever `action.ym
177
177
  <!-- start usage -->
178
178
 
179
179
  ```yaml
180
- - uses: bitflight-devops/github-action-readme-generator@v1.12.3
180
+ - uses: bitflight-devops/github-action-readme-generator@v1.12.4
181
181
  with:
182
182
  # Description: The absolute or relative path to the `action.yml` file to read in
183
183
  # from.
package/dist/bin/index.js CHANGED
@@ -42613,15 +42613,6 @@ const unicodeWordMatch = /(?:[\dA-Za-z\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00
42613
42613
  //#endregion
42614
42614
  //#region src/helpers.ts
42615
42615
  /**
42616
- * Returns the input value if it is not empty, otherwise returns undefined.
42617
- * @param value - The input value to check.
42618
- * @returns The input value if it is not empty, otherwise undefined.
42619
- */
42620
- function undefinedOnEmpty(value) {
42621
- if (!value || value === "") return;
42622
- return value;
42623
- }
42624
- /**
42625
42616
  * Converts the given text to title case.
42626
42617
  * @param text - The text to convert.
42627
42618
  * @returns The text converted to title case.
@@ -42911,7 +42902,10 @@ function getCurrentVersionString(inputs) {
42911
42902
  versionString = detectedVersion ?? "0.0.0";
42912
42903
  const prefix = inputs.config.get("versioning:prefix") ?? "v";
42913
42904
  if (versionSource !== "git-branch" && versionSource !== "git-sha" && versionString && !versionString.startsWith(prefix)) versionString = `${prefix}${versionString}`;
42914
- } else versionString = undefinedOnEmpty(inputs.config.get("versioning:branch")) ?? "main";
42905
+ } else {
42906
+ const configuredBranch = inputs.config.get("versioning:branch");
42907
+ versionString = configuredBranch === void 0 || configuredBranch === "" ? "main" : String(configuredBranch);
42908
+ }
42915
42909
  log.debug(`version to use in generated example is ${versionString}`);
42916
42910
  return versionString;
42917
42911
  }
package/dist/mjs/index.js CHANGED
@@ -422,15 +422,6 @@ const unicodeWordMatch = /(?:[\dA-Za-z\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00
422
422
  //#endregion
423
423
  //#region src/helpers.ts
424
424
  /**
425
- * Returns the input value if it is not empty, otherwise returns undefined.
426
- * @param value - The input value to check.
427
- * @returns The input value if it is not empty, otherwise undefined.
428
- */
429
- function undefinedOnEmpty(value) {
430
- if (!value || value === "") return;
431
- return value;
432
- }
433
- /**
434
425
  * Converts the given text to title case.
435
426
  * @param text - The text to convert.
436
427
  * @returns The text converted to title case.
@@ -720,7 +711,10 @@ function getCurrentVersionString(inputs) {
720
711
  versionString = detectedVersion ?? "0.0.0";
721
712
  const prefix = inputs.config.get("versioning:prefix") ?? "v";
722
713
  if (versionSource !== "git-branch" && versionSource !== "git-sha" && versionString && !versionString.startsWith(prefix)) versionString = `${prefix}${versionString}`;
723
- } else versionString = undefinedOnEmpty(inputs.config.get("versioning:branch")) ?? "main";
714
+ } else {
715
+ const configuredBranch = inputs.config.get("versioning:branch");
716
+ versionString = configuredBranch === void 0 || configuredBranch === "" ? "main" : String(configuredBranch);
717
+ }
724
718
  log.debug(`version to use in generated example is ${versionString}`);
725
719
  return versionString;
726
720
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "github-action-readme-generator",
3
3
  "displayName": "bitflight-devops/github-action-readme-generator",
4
- "version": "1.12.4",
4
+ "version": "1.12.5",
5
5
  "description": "The docs generator for GitHub Actions. Auto-syncs action.yml to README.md with 8 sections: inputs, outputs, usage, badges, branding & more. Works as CLI or GitHub Action.",
6
6
  "keywords": [
7
7
  "github-actions",