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

lint: Add commit/PR body linter for epic and issue refs #87128

Merged
merged 1 commit into from
Oct 6, 2022
Merged

lint: Add commit/PR body linter for epic and issue refs #87128

merged 1 commit into from
Oct 6, 2022

Conversation

nickvigilante
Copy link
Contributor

@nickvigilante nickvigilante commented Aug 30, 2022

Before: Commits and PRs would inconsistently contain references to issues.
Sometimes the author would forget to add it. Some authors might not
think to add them. And there were no epic references provided.

Why: Adding issue and epic references to PRs and commits provides
traceability and context for the revenue teams, product, management and
engineers.

Now: A new GitHub Action workflow checks for references to issues the PR
closes or informs and epics the PR is part of. It looks for references
in the PR body and in commit messages and, if it doesn't find what it
expects, it fails the check.

This PR is a continuation of #77654.

Fixes #77376

Release note: None

Release justification: Adding linter for better epic tracking

@nickvigilante nickvigilante requested a review from a team as a code owner August 30, 2022 17:20
@cockroach-teamcity
Copy link
Member

This change is Reviewable

@nickvigilante nickvigilante requested a review from jlinder August 30, 2022 19:50
@nickvigilante
Copy link
Contributor Author

nickvigilante commented Aug 30, 2022

@jlinder This is ready for final review. My last Bazel run reached the 90 minute timeout, but I hope this one will succeed.

Copy link
Collaborator

@jlinder jlinder left a comment

Choose a reason for hiding this comment

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

Had one suggestion. Good either way!

pkg/cmd/lint-epic-issue-refs/lint_epic_issue_refs.go Outdated Show resolved Hide resolved
Before: Commits and PRs would inconsistently contain references to issues.
Sometimes the author would forget to add it. Some authors might not
think to add them. And there were no epic references provided.

Why: Adding issue and epic references to PRs and commits provides
traceability and context for the revenue teams, product, management and
engineers.

Now: A new GitHub Action workflow checks for references to issues the PR
closes or informs and epics the PR is part of. It looks for references
in the PR body and in commit messages and, if it doesn't find what it
expects, it fails the check.

Release note: None

Release justification: Adding linter for epic tracking for engineering,
docs, and internal teams.
@nickvigilante
Copy link
Contributor Author

bors r+

@craig
Copy link
Contributor

craig bot commented Oct 6, 2022

Build succeeded:

@craig craig bot merged commit bfbd07b into cockroachdb:master Oct 6, 2022
@nickvigilante nickvigilante deleted the pr-commit-lint branch October 10, 2022 17:41
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.

linter: Add PR check to encourage including issue or epic refs in the PR/commit messages
3 participants