1
00:00:00,100 --> 00:00:00,360
OK.

2
00:00:00,360 --> 00:00:01,480
Welcome back.

3
00:00:01,590 --> 00:00:09,690
So in the last video we saw four new commands get in that status add and commit all very useful especially

4
00:00:09,690 --> 00:00:16,220
add and commit you use all the time but all that that lets us do is add in files and commit them.

5
00:00:16,220 --> 00:00:22,910
Save them basically make little checkpoints to actually go back the old code.

6
00:00:22,980 --> 00:00:24,450
We're going to see two new commands.

7
00:00:24,450 --> 00:00:29,700
Get log in get checked out and they're actually going to show you a few more but they're not as essential

8
00:00:29,700 --> 00:00:30,950
as these two.

9
00:00:31,380 --> 00:00:33,550
So I'm in the same folder if I type.

10
00:00:33,830 --> 00:00:35,300
Let's start with us.

11
00:00:35,340 --> 00:00:38,760
You can see I have those three files for type get status.

12
00:00:38,760 --> 00:00:43,890
I haven't made any changes and if I take a look who me just reopen them.

13
00:00:44,040 --> 00:00:48,120
C-9 actually yes.

14
00:00:48,810 --> 00:00:53,460
And let's do cat and dogs.

15
00:00:53,670 --> 00:00:57,370
I don't know if I've shown you that before you can just chain them together like that.

16
00:00:57,810 --> 00:00:58,150
OK.

17
00:00:58,200 --> 00:01:02,730
So we have these three files the dogs one is empty.

18
00:01:02,730 --> 00:01:03,630
That's fine.

19
00:01:03,960 --> 00:01:08,880
Let's suppose that this is a huge app and I somehow messed something up and I get an error.

20
00:01:08,970 --> 00:01:12,540
So I do something wrong and my code no longer works.

21
00:01:12,750 --> 00:01:17,790
And again pretend it's a big app and I don't actually know what the problem is or maybe I was trying

22
00:01:17,790 --> 00:01:20,290
something out and I decided screw it.

23
00:01:20,370 --> 00:01:21,760
I don't actually like that.

24
00:01:21,780 --> 00:01:24,320
Let's go back to my old version.

25
00:01:24,330 --> 00:01:31,440
So the first thing you want to do is type get log in and this will give us a history or a log of all

26
00:01:31,440 --> 00:01:35,400
the commits that we've made in this repo.

27
00:01:35,400 --> 00:01:36,910
So a quick note.

28
00:01:36,990 --> 00:01:44,190
It opens up this kind of new terminal interface where if you hit enter it's actually going to scroll

29
00:01:45,420 --> 00:01:50,290
you can use the up arrow as well to scroll through but you can't type regular commands right now.

30
00:01:50,310 --> 00:01:52,020
Notice how the cursor has changed a little.

31
00:01:52,020 --> 00:01:56,160
There's a curse or there's a colon right here to get out of this.

32
00:01:56,160 --> 00:02:00,040
You can type Q So go back get log.

33
00:02:00,540 --> 00:02:02,590
And let's start at the very beginning.

34
00:02:02,610 --> 00:02:03,580
So at the bottom.

35
00:02:03,840 --> 00:02:12,360
First thing I did You can see first the author the date the time that I made this and the code that

36
00:02:12,360 --> 00:02:16,150
I ran which was are they commit message add X-File.

37
00:02:17,370 --> 00:02:24,310
And then the next one was add catch file and then add me out to cats and dogs file.

38
00:02:24,390 --> 00:02:27,330
And that was you know we had update files as well.

39
00:02:27,960 --> 00:02:31,700
So yes they all have times the messages though are really important.

40
00:02:31,830 --> 00:02:37,470
And they need to be descriptive especially if you're revisiting code if you're coming back to it after

41
00:02:37,470 --> 00:02:38,710
a while away.

42
00:02:38,880 --> 00:02:45,020
But the most important part as far as get is concerned the actual commands that we run.

43
00:02:45,360 --> 00:02:47,610
We never actually type these commit messages again.

44
00:02:47,610 --> 00:02:48,700
They're just for humans.

45
00:02:48,720 --> 00:02:55,670
But the important part for good for the computer is this commit hash here this long string.

46
00:02:55,740 --> 00:03:00,000
It's really really important because that's the unique identifier.

47
00:03:00,360 --> 00:03:07,410
So that's what if I want to go back I want to look at the code from the very beginning add app file

48
00:03:07,800 --> 00:03:08,740
back in time.

49
00:03:08,940 --> 00:03:10,920
I need this.

50
00:03:11,610 --> 00:03:12,900
So I'm going to copy that.

51
00:03:13,080 --> 00:03:18,600
Let's say I want to go back all the way until when I just had the app file no cat file no dugs file

52
00:03:18,600 --> 00:03:19,190
.

53
00:03:19,410 --> 00:03:27,260
I copy this here command C and I hit Q to get out and then we're going to see the new command.

54
00:03:27,360 --> 00:03:30,200
Or the second new command which is get checked out.

55
00:03:30,780 --> 00:03:34,100
So I type get check out and this is a really versatile command.

56
00:03:34,290 --> 00:03:40,290
It's used for a lot of different things but the general idea is that it's used for just going and viewing

57
00:03:40,290 --> 00:03:46,110
something else going and checking something else out whether it's a branch or it's a previous commit

58
00:03:46,110 --> 00:03:47,280
.

59
00:03:47,280 --> 00:03:52,020
We haven't talked about branches by the way but it's often used to do that to change branches.

60
00:03:52,140 --> 00:03:56,830
So we need to get checked out and then paste that long string in and hit enter.

61
00:03:57,240 --> 00:04:04,750
And actually before I do that let me get out of there and just type get status.

62
00:04:05,310 --> 00:04:11,850
First thing I see is that I did make a change in my app Yes which is fine but I didn't stage it for

63
00:04:11,850 --> 00:04:18,480
Commit I didn't add it but more importantly said on Branch master again we don't really know what branches

64
00:04:18,480 --> 00:04:23,350
are but but all that you need to know for now is that master is our home base.

65
00:04:23,520 --> 00:04:25,790
So everything we've done has been on Master.

66
00:04:26,280 --> 00:04:26,780
OK.

67
00:04:27,090 --> 00:04:32,340
And I also have this little get prompt here on my command prompt it says master.

68
00:04:32,940 --> 00:04:36,630
So now if I do run that command looks like I lost it.

69
00:04:36,660 --> 00:04:37,370
Type it again.

70
00:04:37,410 --> 00:04:41,150
Get check out and paste that and then hit enter.

71
00:04:41,310 --> 00:04:46,230
First thing you'll see is that it's telling me I have changes that aren't committed.

72
00:04:46,440 --> 00:04:51,000
And if I check out this if I go back here I'm going to lose those changes.

73
00:04:51,360 --> 00:04:54,660
And that's because it can only keep track of so many things at once.

74
00:04:54,690 --> 00:04:56,340
So I have some changes right now.

75
00:04:56,340 --> 00:05:03,210
This one line that I made and get is watching that and saying do you want me to commit this to you want

76
00:05:03,210 --> 00:05:04,400
me to add this.

77
00:05:04,680 --> 00:05:10,500
But if I go back and view some old code it is not going to know about this anymore.

78
00:05:10,620 --> 00:05:13,610
So it's basically warning me before you go back.

79
00:05:13,710 --> 00:05:19,800
You should probably add and commit this or get rid of it entirely so just don't care about it just overwrite

80
00:05:19,800 --> 00:05:20,110
it.

81
00:05:20,280 --> 00:05:24,060
I'm going to add in commit though I'm going to do it get ad app.

82
00:05:24,080 --> 00:05:35,160
Yes and my commit message will just be mess up app file to get status nothing to commit.

83
00:05:35,250 --> 00:05:36,710
Still on Branch master.

84
00:05:36,730 --> 00:05:39,390
Now let's try and check that out again.

85
00:05:40,480 --> 00:05:44,920
This time we get a much longer message.

86
00:05:44,920 --> 00:05:50,150
Most importantly though notice that it no longer says Master right here.

87
00:05:50,640 --> 00:05:52,140
It gets cut off because it's so long.

88
00:05:52,140 --> 00:05:59,350
But if I type that status I see head detached at 5 c d d blah blah blah.

89
00:05:59,350 --> 00:06:02,170
Which is the beginning of that hash.

90
00:06:02,760 --> 00:06:10,600
OK so in my opinion this is very good starts to get really confusing this term head here.

91
00:06:10,990 --> 00:06:15,300
It's always confusing to most people I know including our developers.

92
00:06:15,310 --> 00:06:17,400
It's basically a pointer in.

93
00:06:17,440 --> 00:06:24,620
They give it as a pointer in space or in time the current place where you are and you can move it around

94
00:06:24,620 --> 00:06:27,270
to move back and forth through time.

95
00:06:27,270 --> 00:06:31,280
What's important though is that we're no longer on Master.

96
00:06:31,300 --> 00:06:36,610
So what we've done is we've gone back and looked at we're basically checking out we're inspecting the

97
00:06:36,610 --> 00:06:37,860
old version of the code.

98
00:06:37,870 --> 00:06:41,650
So if I type LS This is what's pretty cool about it.

99
00:06:41,750 --> 00:06:43,350
I only have one file here.

100
00:06:43,540 --> 00:06:51,400
So when I went back when I checked that old code out it basically transported me back in time it took

101
00:06:51,390 --> 00:06:54,540
me back and I could see what I had back then.

102
00:06:55,060 --> 00:07:00,760
But it is important to note that when I when I do a check out like I'd get checked out and then the

103
00:07:00,750 --> 00:07:07,620
name the commit hash if I do that it kind of takes me out of the current flow or the normal workflow

104
00:07:07,620 --> 00:07:08,100
of good.

105
00:07:08,130 --> 00:07:10,290
That's why it says Head detached.

106
00:07:10,360 --> 00:07:18,610
So if you imagine our history has a history as sort of a timeline that looks like this where each one

107
00:07:18,610 --> 00:07:24,850
of these shows is a commit.

108
00:07:24,860 --> 00:07:27,950
Just do a few more.

109
00:07:30,370 --> 00:07:31,620
OK.

110
00:07:31,920 --> 00:07:32,700
Oh geez.

111
00:07:32,800 --> 00:07:33,480
There we go.

112
00:07:33,490 --> 00:07:39,970
So each one of these is sort of a point in time where we committed and it's in a sort of a linear list

113
00:07:39,970 --> 00:07:44,180
here where we started that one and then we made some changes committed again.

114
00:07:44,310 --> 00:07:46,420
And there's a flow to this.

115
00:07:46,530 --> 00:07:50,400
This is where we were the last commit.

116
00:07:50,500 --> 00:07:58,950
This is what is known currently at least this is where a master is so obvious right that Master This

117
00:07:58,960 --> 00:08:03,260
is where we were before we made this get check out command.

118
00:08:03,270 --> 00:08:11,560
Then I ran get check out and this commit and it took me all the way back to I believe our very first

119
00:08:11,760 --> 00:08:16,760
commit and it told us that head detached at that commit message.

120
00:08:16,770 --> 00:08:19,290
So that means that master is still here.

121
00:08:19,380 --> 00:08:22,530
We haven't moved this master back.

122
00:08:22,530 --> 00:08:26,320
What we've done is kept it there but we've detached the head.

123
00:08:26,310 --> 00:08:28,920
And again I do think this is very confusing.

124
00:08:28,960 --> 00:08:37,150
What's important is that basically we've added in this idea of what just a is right here.

125
00:08:37,480 --> 00:08:42,200
Not sure why that changed the syntax highlighting but head is here.

126
00:08:42,460 --> 00:08:46,570
But we left off here so we have unfinished business over here.

127
00:08:46,890 --> 00:08:49,620
So what we either need to do is totally up to us.

128
00:08:49,620 --> 00:08:55,710
Usually when we use check out it's to just go look at some old change just to check out our old code

129
00:08:55,920 --> 00:08:57,730
and then go back to where we were.

130
00:08:58,020 --> 00:09:03,610
So think of it as hitting the pause button on the code that we had and then we checked out some previous

131
00:09:03,610 --> 00:09:10,990
code which is where we are right now and then maybe we copy a line or two maybe we view a note that

132
00:09:10,990 --> 00:09:18,040
we wrote to ourselves or look at some old code and then we go back to master and that will fix a problem

133
00:09:18,250 --> 00:09:19,590
of head detection.

134
00:09:19,600 --> 00:09:25,560
It's not really a problem but it can be because if I start making changes right now in my app James

135
00:09:25,590 --> 00:09:31,600
and I try and add and commit will run into a problem which is that it's I know what to do because we

136
00:09:31,600 --> 00:09:35,630
have these we have a master here we have head here.

137
00:09:35,800 --> 00:09:37,020
We're going to make a decision.

138
00:09:37,060 --> 00:09:41,100
So usually what we do is we check something out inspected.

139
00:09:41,250 --> 00:09:44,070
Look at it view some code and then go back to master.

140
00:09:44,080 --> 00:09:49,350
Sometimes though you want to just go back to an old version and revert.

141
00:09:49,360 --> 00:09:55,780
Which basically means go back and just start at that point in time rather than just checking it out

142
00:09:55,790 --> 00:09:56,010
.

143
00:09:56,230 --> 00:09:59,420
So before I do that let me just show you how you go back to master.

144
00:09:59,700 --> 00:10:05,500
So again get status says that we're had detached on this long string.

145
00:10:05,500 --> 00:10:05,960
I could do.

146
00:10:05,970 --> 00:10:06,450
Good.

147
00:10:06,510 --> 00:10:08,010
Check out master.

148
00:10:08,130 --> 00:10:10,100
And that takes me back forward in time.

149
00:10:11,400 --> 00:10:18,820
And now first thing I noticed those files come back I type ls and now have those three files again and

150
00:10:19,180 --> 00:10:20,990
right type get status.

151
00:10:21,380 --> 00:10:23,500
I'm on Branch master.

152
00:10:24,070 --> 00:10:26,170
So we took a little trip backwards.

153
00:10:26,170 --> 00:10:27,340
Half of us was a peer.

154
00:10:27,340 --> 00:10:32,970
Half of us was back there and then we went back to master and everything is happy again.

155
00:10:33,470 --> 00:10:34,160
All right.

156
00:10:34,270 --> 00:10:41,320
But let's say do want to go back I want to revert back to let's do get log to before we added the dogs

157
00:10:41,320 --> 00:10:41,890
file.

158
00:10:42,100 --> 00:10:46,760
So this commit commit message where we added in meow to the catch file.

159
00:10:46,840 --> 00:10:50,840
So we should have the cats and the app file and I just want to go back to that.

160
00:10:51,070 --> 00:10:56,560
So I don't want to just go check it out and look at it but I actually want my code to reflect that state

161
00:10:56,560 --> 00:10:57,030
.

162
00:10:57,100 --> 00:11:03,880
I want to add a new commit that says we reverted back I'm starting over without the dogs file.

163
00:11:04,240 --> 00:11:09,310
So this would be like if you scrapped you know a big part of your novel or you want to just go back

164
00:11:09,310 --> 00:11:15,130
before you added in user authentication or before you added in Bootstrap and you just want to go back

165
00:11:15,130 --> 00:11:15,960
and start over.

166
00:11:15,960 --> 00:11:22,110
At that point and the unfortunate thing here is that there are a lot of ways of doing this.

167
00:11:22,180 --> 00:11:25,470
And before I actually show you some of them I'm just going to show you one.

168
00:11:25,480 --> 00:11:30,980
But before I do that I want to add a note here about how developers use it.

169
00:11:31,360 --> 00:11:36,760
Most developers and this is definitely generalization but most developers are pretty are very comfortable

170
00:11:36,760 --> 00:11:43,780
with the common workflow that we've been talking about status add commit status and commit over and

171
00:11:43,780 --> 00:11:48,400
over maybe checking out something developers will work with branches.

172
00:11:48,550 --> 00:11:56,260
But when it comes to reverting back to old code to undoing something to deleting changes whatever it

173
00:11:56,260 --> 00:11:59,930
is that's something that you actually don't do it often.

174
00:12:00,130 --> 00:12:05,950
It's pretty rare that you abandon you know your current code especially when you're on a bigger team

175
00:12:05,950 --> 00:12:06,820
.

176
00:12:06,820 --> 00:12:08,340
It's not it's not that it never happens.

177
00:12:08,350 --> 00:12:11,370
But those sort of things are not the norm.

178
00:12:11,800 --> 00:12:17,290
And I would say that most developers don't know how to do that off the top of their head or they might

179
00:12:17,290 --> 00:12:21,090
know one way of doing it but there's five or 10 different ways of doing it.

180
00:12:21,460 --> 00:12:25,940
So the way that people use get again is that they're comfortable with a lot of the basics.

181
00:12:26,200 --> 00:12:29,260
The bread and butter commands really five to seven commands.

182
00:12:29,260 --> 00:12:32,750
And then one day someone will have to do something they don't know how to do.

183
00:12:32,890 --> 00:12:34,720
And they just research it.

184
00:12:34,720 --> 00:12:38,090
So something like Stack Overflow is really really helpful.

185
00:12:38,320 --> 00:12:43,080
And if we look I have a stack overflow postage included as a link.

186
00:12:43,080 --> 00:12:44,340
There is a question here.

187
00:12:44,470 --> 00:12:48,390
How do I revert from my current state to a snapshot made on a certain commit.

188
00:12:48,400 --> 00:12:53,950
So how do I go back to an old commit not just check it out like we saw but how do I actually revert

189
00:12:53,950 --> 00:12:54,720
to it.

190
00:12:55,030 --> 00:13:01,040
And there's probably 20 different answers and none of them are the same.

191
00:13:02,110 --> 00:13:03,730
So I'll just walk through some of them.

192
00:13:03,790 --> 00:13:06,220
You're going to see some of them are multiple lines long.

193
00:13:06,430 --> 00:13:13,330
Some of them will ask you or some of them will have you basically destroy any of the commits that you've

194
00:13:13,330 --> 00:13:16,060
made before you revert back.

195
00:13:16,060 --> 00:13:18,670
Some of them will keep the commits that you have.

196
00:13:18,670 --> 00:13:20,110
There's lots of different ways.

197
00:13:20,170 --> 00:13:23,560
The one that I'm going to work with is this one here.

198
00:13:23,570 --> 00:13:29,660
It's nice and short and it's pretty easy to do what we do as we type get reversed.

199
00:13:29,920 --> 00:13:37,390
Dash dash no dash commit and then the commit that we want to revert back to dot dot head.

200
00:13:37,600 --> 00:13:43,090
And as you can see here it says this will revert everything from the head back to the commit hash back

201
00:13:43,090 --> 00:13:49,120
to whatever commit we provided meaning it will recreate that commits date as if every commit since have

202
00:13:49,120 --> 00:13:49,880
been a walk back.

203
00:13:49,900 --> 00:13:51,140
So that's not as important.

204
00:13:51,430 --> 00:13:58,900
And then the dash dash No commit is a flag that tells it just to revert all the commits at once rather

205
00:13:58,900 --> 00:14:04,300
than doing them one at a time which would then ask us for a message for every single one.

206
00:14:04,360 --> 00:14:09,970
So rather than doing that we can just do dash dash No commit it will revert everything back and then

207
00:14:09,970 --> 00:14:16,280
we can run get commit and give it a message like reverted back or undo changes whatever we do.

208
00:14:16,510 --> 00:14:22,880
So let's try it out now to go back here and I'm going to copy this into the notes so you have that there

209
00:14:22,900 --> 00:14:25,910
as well as paste it here.

210
00:14:26,350 --> 00:14:30,130
And again this obviously needs to change depending on your commit.

211
00:14:30,190 --> 00:14:32,410
So I want to go back.

212
00:14:32,410 --> 00:14:36,980
I think oh I just copied something else I don't have it on my clipboard anymore.

213
00:14:37,030 --> 00:14:44,140
I want to go back to when I added meow to cats and let's just take a quick look at what the files look

214
00:14:44,140 --> 00:14:45,180
like right now.

215
00:14:45,730 --> 00:14:47,700
So dogs is empty.

216
00:14:48,310 --> 00:14:53,060
Cats has meow and purr and address has all of this stuff.

217
00:14:53,530 --> 00:14:54,300
OK.

218
00:14:54,910 --> 00:15:02,990
So now if I try this line first always type get status and one thing that's worth noting is that if

219
00:15:02,990 --> 00:15:06,550
you try and revert and you have changes that are uncommitted.

220
00:15:06,590 --> 00:15:10,820
So if I made a new file or if I change something in dogs.

221
00:15:10,880 --> 00:15:11,170
Yes.

222
00:15:11,180 --> 00:15:13,750
And I tried to revert it would would warn me.

223
00:15:13,760 --> 00:15:17,150
I would say you have uncommitted changes what do you want me to do.

224
00:15:17,420 --> 00:15:19,670
So most the time you just add those changes.

225
00:15:19,700 --> 00:15:22,150
Commit them and then you would refer.

226
00:15:22,640 --> 00:15:32,280
OK so get river dash dash no dash commit then Pace said stringin dash dash or dot dot head.

227
00:15:32,900 --> 00:15:34,400
Yes I know this is a lot.

228
00:15:34,400 --> 00:15:37,470
No I would never remember this myself.

229
00:15:37,520 --> 00:15:38,550
You stack overflow.

230
00:15:38,570 --> 00:15:40,660
You find it online again.

231
00:15:40,730 --> 00:15:41,780
Use your Googling skills.

232
00:15:41,780 --> 00:15:42,200
It is.

233
00:15:42,200 --> 00:15:42,790
It is.

234
00:15:43,010 --> 00:15:48,650
As I mentioned something that you don't do all that often but it is important to know how to find and

235
00:15:48,650 --> 00:15:52,070
figure out how to do it not that you need to memorize this at all.

236
00:15:52,100 --> 00:15:54,720
So get commit add and knit.

237
00:15:54,800 --> 00:15:56,610
Those are worth memorizing.

238
00:15:56,780 --> 00:15:59,870
But something like this river dash dash No commit.

239
00:16:00,140 --> 00:16:02,160
I wouldn't waste your time on it.

240
00:16:02,810 --> 00:16:04,070
OK.

241
00:16:04,490 --> 00:16:05,780
Noticed that happened over here.

242
00:16:05,930 --> 00:16:10,310
You can see we have at Jasin cats J.S. but dogs is gone.

243
00:16:10,550 --> 00:16:12,230
Let's look at cats.

244
00:16:12,260 --> 00:16:13,690
It only has meow.

245
00:16:14,030 --> 00:16:17,690
Let's look at actually yes it only has a single line.

246
00:16:17,690 --> 00:16:22,920
This is my complex app for I type get status right now.

247
00:16:24,200 --> 00:16:30,740
You'll see that we actually have some changes that that need to be committed and those changes are what

248
00:16:30,800 --> 00:16:32,180
basically just changed.

249
00:16:32,180 --> 00:16:37,150
When I reverted back it deleted the dog's file and it changed app and cats.

250
00:16:37,220 --> 00:16:38,120
Yes.

251
00:16:38,150 --> 00:16:43,150
So let's add commit and we don't need to add.

252
00:16:43,190 --> 00:16:44,290
We just need to commit.

253
00:16:44,290 --> 00:16:47,230
You can see it already says change is to be committed.

254
00:16:48,800 --> 00:16:53,040
And also it tells us you are currently reverting commit and then the commit message.

255
00:16:53,390 --> 00:17:02,060
OK so we would usually put in here is revert back to and then you could either pace that long hash right

256
00:17:02,090 --> 00:17:09,040
there that string or you could give a commit message or a point in time revert back to before authentication

257
00:17:09,080 --> 00:17:15,950
broke or revert back to before bootstrap added and then hit enter.

258
00:17:15,990 --> 00:17:19,570
Now to get status were on Master.

259
00:17:19,580 --> 00:17:21,970
Nothing to commit or can directory's clean.

260
00:17:22,070 --> 00:17:29,400
I have actually yes in cats yes it is important to note that I don't just lose everything.

261
00:17:29,570 --> 00:17:36,710
If I did want to go back to when I have had the dogs file I could do get log and you know see my committee

262
00:17:36,740 --> 00:17:47,180
now look like this very first one ad app file then add cat's file add me out to cats and dogs file update

263
00:17:47,180 --> 00:17:52,670
files mess up file and then revert back.

264
00:17:52,670 --> 00:18:01,280
So even though I no longer have the dog file basically the state that we were in here I do have this

265
00:18:01,280 --> 00:18:01,940
commit.

266
00:18:02,260 --> 00:18:03,360
So I didn't either.

267
00:18:03,370 --> 00:18:04,180
I don't lose it.

268
00:18:04,280 --> 00:18:07,770
I can revert back to that at any point if I want it to.

269
00:18:07,790 --> 00:18:12,890
So it gets really really powerful and I think it's also really intimidating when you're starting out

270
00:18:13,370 --> 00:18:14,950
when you see something like this.

271
00:18:14,990 --> 00:18:17,890
So I debated showing you reverting.

272
00:18:18,260 --> 00:18:23,330
I had the reason I decided to do it is because even though you don't do it a lot I think it shows you

273
00:18:23,780 --> 00:18:28,090
what you can do with get that with a single line maybe two lines.

274
00:18:28,290 --> 00:18:33,650
You can have 100 files and you could revert back to when you had one file or you could have 100 files

275
00:18:33,650 --> 00:18:38,720
that were all filled out with thousand lines each and you could write back and they might only have

276
00:18:38,720 --> 00:18:39,750
one line each.

277
00:18:39,770 --> 00:18:40,900
You can you can use it.

278
00:18:40,900 --> 00:18:46,130
It's really powerful especially when you're working on bigger projects.

279
00:18:46,130 --> 00:18:50,720
So I debated showing it to you though because I think it's a little bit intense.

280
00:18:50,790 --> 00:18:54,650
It's a lot to see and it's you know something like this.

281
00:18:54,770 --> 00:18:59,290
It's not it's not easy for anyone to remember or anyone to just know.

282
00:18:59,600 --> 00:19:00,890
So I don't to get that impression.

283
00:19:00,890 --> 00:19:04,550
I know I'm a broken record here but don't freak out about this line.

284
00:19:05,060 --> 00:19:05,880
OK.

285
00:19:06,380 --> 00:19:12,530
So we've talked a little bit about this workflow ad commit status if you want to you can check out old

286
00:19:12,560 --> 00:19:13,300
code.

287
00:19:13,460 --> 00:19:18,470
You can revert if you need to just take a look at the stack overflow post if you ever need to do it

288
00:19:18,470 --> 00:19:19,210
.

289
00:19:19,340 --> 00:19:22,590
What we're going to see next is how get how it plays into this.

290
00:19:22,760 --> 00:19:25,160
So we've seen how we can use it locally.

291
00:19:25,310 --> 00:19:27,320
So I could work on a project a novel.

292
00:19:27,350 --> 00:19:32,840
I can write my novel at little checkpoints with get ad get commit and then I can go back and look at

293
00:19:32,840 --> 00:19:34,270
what I had or I can revert.

294
00:19:34,400 --> 00:19:40,310
But now what if I wanted to put my code put my novel up on good hub so that other people could share

295
00:19:40,310 --> 00:19:40,470
it.

296
00:19:40,490 --> 00:19:45,170
Other people could read it other people could edit it they could get it on their own machine make some

297
00:19:45,170 --> 00:19:47,490
changes and then share that with other people.

298
00:19:47,690 --> 00:19:51,710
So that's what get how busy is for and that's what we're going to talk about in the next video.
