NEW
Font size
WorksheetsIntroduction to Git and Github
Total questions: 10
Worksheet time: 5mins
What is the command to initialize a Git repository in a directory?
git init
init git
git create
git start
What is the command to add files to the staging area in Git?
git push
git checkout
git commit
git add
What command is used to confirm changes in Git?
git commit
git checkout
git add
git push
What is the command to merge branches in Git?
git merge
git push
git branch
git commit
What is the purpose of a remote repository in GitHub?
Store and manage project versions collaboratively
Share memes with other users
Organize networking events for developers
Create a local backup of the project
How do you clone a remote repository in GitHub through the command line?
git clone
git commit
git add
git pull
What is the basic workflow in Git?
Open, copy, paste, save as
Clone, make changes, add, commit, push
Download, edit, delete, save
Create, move, rename, delete
What is the command to create a new branch in Git?
git checkout -b branch_name
git branch branch_name
git add branch_name
git commit -m branch_name
What command is used to view the commit history in Git?
git history
git status
git log
git show
What is the command to undo uncommitted changes in Git?
git reset --hard
git commit -m 'message'
git checkout -- .
git add .
