WEBVTT 0 00:00.390 --> 00:06.870 So way way back, at the beginning of the course, we introduced you to Git and GitHub as a part of the 1 00:06.930 --> 00:15.170 'I am poor' challenge and that was just to show you how Git works and how you can use GitHub or our repositories 2 00:15.180 --> 00:21.240 that are hosted on Github in order to download the skeleton project and to follow along with the tutorials. 3 00:21.270 --> 00:28.230 Now in this module, I want to introduce you formally to how Git works and how you can use it to achieve 4 00:28.290 --> 00:29.840 various powerful ends. 5 00:29.880 --> 00:35.880 And I'm going to be talking about and showing you how you can use Git both inside Xcode and on the 6 00:35.880 --> 00:43.590 command line to do things such as version control, well how to clone repositories, how to fork make pull 7 00:43.590 --> 00:48.430 requests and merge repositories and a whole bunch of really really exciting things. 8 00:48.450 --> 00:53.950 So once you're ready let's get started and let's start learning about Git. 9 00:54.030 --> 00:57.300 So let's talk about version control in its simplest form. 10 00:57.420 --> 01:01.470 Let's say that I create a new code file and I write a few lines in it. 11 01:01.470 --> 01:04.960 Now I decide to put it under version control using Git 12 01:05.010 --> 01:09.000 and let's say that I call this save point as number 1, 13 01:09.000 --> 01:12.140 now this is my first version. So 14 01:12.180 --> 01:16.600 later on as I progress I write maybe a few more lines of code. 15 01:16.920 --> 01:23.520 And at this point I decide to make another save point and I call this my second version. 16 01:23.610 --> 01:31.170 So further down the line I accidentally screw up my entire code file and it's irreparable and I get 17 01:31.170 --> 01:38.620 to the point where I would rather burn my entire code file rather than having to try and fix it. 18 01:38.670 --> 01:44.430 You do get into these situations because very often your code is interlinked and each class depends 19 01:44.430 --> 01:50.850 on another and sometimes you can screw up in a way where you know all hope is lost and I simply just 20 01:50.850 --> 01:54.560 want to roll back to the last save point. 21 01:54.630 --> 01:56.860 I can do that using Git. 22 01:57.030 --> 01:59.050 I can do that using other tools as well 23 01:59.100 --> 02:02.860 but the most popular tool and the one that we're going to be talking about is Git. 24 02:02.970 --> 02:08.910 So you can either compare your current code file so the current mess that you've made against a previous 25 02:08.910 --> 02:11.590 version so that any of the save points before. 26 02:11.730 --> 02:17.610 Alternatively you can simply just roll back to a previous version and it doesn't have to be the one 27 02:17.610 --> 02:19.520 that was immediately previous. 28 02:19.530 --> 02:25.500 You can go as far back or as far forwards as you like as long as you know which version you want. 29 02:25.500 --> 02:31.560 So in the next lesson I'm going to show you version control using Git locally on your computer. 30 02:31.560 --> 02:33.890 I'm going to use the command line to do this. 31 02:34.290 --> 02:35.160 So I'll see you there.