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

In discussions, always link the "Closed" label to the closing event #2012

Merged
merged 3 commits into from May 11, 2019

Conversation

Projects
None yet
2 participants
@loilo
Copy link
Contributor

commented May 6, 2019

Recap: Besides linking to a concrete PR/commit, the extend-status-labels feature also puts an anchor to the closing note on the status label (which I find really handy since the most valuable/helpful comments are often right before the closing note).

However, those anchors are currently not set when an issue was not closed by a PR/commit (e.g. #2005).

This PR changes that behavior by not bailing out prematurely when no commit/PR was found. Instead it always puts the anchor to the closing note and adds the in #xxxx label + link if needed.

@bfred-it bfred-it closed this May 6, 2019

@bfred-it bfred-it reopened this May 6, 2019

@bfred-it
Copy link
Collaborator

left a comment

I don't think I ever used the link, but I like the idea!

Show resolved Hide resolved source/features/extend-status-labels.tsx Outdated
Show resolved Hide resolved source/features/extend-status-labels.tsx Outdated
Show resolved Hide resolved source/features/extend-status-labels.tsx
Show resolved Hide resolved source/features/extend-status-labels.tsx Outdated

bfred-it and others added some commits May 6, 2019

Use .matches() instead of .closest() for efficiency
Co-Authored-By: Loilo <Florian.Reuschel@gmx.de>

@bfred-it bfred-it added the enhancement label May 6, 2019

@loilo

This comment has been minimized.

Copy link
Contributor Author

commented May 7, 2019

The reviewed points have all been resolved, so feel free to look at the code again. 🙂

@bfred-it bfred-it changed the title Improve consistency of status links In discussions, always link the "Closed" label to the closing event May 11, 2019

@bfred-it bfred-it merged commit 89b8256 into sindresorhus:master May 11, 2019

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
@bfred-it

This comment has been minimized.

Copy link
Collaborator

commented May 11, 2019

Thanks @loilo! 🙋‍♂️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.