World map

 

BM: Baca dalam Bahasa Melayu

World 5: Teamwork

Link PRs to issues

You will learn: how "Closes #12" makes an issue close by itself when a PR merges.

The problem

Mei’s events page was merged last week. But issue #9 is still open! Someone must close it by hand. Do it now.

Practice repo — not a real website
kelab-kod / club-site
Add a club events page #9
Open #9 opened by aina
Labels
enhancement
  1. aina

    List our next events with dates.

  2. aina commented

    The events page is live. Is this issue done?

Watch

A closing keyword: Words like Closes #9 in a pull request. When it merges into the default branch, issue 9 closes. goes in the PR description. When the PR merges into main, the issue closes by itself. Tap the magic line.

Tap the line that will close an issue.

0 of 1 found

Predict

Ravi’s PR says “Fixes #20”. It merges into a branch called test, not main. What happens to issue #20?

Pick one answer.

Check

Will this line close issue #9 on merge? Swipe right for yes, left for no.

Swipe right for good, left for needs work. Or use the buttons.

1 / 4Fixes #9
Fixes #9

Try it

Time to merge your gallery PR. Then peek at the Issues tab.

Practice repo — not a real website
kelab-kod / club-site
Add a photo gallery #18
Open you wants to merge gallery into main
  1. you

    Adds a gallery page with 6 photos.

    Closes #16

  2. Mei approved these changes

    Love the photos!

Checks
  • Passed test
Merging this closes #16.
How to merge
Ready to merge.
Your review

You did it!

You can now link a PR to an issue, so it closes by itself.

Go deeper (optional)

All nine keywords: close, closes, closed, fix, fixes, fixed, resolve, resolves, resolved. For an issue in another repo, write Fixes owner/repo#100. For several issues, repeat the keyword: Closes #10, closes #11. A keyword in a commit message works too, once it reaches the default branch.