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

Add match_word option to git blacklist task #804

Merged
merged 3 commits into from
Aug 24, 2020
Merged

Conversation

morloderex
Copy link
Contributor

@morloderex morloderex commented Aug 22, 2020

Added a match_word option to git blacklist.

Closes: #803

Q A
Branch master for features and deprecations
Bug fix? yes
New feature? yes
BC breaks? no
Deprecations? no
Documented? yes
Fixed tickets #803

So I figured my issue #803 out by myself, as it turns out git grep command has an option called word --word-regexp or -w for sorthand.

This has been taken from the Git scm documentation

Match the pattern only at word boundary 

(either begin at the beginning of a line, or preceded by a non-word character; end at the end of a line or followed by a non-word character).

I have added the possiblity to opt-in to this functionallity by using the new match_word option on the task. However I am fully open to changing this option on the task to something else. Some alternative naming conventions considered strict_keywords, match_keywords, match_using_boundary

All tests passes however let me know if I need to address anything before this can be merged I am new to contributing here.

Added a match_word option to git blacklist.

Closes: phpro#803
Signed-off-by: michael lundbøl <michael.lundboel@gmail.com>
@morloderex morloderex changed the title Add match_word option to git blacklist Add match_word option to git blacklist task Aug 22, 2020
Copy link
Contributor

@veewee veewee left a comment

Choose a reason for hiding this comment

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

Thanks for the PR, it looks good!
I've added 2 small remarks.

src/Task/Git/Blacklist.php Outdated Show resolved Hide resolved
doc/tasks/git_blacklist.md Outdated Show resolved Hide resolved
morloderex and others added 2 commits August 24, 2020 10:31
Update docs with suggested change

Co-authored-by: Toon Verwerft <toonverwerft@gmail.com>
@morloderex morloderex requested a review from veewee August 24, 2020 08:39
@veewee veewee added this to the 0.21.0 milestone Aug 24, 2020
@veewee veewee merged commit 8a99f81 into phpro:master Aug 24, 2020
@veewee
Copy link
Contributor

veewee commented Aug 24, 2020

Thanks for your work!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants