-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathlesson_2_reflections.txt
56 lines (43 loc) · 2.09 KB
/
lesson_2_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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
1. What happens when you initialize a repository?
Why do you need to do it?
-A hidden .git folder is added to the directory. The
Folder contains the necessary files for Git to interact
with your repository. It gives you the functionality
of the version-control system.
2.How is the staging area different from the working
directory and the repository? What value do you think
it offers?
-The staging area is not permanent and allows you the
opportunity to choose which files will be relevant to
each commit. It also provides some safety by giving you
time to preview and second-check a commit before it is
made.
3. How can you use the staging area to make sure you have
one commit per logical change?
-I can use the staging area to prepare a commit before it
is made. By doing this, I give myself the chance to double
check that the changes I am about to make are appropriate
and logical.
4. What are some situations when branches would be helpful
in keeping your history organized? How would branches help?
-Branches should be used when you want to take your code in
a different directions, but also want to maintain the original
code. Examples might be experimental features, new layout, a
different language, etc.
5. How do the diagrams help you visualize the branch structure?
-It makes the organization and structure of your project much
easier to visualize. If you have a diagram to actually look at,
you can see each branch and each commit, and how they both fit
into the overall structure.
6. What is the result of merging two branches together? Why do
we represent it in the diagram the way we do?
-If one of your experimental branches ends up with the intended
behaviour, merging it with the master branch updates the code
and creates one branch where all the changes can be viewed on
one branch.
7. What are the pros and cons of Git’s automatic merging vs.
always doing merges manually?
-The con's are that merges will take a bit more time; however,
the pros are that by manually merging the branches there is much
more control going into the merge, and, therefore, it is far less
prone to mistakes.