Skip to content

Migrate from Github Actions v2 to v3#87

Merged
archive merged 2 commits intomasterfrom
v2tov3
Apr 3, 2026
Merged

Migrate from Github Actions v2 to v3#87
archive merged 2 commits intomasterfrom
v2tov3

Conversation

@archive
Copy link
Copy Markdown
Owner

@archive archive commented Apr 3, 2026

Migrated the codebase from CommonJS to ES Modules to support @actions/core v3, which dropped CommonJS support.

  • Source files: converted all require()/module.exports to import/export across 13 files.
  • Jest: renamed jest.config.js -> jest.config.cjs (keeps CJS syntax while the rest of the project is ESM), updated test script to run with --experimental-vm-modules, and replaced jest.mock() with
    jest.unstable_mockModule() (the ESM-compatible mocking API).
  • Test files that use the jest object now explicitly import it from @jest/globals.
  • ESLint: updated sourceType from "commonjs" to "module".
  • package.json: added "type": "module" and bumped @actions/core to ^3.0.0.

Bonus: Removed dependency "@actions/github" since it was not needed anymore.

@archive archive changed the title [WIP] Migrate from Github Actions v2 to v3 Migrate from Github Actions v2 to v3 Apr 3, 2026
@archive archive merged commit fdb954e into master Apr 3, 2026
17 checks passed
@archive archive deleted the v2tov3 branch April 3, 2026 21:10
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.

1 participant