0
1
00:00:00,450 --> 00:00:00,740
All right.
1

2
00:00:00,750 --> 00:00:05,450
So we've been doing a lot of stuff in the command line and it's great practice,
2

3
00:00:05,490 --> 00:00:08,690
and also a lot of developers prefer it.
3

4
00:00:08,940 --> 00:00:15,150
But in the new Xcode 9, there's actually a couple of changes that are made in terms of how Git version
4

5
00:00:15,150 --> 00:00:16,730
control is implemented,
5

6
00:00:16,890 --> 00:00:20,060
and I have to say it's a lot better than previous versions,
6

7
00:00:20,250 --> 00:00:25,800
almost to the point that I'm tempted to use this instead of using the command line. But, of course, you can
7

8
00:00:25,800 --> 00:00:27,470
choose whichever one you prefer,
8

9
00:00:27,660 --> 00:00:32,700
and that's why I'm going to show you how you can do everything that we've just done using Xcode itself
9

10
00:00:33,120 --> 00:00:35,860
without having to ever touch the command line.
10

11
00:00:35,880 --> 00:00:41,640
So let's go ahead and create a Xcode project and it's going to be a single view iOS application.
11

12
00:00:41,790 --> 00:00:48,900
And I'm going to call it Udder which is like an alternative to Uber. But here's my pitch: what if you
12

13
00:00:48,900 --> 00:00:52,610
could get fresh milk on demand through the other app?
13

14
00:00:52,800 --> 00:00:53,180
Okay.
14

15
00:00:53,250 --> 00:00:55,540
Let me know in the Q and A what you think about this.
15

16
00:00:55,740 --> 00:01:00,230
But anyways, let's go ahead with our example. I"m going to go ahead and click next.
16

17
00:01:00,540 --> 00:01:07,200
And it's really important that previously, we've not really cared much about this. But given that we're
17

18
00:01:07,200 --> 00:01:14,010
talking about source control and version control, we need to create a git repository on my Mac using
18

19
00:01:14,040 --> 00:01:19,170
Xcode. And this is the equivalent of using "git init" in our Terminal.
19

20
00:01:19,590 --> 00:01:23,610
So I'm going to save it on my desktop and just make sure that you've got that checked.
20

21
00:01:23,610 --> 00:01:25,370
Go ahead and click Create.
21

22
00:01:25,620 --> 00:01:28,730
And here's our brand-new project.
22

23
00:01:28,860 --> 00:01:30,860
Now, I'm going to do a couple of things first,
23

24
00:01:30,900 --> 00:01:40,500
going to maybe add a UILabel to the top of my file, and I'm going to call my app Udder, as I already
24

25
00:01:40,500 --> 00:01:51,510
pitched here. And I'm going to change the size of it to size 40, make it maybe a dark gray color.
25

26
00:01:52,170 --> 00:01:56,840
And let's just make that resized to the right size.
26

27
00:01:57,090 --> 00:02:04,890
And let's give it a tagline, why not "Fresh Milk, On Demand.
27

28
00:02:04,950 --> 00:02:07,040
That sounds pretty good, right?
28

29
00:02:07,040 --> 00:02:07,760
Sounds like a start
29

30
00:02:07,760 --> 00:02:08,790
already.
30

31
00:02:09,350 --> 00:02:09,640
All right.
31

32
00:02:09,650 --> 00:02:13,760
So now that I've done that, the other thing I want to do is add some image assets.
32

33
00:02:13,760 --> 00:02:19,910
So I've got two images, one of milk and one of cow, which is all going to be very relevant in this particular
33

34
00:02:20,000 --> 00:02:21,360
app.
34

35
00:02:21,380 --> 00:02:26,890
So, now I am ready to go ahead and make my second commit.
35

36
00:02:26,900 --> 00:02:34,010
So the first commit is on initializing the project and you can take a look at where the commits are by going
36

37
00:02:34,010 --> 00:02:37,290
to this brand-new source control navigator.
37

38
00:02:37,310 --> 00:02:44,300
So if you head over there and you expand these folders, then you can see that we've got a other master,
38

39
00:02:44,600 --> 00:02:49,390
and we got an initial commit that was made when our project was created.
39

40
00:02:49,400 --> 00:02:53,130
So let's go ahead and commit our latest changes.
40

41
00:02:53,390 --> 00:03:00,290
So to do that, we simply go to source control and hit commit, or use the option command, see shortcut if
41

42
00:03:00,290 --> 00:03:01,560
you wish.
42

43
00:03:01,580 --> 00:03:06,930
Now, in the left-hand pane here, you can see some of those changes that were made.
43

44
00:03:06,980 --> 00:03:09,800
So we added these two new images.
44

45
00:03:09,800 --> 00:03:14,900
We changed our Main.storyboard, of course, this is all in XML. And you can see that this is showing what
45

46
00:03:14,900 --> 00:03:16,410
the differences are.
46

47
00:03:16,580 --> 00:03:21,560
So, for example, I added a brand-new label, which previously didn't exist,
47

48
00:03:21,710 --> 00:03:24,460
and also I added a UI Image View.
48

49
00:03:24,560 --> 00:03:32,990
So I'm ready to commit those changes, so I have to enter a commit message here, and label "Add label and
49

50
00:03:33,110 --> 00:03:40,970
images." And we're going to go ahead and commit those seven files to our local repository.
50

51
00:03:41,270 --> 00:03:47,330
So, now if you have a look at our master branch, you can see that we have two commits that are made.
51

52
00:03:47,330 --> 00:03:52,820
All right. So, now that that commits were made, let's say we go into our Main.storyboard and we kind of
52

53
00:03:52,820 --> 00:03:54,950
just mess everything up.
53

54
00:03:55,160 --> 00:04:02,660
Let's just try and mess up our interface and make it something pretty terrible, and let's delete all
54

55
00:04:02,660 --> 00:04:04,280
the useful parts.
55

56
00:04:04,400 --> 00:04:06,400
And now it's pretty much a mess.
56

57
00:04:06,530 --> 00:04:11,420
And our view controller, let's add some mumbo-jumbo which is not code.
57

58
00:04:11,660 --> 00:04:15,570
And let's say, we accidentally even deleted our Main.story board.
58

59
00:04:15,620 --> 00:04:17,720
Let's just move it to trash, shall we?
59

60
00:04:17,720 --> 00:04:19,920
Now we've made some pretty big issues.
60

61
00:04:19,940 --> 00:04:21,020
Let's delete
61

62
00:04:21,110 --> 00:04:23,420
ViewControllers as well. This is a really common bug,
62

63
00:04:23,420 --> 00:04:29,360
by the way, that a lot of students in our in-person programming boot camp get themselves into which is
63

64
00:04:29,360 --> 00:04:32,740
when you think that you've got something selected over here,
64

65
00:04:32,750 --> 00:04:35,890
but actually you've still got the file selected.
65

66
00:04:36,050 --> 00:04:40,800
And if you hit backspace, it'll actually try to move your file to the trash.
66

67
00:04:40,910 --> 00:04:43,360
So we've made a mess of things, basically.
67

68
00:04:43,370 --> 00:04:47,790
So, of course, you can drag them out of trash, because we just place them in the trash,
68

69
00:04:47,840 --> 00:04:51,350
but let's say that we just mess everything up irreversibly.
69

70
00:04:51,350 --> 00:04:59,510
But what we can do is because we have that last good commit, we can simply go to source control and discard
70

71
00:04:59,660 --> 00:05:00,920
all changes.
71

72
00:05:00,920 --> 00:05:07,370
So this will discard all the changes that we made since the last commit inside our working copy.
72

73
00:05:07,370 --> 00:05:17,030
So if I hit this button, you can see that little bit of work is done behind the scenes. And, ta-da!
73

74
00:05:17,090 --> 00:05:24,020
All of our beautiful work is restored to that last checkpoint and we will no longer get fired from our jobs,
74

75
00:05:24,140 --> 00:05:30,970
and there are countless stories of Git and source control saving people's lives at work every day.
75

76
00:05:30,980 --> 00:05:33,140
So that was pretty cool.
76

77
00:05:33,140 --> 00:05:34,730
Now, what about another feature of Git?
77

78
00:05:34,730 --> 00:05:36,150
What about branching?
78

79
00:05:36,350 --> 00:05:38,200
Well, it's equally easy to do.
79

80
00:05:38,240 --> 00:05:45,800
So if we head into the master branch and we decide to make a branch at this point, and we can simply
80

81
00:05:45,800 --> 00:05:52,760
just right click and say , "Branch from..." this particular hash or this particular point, and we can give our
81

82
00:05:52,760 --> 00:06:01,330
branch a name, and I'm going to call this the milk-design and it will all become clear very quickly.
82

83
00:06:01,340 --> 00:06:07,940
So, now I have the milk design. But it's important to note that current or the branch that we're currently
83

84
00:06:07,940 --> 00:06:09,830
on is still the master branch.
84

85
00:06:09,830 --> 00:06:15,990
So I have to also checkout to switch to the milk-design branch.
85

86
00:06:16,310 --> 00:06:17,690
So let's go ahead and do that.
86

87
00:06:17,690 --> 00:06:23,030
So we're now on the milk design-branch and I'm going to go into the Main.storyboard and I'm going to
87

88
00:06:23,030 --> 00:06:32,970
put a image view onto the screen. And I'm going to place the milk image I've got in my Assets folder
88

89
00:06:33,480 --> 00:06:34,230
on here.
89

90
00:06:34,330 --> 00:06:34,770
Okay.
90

91
00:06:34,770 --> 00:06:35,720
Looks pretty good.
91

92
00:06:35,790 --> 00:06:36,210
Okay.
92

93
00:06:36,210 --> 00:06:38,880
So that's my milk branch done.
93

94
00:06:38,910 --> 00:06:44,970
And I'm going to save my Main.storyboard and I'm going to commit my changes.
94

95
00:06:44,970 --> 00:06:54,210
So let's say we change interface, change view controller interface.
95

96
00:06:54,540 --> 00:06:58,450
And these are obviously the changes in XML that I have just made.
96

97
00:06:58,620 --> 00:07:03,000
So I added that image view and that includes that milk resource.
97

98
00:07:03,000 --> 00:07:06,660
So let's go ahead and commit that file.
98

99
00:07:06,660 --> 00:07:14,580
So, now let's head back to the source control navigator and let's have a look at our milk-design branch.
99

100
00:07:14,700 --> 00:07:20,930
So you can see that the latest commit is in action, "Change view control interface."
100

101
00:07:20,940 --> 00:07:28,050
Now, I'm going to create another branch. So I'm going to branch from the latest checkpoint inside master,
101

102
00:07:28,070 --> 00:07:29,890
so we're going to branch from here again.
102

103
00:07:30,020 --> 00:07:32,410
I'm going to call this a cow-design.
103

104
00:07:32,720 --> 00:07:39,660
So just bear with me, bear with me here. And I'm going to check out to switch over to the cow design branch.
104

105
00:07:39,830 --> 00:07:45,950
And now I'm going to go to my Main.storyboard. And remember, because we're currently at the last checkpoint
105

106
00:07:46,010 --> 00:07:49,130
on the main branch, we haven't actually got an image view yet.
106

107
00:07:49,130 --> 00:07:54,520
That's only inside the commit for the milk-design branch.
107

108
00:07:54,620 --> 00:08:00,710
So here, I'm going to put another image view, and you guessed it, I'm going to put the cow-image that I've
108

109
00:08:00,710 --> 00:08:02,370
got in here.
109

110
00:08:04,030 --> 00:08:08,920
So, now I have got a cow design and also a milk design.
110

111
00:08:08,950 --> 00:08:14,830
So, now I'm going to save my Main.storyboard. I'm going to go to source control and hit commit. A nd I'm
111

112
00:08:14,830 --> 00:08:22,280
going to say, "Change interface to incorporate cow image."
112

113
00:08:22,540 --> 00:08:29,080
Now, you always want to be precise when you are writing your commit messages because if somebody else
113

114
00:08:29,080 --> 00:08:38,200
is coming across this and each of your commits are just changes, changes, changes, then that really doesn't
114

115
00:08:38,200 --> 00:08:39,130
help anybody.
115

116
00:08:39,130 --> 00:08:44,650
And I've actually seen this before, but this is bad practice, and this would probably get you fired if
116

117
00:08:44,650 --> 00:08:47,540
you're working in a very Git intensive team.
117

118
00:08:47,590 --> 00:08:55,840
So let's go ahead and commit this file and go back to our source control navigator and check out our
118

119
00:08:56,170 --> 00:08:57,070
cow-design.
119

120
00:08:57,170 --> 00:09:03,970
Okay, so we've got the cow images and we've got the milk design. And you know what, I think that I'd prefer 
120

121
00:09:03,970 --> 00:09:04,750
the milk-design.
121

122
00:09:04,750 --> 00:09:11,690
So I am going to merge my milk-design into my master and that is going to become my master branch.
122

123
00:09:11,740 --> 00:09:15,700
So all I have to do is right-click on milk design and I'm going to click
123

124
00:09:15,700 --> 00:09:17,650
Checkout.
124

125
00:09:17,780 --> 00:09:26,800
And now I can right-click on master and say, "Merge 'milk-design' into 'master.'" So milk-design is my current branch
125

126
00:09:26,810 --> 00:09:30,800
that I'm currently on and I'm going to merge into my master branch.
126

127
00:09:30,860 --> 00:09:37,760
So go ahead and click Merge.
127

128
00:09:37,910 --> 00:09:43,080
Now once it's done that you're going to be reverted back to the master branch because it's now merged.
128

129
00:09:43,280 --> 00:09:49,550
And if you have a look inside your Main.storyboard, you can see the milk-design is now the accepted design
129

130
00:09:49,850 --> 00:09:51,400
on our master branch.
130

131
00:09:51,620 --> 00:09:52,070
All right.
131

132
00:09:52,070 --> 00:09:54,440
So that was all very easy.
132

133
00:09:54,470 --> 00:10:00,140
Now, another thing that you can do is what if you wanted to have a look back at what milk-design looked like
133

134
00:10:00,140 --> 00:10:06,590
or at the code that you made in another branch or, you know, way, way back in a random or different
134

135
00:10:06,590 --> 00:10:07,490
commit.
135

136
00:10:07,490 --> 00:10:14,030
well, say, if at the moment, we're currently at this point on the master branch, if I want to have a look
136

137
00:10:14,030 --> 00:10:21,080
at what, you know, this checkpoint was like, then I can simply right click and say, "Checkout this particular
137

138
00:10:21,080 --> 00:10:21,830
commit."
138

139
00:10:22,040 --> 00:10:27,680
So if we check that out and we go back to our Main.storyboard, you can see that everything is reverted
139

140
00:10:27,980 --> 00:10:30,840
to that checkpoint or that commit.
140

141
00:10:30,860 --> 00:10:37,670
Now, this can be really invaluable for your code files because sometimes, you know, way, way back at some,
141

142
00:10:37,940 --> 00:10:42,380
you know, three months ago, you might have created some sort of feature that you thought was a little
142

143
00:10:42,380 --> 00:10:48,800
bit crappy, but now you've decided that it's actually a great idea. So you can have a look at what each
143

144
00:10:48,800 --> 00:10:53,620
and every commit looks like by simply checking out the commit.
144

145
00:10:53,630 --> 00:11:01,010
So let's go back to master and check out the main master branch and head back to where we are meant
145

146
00:11:01,010 --> 00:11:01,480
to be.
146

147
00:11:01,520 --> 00:11:06,950
So when you check out one of the earlier commits, you can use it to compare the differences.
147

148
00:11:06,950 --> 00:11:13,130
So currently, we're on the master branch and, let's say, that, you know, type some code in here, let's
148

149
00:11:13,130 --> 00:11:18,380
just add, I don't know, maybe viewWillAppear and a comment.
149

150
00:11:18,380 --> 00:11:19,970
So let's go ahead and save that.
150

151
00:11:19,970 --> 00:11:29,830
So this is our master branch and Commit, "And view will appear," and we're going to commit that file.
151

152
00:11:29,820 --> 00:11:35,250
And you can see that this is the difference between this commit and the previous commit in terms of the code.
152

153
00:11:35,250 --> 00:11:37,340
This is the addition.
153

154
00:11:37,660 --> 00:11:45,250
So let's go ahead and commit that file. And then if we head over to one of our milk-design, let's say
154

155
00:11:45,270 --> 00:11:46,260
checkout,
155

156
00:11:46,510 --> 00:11:50,970
and in the view controller, you can see that it doesn't have the viewDidLoad.
156

157
00:11:50,980 --> 00:11:55,860
But here, we're going to delete that didReceiveMemoryWarning block of code.
157

158
00:11:55,930 --> 00:12:00,630
I'm going to save and I'm going to commit, and I'm going to say, "Delete
158

159
00:12:03,760 --> 00:12:07,730
memory warning code."
159

160
00:12:08,050 --> 00:12:11,210
Okay. So, now you can see that this is the latest commit.
160

161
00:12:11,230 --> 00:12:15,610
This is the previous version and we are removing this block of code.
161

162
00:12:15,670 --> 00:12:17,970
So let's commit that one file.
162

163
00:12:17,980 --> 00:12:25,960
So, now what I'm gonna do is if I go into this particular button, which is the version editor, I can compare
163

164
00:12:26,020 --> 00:12:28,340
and contrast my code files.
164

165
00:12:28,390 --> 00:12:36,310
So on the left, I've got my master branch latest version which has the viewWillAppear and the 
165

166
00:12:36,310 --> 00:12:37,300
didReceiveMemoryWarning.
166

167
00:12:37,540 --> 00:12:45,220
Now, on the right, let's say that I've got my milk-design latest version, so you can see that the version
167

168
00:12:45,220 --> 00:12:51,580
editor actually highlights the differences between the two code files that you're comparing.
168

169
00:12:51,580 --> 00:12:57,670
So you can compare different commits against each other, either from different branches or on the same
169

170
00:12:57,670 --> 00:12:58,050
branch,
170

171
00:12:58,060 --> 00:13:03,730
but, you know, way, way back historically, and you can check out what are the code changes that you've made
171

172
00:13:04,060 --> 00:13:06,470
and see what the previous code look like.
172

173
00:13:06,580 --> 00:13:11,230
And this is really invaluable when you screw up or when you mess up your code because you can always
173

174
00:13:11,230 --> 00:13:15,790
compare and put things over if you realize that you actually do need this.
174

175
00:13:15,790 --> 00:13:23,080
So the last thing that I want to show you in terms of using Xcode for source control is using remotes,
175

176
00:13:23,650 --> 00:13:26,710
and namely, and namely GitHub.
176

177
00:13:26,800 --> 00:13:34,690
So Xcode has integrated really neat feature where you can actually push your project using Xcode to
177

178
00:13:34,690 --> 00:13:36,070
your GitHub remote.
178

179
00:13:36,130 --> 00:13:40,130
So the first thing you have to do is go into Xcode and go to preferences.
179

180
00:13:40,300 --> 00:13:46,010
And if you go to accounts, you can click add an account, and instead of picking Apple ID, you're going
180

181
00:13:46,010 --> 00:13:47,710
to pick GitHub.
181

182
00:13:47,740 --> 00:13:53,650
So continue, and then you're going to log in using your GitHub account. And once you've done that,
182

183
00:14:01,170 --> 00:14:06,140
and, of course, you need to be internet-enabled for this check to pass because they're going to log you
183

184
00:14:06,180 --> 00:14:11,760
in remotely to GitHub and they're going to grab your SSH keys and everything that you need to be
184

185
00:14:11,760 --> 00:14:15,390
able to create a remote and push to your remotes.
185

186
00:14:15,420 --> 00:14:17,860
So once you are done with that, you can close that down.
186

187
00:14:17,860 --> 00:14:23,160
And now if we go into the source control navigator, we can head back to master.
187

188
00:14:23,160 --> 00:14:29,490
So let's checkout master. And from here, I'm going to create a new remote and I'm going to push my project
188

189
00:14:29,790 --> 00:14:30,930
to GitHub.
189

190
00:14:31,050 --> 00:14:39,570
So if you click on your main repository and you right-click, you can "Create "Udder" Remote on GitHub,"
190

191
00:14:40,140 --> 00:14:42,780
or you can also add an existing remote.
191

192
00:14:42,900 --> 00:14:46,830
So if you created a GitHub remote already and you just want to add that existing remote, then you
192

193
00:14:46,830 --> 00:14:47,670
can use this.
193

194
00:14:47,730 --> 00:14:52,030
But in most cases, you'll probably be creating a brand-new remote on GitHub.
194

195
00:14:52,050 --> 00:14:55,700
So go ahead and give it a repository name, a description.
195

196
00:14:55,800 --> 00:15:02,040
You can see this is very, very similar to what we did when we set up a new repository inside GitHub.
196

197
00:15:02,040 --> 00:15:07,140
And as you can see the default name for your remote is still origin and I would recommend to keep it
197

198
00:15:07,140 --> 00:15:07,740
so.
198

199
00:15:08,010 --> 00:15:08,760
So once you're done,
199

200
00:15:08,760 --> 00:15:15,780
go ahead and click Create, and it's going to push your existing repository, your local repository that's
200

201
00:15:15,780 --> 00:15:19,080
managed by Xcode to your GitHub account.
201

202
00:15:19,080 --> 00:15:25,920
And now, if you look inside this Remote folder, whereas before it was empty, you now have a origin, 
202

203
00:15:25,920 --> 00:15:29,700
and the origin has the master branch pushed to it.
203

204
00:15:29,700 --> 00:15:37,230
So, now if I head over to my GitHub repository, you can see this brand-new other repository that's been created
204

205
00:15:37,560 --> 00:15:38,460
for me.
205

206
00:15:38,630 --> 00:15:47,910
And so you can see how incredibly simple it has been to push all of these commits onto my other repository,
206

207
00:15:48,450 --> 00:15:53,500
and I've done all of that without touching the command line, without touching GitHub.
207

208
00:15:53,820 --> 00:15:57,270
So if you are using a remote repository,
208

209
00:15:57,270 --> 00:16:03,000
so from now on if you make some changes to your code, say, let's add
209

210
00:16:03,030 --> 00:16:14,210
a viewDidDisappear, and we save and we go to Source Control, and we say Commit, you have the option
210

211
00:16:14,210 --> 00:16:19,490
to push to your remote, and you can have more than one remote and you can pick which one you wanted to
211

212
00:16:19,490 --> 00:16:20,380
go to.
212

213
00:16:20,720 --> 00:16:27,200
Now, alternatively, if you ready committed without pushing, you could also use the Push functionality over
213

214
00:16:27,200 --> 00:16:28,250
here as well.
214

215
00:16:28,340 --> 00:16:34,770
So, now let me show you something. If we go on to Udder and we add a README,
215

216
00:16:34,880 --> 00:16:41,330
now this is going to make our remote repository be different to our local repository,
216

217
00:16:41,330 --> 00:16:53,630
so we're just going to say, "This is an app that gives you on demand fresh cow's milk," and let's just say,
217

218
00:16:53,660 --> 00:16:58,850
"Create README" and commit to the master branch.
218

219
00:16:58,860 --> 00:16:59,130
All right.
219

220
00:16:59,130 --> 00:17:05,640
So that's done, the README has added, and now you can see that my remote repository now has a new file
220

221
00:17:05,640 --> 00:17:09,360
that my local directory does not have.
221

222
00:17:09,360 --> 00:17:18,140
So, now if I tried to go to Source Control and I said "Push," then it's actually going to fail.
222

223
00:17:18,150 --> 00:17:21,550
And the reason is because the local repository is out of date.
223

224
00:17:21,660 --> 00:17:27,970
It's basically saying that on the remote repository, we have stuff that we don't have locally.
224

225
00:17:27,990 --> 00:17:34,860
So we're actually behind the remote repository because they have more things or more up-to-date stuff.
225

226
00:17:34,890 --> 00:17:43,410
So in order to make our local repository reflect the changes or be up to date with the remote repository,
226

227
00:17:43,650 --> 00:17:45,200
we're going to use pull.
227

228
00:17:45,210 --> 00:17:49,230
So let's first commit our local changes,
228

229
00:17:49,500 --> 00:17:54,250
so "Add viewDidDisappear."
229

230
00:17:54,720 --> 00:18:00,300
And we're going to commit that file without pushing, and then we're going to say pull, and we're going to
230

231
00:18:00,300 --> 00:18:06,510
pull from our origin/master branch, hit Pull, and it's going to pull successful.
231

232
00:18:06,510 --> 00:18:06,840
Great.
232

233
00:18:06,840 --> 00:18:13,110
So, now if we have a look inside this file Udder, you'll see that it actually pulled down that README
233

234
00:18:13,110 --> 00:18:16,220
file that we created inside GitHub.
234

235
00:18:16,230 --> 00:18:23,490
So, now our Udder local repository has everything that the remote repository has, and it has some more
235

236
00:18:23,490 --> 00:18:24,630
changes.
236

237
00:18:24,630 --> 00:18:32,550
So at this point, we're going to use push to push that latest change or that latest commit which is, of
237

238
00:18:32,550 --> 00:18:37,210
course, the one where I added the viewDidDisappear.
238

239
00:18:37,440 --> 00:18:46,500
So let's go ahead and go to Source Control, push to origin/master, hit Push, and now it will successfully push
239

240
00:18:46,590 --> 00:18:49,140
to the GitHub remote.
240

241
00:18:49,140 --> 00:18:55,080
So, now if we check under Udder, check inside ViewControl.swift, you can see if viewDidDisappear
241

242
00:18:55,080 --> 00:18:56,760
now shows up.
242

243
00:18:56,880 --> 00:19:04,260
So that's a little bit of primer on how you can work with GitHub, git source control all using Xcode.
243

244
00:19:04,350 --> 00:19:07,140
So I hope that has been interesting for you.
244

245
00:19:07,380 --> 00:19:10,880
And, of course, it's totally up to you which one you prefer,
245

246
00:19:10,890 --> 00:19:14,620
which one is quicker, easier, more reliable.
246

247
00:19:14,850 --> 00:19:20,100
And the whole reason why I showed you both ways of doing it, either using the command line or using
247

248
00:19:20,100 --> 00:19:24,740
Xcode's graphical user interface is for you to pick and choose.
248

249
00:19:24,810 --> 00:19:31,020
So in the next lesson, we're going to be diving into some slightly more advanced topics in terms of
249

250
00:19:31,020 --> 00:19:37,770
GitHub and Git, and we're going to be talking about forking, pull requests, and merging.
250

251
00:19:37,860 --> 00:19:39,630
So I will see you there.
