Skip to content

fix: drop dependency upon @actions/github to get the context.#2594

Merged
Jason3S merged 3 commits intomainfrom
dev-github
Jan 27, 2026
Merged

fix: drop dependency upon @actions/github to get the context.#2594
Jason3S merged 3 commits intomainfrom
dev-github

Conversation

@Jason3S
Copy link
Contributor

@Jason3S Jason3S commented Jan 27, 2026

Pull request overview

This PR removes the @actions/github dependency and replaces it with an internal implementation of the Context class. This reduces the dependency footprint by eliminating the entire @actions/github package and its transitive dependencies (including @octokit/* packages).

Changes:

  • Removed @actions/github dependency from package.json and pnpm-lock.yaml
  • Created internal implementation of Context class copied from @actions/toolkit
  • Added proper MIT license attribution for the copied code
  • Updated all imports to use the internal implementation instead of the external package

@coveralls
Copy link

coveralls commented Jan 27, 2026

Pull Request Test Coverage Report for Build 21415015930

Details

  • 27 of 27 (100.0%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.2%) to 95.688%

Totals Coverage Status
Change from base Build 21412805820: -0.2%
Covered Lines: 366
Relevant Lines: 371

💛 - Coveralls

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR removes the @actions/github dependency and replaces it with an internal implementation of the Context class. This reduces the dependency footprint by eliminating the entire @actions/github package and its transitive dependencies (including @octokit/* packages).

Changes:

  • Removed @actions/github dependency from package.json and pnpm-lock.yaml
  • Created internal implementation of Context class copied from @actions/toolkit
  • Added proper MIT license attribution for the copied code
  • Updated all imports to use the internal implementation instead of the external package

Reviewed changes

Copilot reviewed 11 out of 12 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
pnpm-lock.yaml Removed @actions/github and all its transitive dependencies (@octokit/*, undici, etc.)
action-src/package.json Removed @actions/github from devDependencies
action-src/src/actions/github/context.ts New internal implementation of Context class copied from @actions/toolkit
action-src/src/actions/github/interfaces.ts New internal type definitions for webhook payloads copied from @actions/toolkit
action-src/src/actions/github/index.ts Export module for the internal github actions utilities
action-src/src/actions/github/README.md Documentation for the internal implementation (contains minor spelling issues)
action-src/src/actions/github/LICENSE.md MIT license attribution for the copied code
action-src/src/actions/github/context.test.ts Test suite for the Context class implementation
action-src/src/main.ts Updated import to use internal Context implementation
action-src/src/action.ts Updated import to use internal Context implementation
action-src/src/action.test.ts Updated import to use internal Context implementation and improved imports to use node: protocol
action/lib/main_root.cjs Compiled output reflecting the changes
Files not reviewed (1)
  • pnpm-lock.yaml: Language not supported

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Jason Dent <Jason3S@users.noreply.github.com>
@Jason3S Jason3S merged commit 8e0bc6f into main Jan 27, 2026
25 checks passed
@Jason3S Jason3S deleted the dev-github branch January 27, 2026 21:35
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