Skip to content
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

feat: add configuration to exclude author from mentions #22

Merged
merged 3 commits into from
Oct 22, 2024

Conversation

wschurman
Copy link
Contributor

@wschurman wschurman commented Oct 18, 2024

Why

Some members of the expo/expo repo have expressed interest in excluding the author of the PR from the mentions. This PR adds the ability to conditionally configure this behavior.

How

Add excludeAuthor as a top-level configuration option to the configuration yaml. Filter the matched rules if set.

Note that this PR also runs the format script so some incorrectly-formatted code from previous PRs is corrected.

Test Plan

Run test.

Tried to test in expo#5 but I believe 6bf157a makes fork workflows run with the tobyhs/codemention@main. I guess I could override for the fork, but I think the test provides enough confidence for this.

Copy link

CodeMention:

File Patterns Mentions
** @tobyhs

Copy link
Owner

@tobyhs tobyhs left a comment

Choose a reason for hiding this comment

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

lgtm, although I'm also fine with not having an excludeAuthor option and just unconditionally excluding the author from mentions. Let me know if this is preferable and you want to update this PR for that approach, or if you want to stick with the current approach.

I'll update the build-test GitHub workflow to run npm run format-check later to catch format/prettier issues in the future.

@wschurman
Copy link
Contributor Author

Thinking about it more, yep, I think it makes sense for this to be the behavior. I'll update the PR early next week.

@wschurman wschurman requested a review from tobyhs October 21, 2024 23:35
Copy link
Owner

@tobyhs tobyhs left a comment

Choose a reason for hiding this comment

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

lgtm

@tobyhs tobyhs merged commit 0da2e1c into tobyhs:main Oct 22, 2024
4 checks passed
tobyhs added a commit to tobyhs/codemention-test that referenced this pull request Oct 22, 2024
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