Skip to content

Allow specifiying custom skip label instead of hard-coded 'no-issue' #682

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 11, 2025

Conversation

gstokkink
Copy link
Contributor

@gstokkink gstokkink commented Jun 6, 2025

Will still default to 'no-issue' for backwards compatibility.

Copy link

github-actions bot commented Jun 6, 2025

No linked issues found. Please add the corresponding issues in the pull request description.
Use GitHub automation to close the issue when a PR is merged

@simoneb simoneb requested a review from Copilot June 11, 2025 13:45
Copy link

@Copilot 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 enables users to specify a custom skip label for linked issues checks instead of using the hard-coded "no-issue" label, while still defaulting to "no-issue" for backwards compatibility. Key changes include updating the util function to read a custom label from the action input, adjusting tests and mocks to reflect the new configuration, and modifying the action and README documentation accordingly.

Reviewed Changes

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

Show a summary per file
File Description
src/util.js Updated skip label check to use an input value but contains a variable naming shadow issue and possible input key mismatch.
src/action.test.js Updated test descriptions and mocks to align with the new custom skip label behavior.
action.yml Added a new input for the custom skip label, though its name may be inconsistent with util.js.
mocks/@actions/github.js Modified label assignment to use the new custom skip label from the context.
README.md Updated documentation to reflect the new skip label input and its behavior.
Comments suppressed due to low confidence (1)

src/util.js:152

  • The variable 'skipLinkedIssuesCheck' shadows the function name. Consider renaming it to 'skipLinkedIssuesCheckLabel' for clarity and to avoid potential confusion.
const skipLinkedIssuesCheck = core.getInput("skip-linked-issues-check-label");

@@ -31,12 +31,18 @@ inputs:
description: "A boolean value that allow PR to link issues on any branch"
required: false
default: "false"
skip-linked-issued-check-label:
Copy link
Preview

Copilot AI Jun 11, 2025

Choose a reason for hiding this comment

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

The input name in action.yml ('skip-linked-issued-check-label') does not match the key used in src/util.js ('skip-linked-issues-check-label'). Please standardize the naming across all files.

Suggested change
skip-linked-issued-check-label:
skip-linked-issues-check-label:

Copilot uses AI. Check for mistakes.

@simoneb simoneb merged commit b005bf5 into nearform-actions:main Jun 11, 2025
2 of 4 checks passed
@gstokkink gstokkink deleted the custom-label-support branch June 12, 2025 09:15
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