No student devices needed. Know more
40 questions
Which is Distributed version control system?
CSV
perforce
svn
Git
After you add a file, it becomes
Committed
Modified
Staged
Untracked
Which of the following is true you when you use the following command?
All new and updated files are staged
Files are staged in alphabetical order.
All new files are staged
Only updated files are staged
How do you supply a commit message to a commit?
Which two configuration properties does the tool expect to be configured after installing Git and prior to issuing the first commit?
email address and password
username and password
username and IP address
username and email address
What's a shortcut to staging all the changes you have?
git commit add .
git commit .
git add .
git stage -a
Which of the following commands is used in switching between branches?
git branch
git checkout
git switch
git merge
What is the area where uncommitted changes are temporarily held after adding?
Staging Area
Unstaging Area
Command to check the created, modified, deleted files in gitbash before Commit?
git show
git log
git status
all of the above
Which command should you use to initialize a new git repository?
git install
git bash
git init
git start
You can type git status at any point while in a git controlled directory to check the status of your files?
True
False
What command removes untracked files from your working directory.
git commit
git clean
git clean -f <path>
git reset
Which programming language was used to create Git?
C
HTML
PHP
C++
Which of the following commands will create a new branch?
git checkout new-branch
git checkout -b new-branch
git clone new-branch
git create-branch new-branch
Which of the following is one of Git's powerful features?
Rooting
Leafing
Branching
Planting
Command to add particular file changes to staging area from working directory?
git pull
git add .
git add file_name
git commit -m
To make a new git branch, the git command is?
git branch branch_name
git -b
git new branch_name
git checkout branch_name
Who is attributed with inventing Git?
Junio C. Hamano
James Gosling
Kohsuke Kawaguchi
Linus Torvalds
What do you call a system the records the project code's changes over time?
Repository System
Code Change System
Version Control System
none of the above
Which file can you configure to ensure that certain files are never committed to the local Git repository?
Ignore.git
.gitignore
gitignore.txt
git.ignore
What is the full form of GIT?
Gastro Intestional Track.
Global information Tracker
Gastro International Track.
None of these
We have just created a new file called “sum.java”. Which of the following will add this file so that we can commit it in git?
$ git add sum.java
$ git add new
$ git add -a sum.java
$ git git commit sum.java
Which of the following git command that downloads your repository from GitHub to your computer?
git fork
git commit
git clone
git push
How do you create a copy of a lab under your own GitHub account so that you can solve the lab?
Forking it via the GitHub interface.
git clone
git pull-request
git fork
What is the function of ‘GIT PUSH’ in GIT?
‘GIT PUSH’ updates remote refs.
‘GIT PUSH’ remote refs along with associated objects.
'GIT PUSH’ updates remote refs along with associated objects.
None of these
Which of these git client commands creates a copy of the repository?
clone
update
import
checkout
Which of the following commands used to show all parameters in git?
$ git config -a
$ git config --list
$ git config --all
$ git config --parameters --list
Which of the following commands used to undo a commit?
$ git reset <commit>
$ git revert <commit>
$ git reset --hard origin/master
$ git init
Which of the following commands used to permanently cancel a commit?
$ git reset <commit>
$ git revert <commit>
$ git reset --hard origin/master
$ git init
How to create a new branch and switch to it directly?
$ git checkout <branch-name>
$ git branch <branch-name>
$ git checkout -b <branch-name>
$ git branch -new <branch-name>
Which comes first _____?
$ git add
$ git commit
Which of the following commands used to return to the master branch?
$ git checkout origin
$ git checkout -b master
$ git checkout master
$ git checkout branche
.......... is equivalent to fetch and merge
pull
syncronize
push
fetch
What will the following command print to the Terminal? $git remote -v
A list of remote repositories you are connected to
The current git version you're running
An inline editor for modifying remote repositories
The last 5 git versions you've installed
Which command is useful for getting a high-level overview of the project history?
$git log --oneline
$git reset --hard
$git log --author="<pattern>"
$git rebase <base>
Which of the following commands will merge branch-a into the master branch?
git merge master and git checkout branch-a
git checkout branch-a and git merge master
git checkout master and git merge branch-a
git merge branch-a and git checkout master
Git commit command use to
push changes from local repo to central repo
stage changes
push changes from staging area to local rep
all of them
Which one of them is incorrect command
git add Test.txt
git pull origin master
git push origin master
None
How to do you delete a branch LOCALLY?
git branch -d <branch>
git delete <branch>
git branch -delete <branch>
None
How do you Delete a branch REMOTELY?
git push <remote> --d <branch>
git push <remote> --delete <branch>
git branch -d <branch>
None
Explore all questions with a free account