0
0
Gitdevops~10 mins

Code review in pull requests in Git - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the command to create a new pull request branch named 'feature' from 'main'.

Git
git checkout -b [1] main
Drag options to blanks, or click blank then click option'
Afeature
Bmain
Cdevelop
Drelease
Attempts:
3 left
💡 Hint
Common Mistakes
Using the base branch name instead of the new branch name.
2fill in blank
medium

Complete the command to push your local 'feature' branch to the remote repository.

Git
git push origin [1]
Drag options to blanks, or click blank then click option'
Adevelop
Bmain
Cfeature
Dmaster
Attempts:
3 left
💡 Hint
Common Mistakes
Pushing the wrong branch like 'main' or 'master'.
3fill in blank
hard

Fix the error in the command to fetch the latest changes from the remote repository.

Git
git [1] origin
Drag options to blanks, or click blank then click option'
Apull
Bfetch
Cclone
Dpush
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'push' or 'clone' which do different things.
4fill in blank
hard

Fill both blanks to create a pull request review comment on line 10 of 'app.py'.

Git
gh pr review [1] --comment --body "Looks good!" --line [2] --path app.py
Drag options to blanks, or click blank then click option'
A123
B10
C456
D20
Attempts:
3 left
💡 Hint
Common Mistakes
Mixing up PR number and line number.
5fill in blank
hard

Fill all three blanks to merge a pull request with ID 123 using the GitHub CLI with squash merge and a message.

Git
gh pr merge [1] --[2] --message "[3]"
Drag options to blanks, or click blank then click option'
A123
Bsquash
CAdd feature with squash merge
Drebase
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'rebase' instead of 'squash' for the merge method.