Skip to content

fix(release): set the package version before the build, so the CLI reports it - #245

Merged
boazpoolman merged 1 commit into
pluginpal:masterfrom
PaulRichez:fix/cli-reported-version
Nov 13, 2026
Merged

boazpoolman merged 1 commit into
pluginpal:masterfrom
PaulRichez:fix/cli-reported-version

Conversation

@PaulRichez

Copy link
Copy Markdown
Contributor

What does it do?

In publish.yml, the "Set package version" step now runs before "Build the plugin", instead of just before npm publish. Nothing else in the workflow changes: the version bump is still committed back after the publish.

Why is it needed?

The CLI bundles package.json when the plugin is built, and --version reports the version found there. The build runs before yarn version sets the version from the tag, so the published CLI reports the previous version.

With 3.3.0 from npm, npx config-sync --version prints 3.2.0. 3.2.0 printed 3.1.2 the same way.

How to test it?

Install 3.3.0 from npm in a Strapi app and run npx config-sync --version: it prints 3.2.0. With this change, the CLI of the next release reports the tag's version.

Related issue(s)/PR(s)

None.

@codecov

codecov Bot commented Nov 10, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (7166c56) to head (cef7e99).
⚠️ Report is 2 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff            @@
##            master      #245   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            2         2           
  Lines           22        22           
  Branches         3         3           
=========================================
  Hits            22        22           
Flag Coverage Δ
unit 100.00% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@boazpoolman boazpoolman left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch

@boazpoolman
boazpoolman merged commit 1300658 into pluginpal:master Nov 13, 2026
7 of 8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants