Don't run npm install when in an Actions workflow by mbg · Pull Request #3155 · github/codeql-action (original) (raw)
Navigation Menu
Provide feedback
Saved searches
Use saved searches to filter your results more quickly
Appearance settings
Merged
merged 2 commits into
Sep 25, 2025
Conversation
Follow-up to #3154 to skip running npm install when running in a GitHub Actions workflow.
Risk assessment
For internal use only. Please select the risk level of this change:
- Low risk: Changes are fully under feature flags, or have been fully tested and validated in pre-production environments and are highly observable, or are documentation or test only.
Merge / deployment checklist
- Confirm this change is backwards compatible with existing workflows.
- Consider adding a changelog entry for this change.
- Confirm the readme and docs have been updated if necessary.
Copilot AI review requested due to automatic review settings
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This change modifies the check-node-modules.sh script to skip running npm install when executing in a GitHub Actions workflow environment, addressing potential issues with dependency installation in CI environments.
- Adds a check for the
GITHUB_ACTIONSenvironment variable to exit early when running in CI - Improves logging to provide clear feedback about npm install decisions
- Maintains existing logic for local development environments
mbg mentioned this pull request
mbg deleted the mbg/node/no-install-in-actions branch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
[ Show hidden characters]({{ revealButtonHref }})