Skip to content

feat: adapt rule to identify caching via actions/setup-node#9

Merged
NicholasEllul merged 2 commits intomainfrom
ellul/rule-updates
Mar 14, 2025
Merged

feat: adapt rule to identify caching via actions/setup-node#9
NicholasEllul merged 2 commits intomainfrom
ellul/rule-updates

Conversation

@NicholasEllul
Copy link
Contributor

Summary

This pull request adapts our existing rule to be capable of flagging caching when performed through usage of actions/setup-node.

@NicholasEllul NicholasEllul requested a review from a team as a code owner March 7, 2025 22:07
@NicholasEllul NicholasEllul requested a review from Copilot March 7, 2025 22:07
Copy link

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.

PR Overview

This PR enhances our caching rule to also detect caching implemented via actions/setup-node.

  • Introduces a new pattern-either block in the rule YAML to identify both actions/cache and actions/setup-node usage.
  • Adds a new test case in the test YAML to validate the updated rule behavior.

Reviewed Changes

File Description
rules/src/github-actions/publish-actions-cache-used.yaml Updates the rule logic to detect caching when actions/setup-node is used.
rules/test/github-actions/publish-actions-cache-used.test.yaml Adds a test scenario to verify the updated caching detection rule.

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

Copy link

@al-sultani al-sultani left a comment

Choose a reason for hiding this comment

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

LGTM.

@NicholasEllul NicholasEllul merged commit 5a3355b into main Mar 14, 2025
1 check passed
@NicholasEllul NicholasEllul deleted the ellul/rule-updates branch March 14, 2025 14:11
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