BM: Baca dalam Bahasa Melayu
World 5: Teamwork
Pull requests and drafts
You will learn: how to offer your change with a pull request, and when to use a draft.
The problem
Your fix is ready on your own branch. But main belongs to the whole club. How do you get your change in, politely?
Pick one answer.
Try it
A pull request (PR): Ask others to review and accept your changes. (PR) says: please pull my branch into main. The team reads it, talks, then merges. Answer Mei’s question.
- Yyou
The button pointed to a missing page. Now it opens signup.html.
- mei
Nice! Did you test it on a phone?
- Passed test
- This branch needs one approving review first.
Hint
Type a short answer, like “Yes, it works on my phone!”, then press Comment.Try it
A PR has two main tabs. Where do you find each thing?
Drag a card into a box. Or tap the card, then tap the box.
Predict
Your work is half done. You open it as a draft pull request: A pull request marked as not finished. Nobody can merge it until it is ready for review.. Can anyone merge it now?
Pick one answer.
Try it
Your draft is finished now. Aina already approved it. Mark it ready for review, then merge it.
- you
Adds a footer with our meeting time.
- Aina approved these changes
Looks good! Ship it when it is done.
- Passed test
- This is still a draft. Mark it ready for review first.
Hint
First press “Ready for review”. Then press “Merge pull request”.Check
Put a pull request’s life in order. First at the top.
First step at the top. Put these in order. Use the arrows, or drag.
- Merge it into main
- Commit on your own branch
- Push the branch to GitHub
- Open a pull request
- Teammates review it
You did it!
You can now open a pull request, and use a draft for unfinished work.
Go deeper (optional)
You can turn a PR back into a draft at any time. Drafts do not ask code owners to review. Marking one ready does. You can open PRs on the website, from your editor, or with gh pr create (World 9). A pull request template fills in the description for you.
Bahasa Melayu
Pembaikan anda dah siap dalam branch (cabang) anda sendiri. Tapi main milik seluruh kelab. Macam mana nak masukkan perubahan anda dengan sopan?
Pull request (PR) bermaksud: tolong tarik branch saya ke dalam main. Pasukan baca, berbincang, kemudian merge (cantum). Jawab soalan Mei.
PR ada dua tab utama. Di mana anda jumpa setiap benda?
Kerja anda baru separuh siap. Anda buka sebagai draf pull request. Bolehkah sesiapa merge sekarang?
Draf anda dah siap sekarang. Aina dah luluskannya. Tanda sedia untuk review, kemudian merge.
Susun perjalanan sebuah pull request. Yang pertama di atas.
Kini anda boleh buka pull request, dan guna draf untuk kerja belum siap.
You finished this before. Practice is always welcome!
Official docs: About pull requests · Creating a pull request · Changing the stage of a pull request
You've learned for 25 minutes. A short break helps your brain.
Sprint done! Great focus. Stretch for a minute?