Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Style: mark 'file.txt' as code #181

Merged
merged 1 commit into from
May 31, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions basic-staging/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,16 @@ We will also work with `git reset` to reset the staged changes of a file, and `g

## The task

You live in your own repository. There is a file called file.txt
You live in your own repository. There is a file called `file.txt`.

1. What's the content of file.txt?
1. Overwrite the content in file.txt: `echo 2 > file.txt` to change the state of your file in the working directory (or `sc file.txt '2'` in PowerShell)
1. What's the content of `file.txt`?
1. Overwrite the content in `file.txt`: `echo 2 > file.txt` to change the state of your file in the working directory (or `sc file.txt '2'` in PowerShell)
1. What does `git diff` tell you?
1. What does `git diff --staged` tell you? why is this blank?
1. Run `git add file.txt` to stage your changes from the working directory.
1. What does `git diff` tell you?
1. What does `git diff --staged` tell you?
1. Overwrite the content in file.txt: `echo 3 > file.txt` to change the state of your file in the working directory (or `sc file.txt '3'` in PowerShell).
1. Overwrite the content in `file.txt`: `echo 3 > file.txt` to change the state of your file in the working directory (or `sc file.txt '3'` in PowerShell).
1. What does `git diff` tell you?
1. What does `git diff --staged` tell you?
1. Explain what is happening
Expand All @@ -36,11 +36,11 @@ You live in your own repository. There is a file called file.txt
1. What does git status tell you now?
1. Stage the change and make a commit
1. What does the log look like?
1. Overwrite the content in file.txt: `echo 4 > file.txt` (or `sc file.txt '4'` in PowerShell)
1. What is the content of file.txt?
1. Overwrite the content in `file.txt`: `echo 4 > file.txt` (or `sc file.txt '4'` in PowerShell)
1. What is the content of `file.txt`?
1. What does `git status` tell us?
1. Run `git checkout file.txt`
1. What is the content of file.txt?
1. What is the content of `file.txt`?
1. What does `git status` tell us?


Expand Down