Wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Open Source WorkShop 001 Quiz_02

Total questions: 10

Worksheet time: 5mins

Name
Class
Date
1.
  1. Which command initializes a new Git repository in the current folder?

a)
  • git start

b)
  • git init

c)
  • git create

d)
  • git new

2.
  1. Which command shows the current state of your working directory and staging area?

a)
  • git show

b)
  • git status

c)
  • git check

d)
  • git inspect

3.
  1. Which command adds changes for a specific file to the staging area?

a)
  • git add filename

b)
  • git stage filename

c)
  • git include filename

d)
  • git push filename

4.
  1. How do you commit staged changes with a message?

a)
  • git save “message”

b)
  • git commit -m “message”

c)
  • git note “message”

d)
  • git log -m “message”

5.
  1. Which command clones a remote repository to your local machine?

a)
  • git copy   <url>

b)
  • git pull   <url>

c)
  • git clone   <url>

d)
  • git fetch   <url>

6.
  1. Which file tells Git which files or patterns to ignore?

a)

.gitconfig

b)

.gitignore

c)
  • ignore.txt

d)
  • gitignore.json

7.
  1. What does git push do?

a)
  • Downloads changes from remote to local

b)
  • Uploads local commits to a remote repository

c)
  • Stages files for commit

d)
  • Creates a new branch on local

8.
  1. Which command shows commit history?

a)
  • git history

b)
  • git log

c)
  • git commits

d)
  • git list

9.
  1. On GitHub, what is a “fork”?

a)
  • A way to delete a repository

b)
  • A copy of a repository under your account to work independently

c)
  • A feature to rename branches

d)
  • A command to stage changes

10.

What does git pull do?

a)
  • Uploads local commits to the remote repository

b)
  • Downloads and merges changes from the remote into your current branch

c)
  • Stages all files for commit

d)
  • Creates a new local repository