Skip to content

Conversation

Copy link

Copilot AI commented Jan 28, 2026

Overview

Migrated package publishing from Lerna to NX Release with file-based versioning (Version Plans). Contributors now create version plan files via yarn nx release plan instead of relying on conventional commit messages for version bumps.

Configuration:

  • Added release config in nx.json: versionPlans: true, projectsRelationship: "independent"
  • Created .nx/version-plans/ for version plan files
  • Updated .gitignore to track version plans, ignore cache/workspace-data

Workflows:

  • publish-production.yml: lerna publishnx release -y
  • publish-alpha.yml: Uses nx release --skip-publish prerelease --preid=alpha.{SHA} followed by nx release publish --tag=alpha.{SHA} for alpha builds
    • Temporarily moves .nx/version-plans directory during alpha releases (version plans cannot be used with specifier arguments)

Dependency Cleanup:

  • Removed lerna, conventional-changelog-cli, conventional-changelog-conventionalcommits
  • Removed lerna.json
  • Updated yarn.lock (−3107 lines)

Version Plan Format:

---
gamut: minor
gamut-styles: patch
---

Add ghost button variant and fix spacing

- New ghost variant for Button component
- Fixed Card margin spacing

CLI Usage:
All NX Release commands use correct flags per official documentation:

  • Production uses -y (short form of --yes) on main nx release command
  • Alpha uses --skip-publish (not --skipPublish) on main nx release command
  • Subcommands (nx release version, nx release publish) don't accept --yes or -y flags

Exact versions for internal dependencies maintained (NX default). Alpha publishing unchanged from contributor perspective.

PR Checklist

  • Related to designs: N/A
  • Related to JIRA ticket: N/A
  • I have run this code to verify it works
  • This PR includes unit tests for the code change (N/A - infrastructure change)
  • This PR includes testing instructions tests for the code change
  • The alpha package of this PR is passing end-to-end tests in all relevant Codecademy repositories

Testing Instructions

Verify NX Release:

yarn nx release --dry-run  # Should complete without errors

Create version plan:

yarn nx release plan  # Interactive prompts to create version plan

Test version plan application:

echo -e "---\ngamut: patch\n---\n\nTest" > .nx/version-plans/test.md
yarn nx release --dry-run  # Should show gamut bumping 67.6.4 → 67.6.5
rm .nx/version-plans/test.md

Test alpha workflow locally:

# Simulate alpha versioning
mv .nx/version-plans .nx/version-plans.backup
yarn nx release --skip-publish prerelease --preid=alpha.test123 --dry-run
mv .nx/version-plans.backup .nx/version-plans

No action needed - workflows apply version plans on merge to main. Alpha builds continue working automatically.

PR Links and Envs

N/A - Infrastructure change, no end-user facing changes


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

@CLAassistant
Copy link

CLAassistant commented Jan 28, 2026

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
1 out of 2 committers have signed the CLA.

✅ jakemhiller
❌ Copilot
You have signed the CLA already but the status is still pending? Let us recheck it.

Copilot AI changed the title [WIP] Update repo to use NX release for package publishing chore: migrate from Lerna to NX Release with Version Plans Jan 28, 2026
Copilot AI requested a review from jakemhiller January 28, 2026 18:35
@codecov
Copy link

codecov bot commented Jan 28, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 89.78%. Comparing base (dba147a) to head (535b6d8).
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3254      +/-   ##
==========================================
+ Coverage   89.65%   89.78%   +0.12%     
==========================================
  Files         353      361       +8     
  Lines        5065     5147      +82     
  Branches     1606     1654      +48     
==========================================
+ Hits         4541     4621      +80     
- Misses        516      518       +2     
  Partials        8        8              
Flag Coverage Δ
main ?
pull-request 89.78% <ø> (?)

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

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

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@nx-cloud
Copy link

nx-cloud bot commented Jan 28, 2026

View your CI Pipeline Execution ↗ for commit 535b6d8


☁️ Nx Cloud last updated this comment at 2026-01-28 20:19:48 UTC

@jakemhiller jakemhiller force-pushed the copilot/update-to-nx-release branch from a521830 to 85ce914 Compare January 28, 2026 19:48
@jakemhiller
Copy link
Member

@copilot there are problems with the CLI usage of nx release. --skipPublish and --yes are not valid options. make sure you are using the nx mcp and documentation https://nx.dev/docs/features/manage-releases to know exactly how to use nx release.

Copy link
Author

Copilot AI commented Jan 28, 2026

@copilot there are problems with the CLI usage of nx release. --skipPublish and --yes are not valid options. make sure you are using the nx mcp and documentation https://nx.dev/docs/features/manag...

Fixed in commit 49904d3. Changes made:

Production workflow:

  • Changed --yes to -y (the correct short form)

Alpha workflow:

  • Removed invalid --skipPublish flag (correct flag is --skip-publish and only works on nx release, not nx release version)
  • Removed --yes from nx release publish (not a valid flag for the publish subcommand)
  • Changed to use nx release --skip-publish prerelease --preid="alpha.{SHA}" followed by nx release publish --tag="alpha.{SHA}"
  • Added workaround to temporarily move .nx/version-plans directory during alpha builds (since version plans can't be used with a specifier argument)

Both workflows now use the correct NX Release CLI syntax per the official documentation.

@github-actions
Copy link
Contributor

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.

3 participants