-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathlesson_1_reflections.txt
39 lines (25 loc) · 1.73 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
32
33
34
35
36
37
38
39
How did viewing a diff between two versions of a file help you see the bug that
was introduced?
use diff in unix/linux or fc in windows
How could having easy access to the entire history of a file make you a more
efficient programmer in the long term?
help you find bugs quickly.
What do you think are the pros and cons of manually choosing when to create a
commit, like you do in Git, vs having versions automatically saved, like Google
docs does?
Fill in your answer here
Why do you think some version control systems, like Git, allow saving multiple
files in one commit, while others, like Google Docs, treat each file separately?
因为Git是代码版本控制,同一功能可能需要多个文件才能实现,修改一个功能,可能
需要修改多个文件,因此允许再一次提交中保存多个文件。而Google Docs多是文档版本控制。
How can you use the commands git log and git diff to view the history of files?
git log --stat
git diff commitID1 commitID2
How might using version control make you more confident to make changes that
could break something?
可以使用git checkout commit_id轻松的回退到之前的版本
Now that you have your workspace set up, what do you want to try using Git for?
管理自己的代码
你认为,手动选择何时创建提交(像在 Git 中做的那样)与自动保存版本(如 Google Docs 所做的那样)各有何优缺点?
手动选择何时创建提交更灵活,可以更好的掌控提交的是否合适,是否提交过大或者过小,不过需要时刻记着手动提交。
自动保存版本可以自动提交,不会因为人为原因忘记提交。缺点是提交大小无法控制,可能过大或者过小。