-
Notifications
You must be signed in to change notification settings - Fork 23
/
Copy pathlesson_1_reflections.txt
31 lines (25 loc) · 1.4 KB
/
lesson_1_reflections.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
Viewing a diff between two files helps indentifying areas where a new bug may
have been introduced. So check those locations first when things are "suddenly"
broken.
Other notes:
Use git-bash to get linux style command prompt
on windows you have program called FC. Can be runned from commandline:
>> FC file-old.js file-new.js
Reflect: Manual Commits
By committing manually instead of automaticall, you can decide what to commit and when.
This gives the opportunity to split the commits based on functionality.
By committing manually you can specify commit messages describing what has changed, instead of only showing an auto commit.
Reflect: Multi-File commits
Multi-file commits are usefull when files are related to eachother.
"Normal" documents seldom have relations, so those are not needed. In sourcecode, files will have lots of relations.
So having multi-file commits is an essential feature.
Reflect: what do you want to try using Git for?
Source code for a simple website/game
Commands:
q | exit git log!
git log | List the commits and show which files have changed
git log --stat | Show addition information about the commits
git diff id1 id2 | Compare two commits
git clone | Create a local copy/clone from the repository
git config --global color.ui auto | get colored diff output
git checkout | Shows a previous version of the file. This is not a checkout to edit like in SVN or TFS!