1 00:00:00,210 --> 00:00:02,280 Hello and welcome to this video. 2 00:00:02,310 --> 00:00:09,300 In this video, I'm going to be adding falls to a remote kit repository. 3 00:00:09,300 --> 00:00:18,030 In the previous video, I created a local guide repository, so I'm going to move a copy of that to 4 00:00:18,060 --> 00:00:21,060 a remote repository on GitHub. 5 00:00:21,180 --> 00:00:28,930 To begin, I need to create a new repository on GitHub so you can either use a link here that says create 6 00:00:28,930 --> 00:00:35,070 a repository, or you can click on the dropdown and select new repository. 7 00:00:35,080 --> 00:00:36,670 So I'm going to click on this one. 8 00:00:36,690 --> 00:00:38,070 That's the new repository. 9 00:00:38,100 --> 00:00:45,300 The user name you used when you created an account on GitHub will be displayed here, and then you have 10 00:00:45,300 --> 00:00:47,270 to give the repository a name. 11 00:00:47,280 --> 00:00:55,830 I want to call my repository the same name as the folder I have created on my desktop, so I'm just 12 00:00:55,830 --> 00:00:57,350 going to paste the name in here. 13 00:00:57,360 --> 00:00:58,440 So this is the name. 14 00:00:58,440 --> 00:01:02,760 I've got a green tick, which means that name is available to use. 15 00:01:02,760 --> 00:01:05,550 You can add a description if you wish to do so. 16 00:01:05,550 --> 00:01:11,280 That is optional and then your repository can be public or private. 17 00:01:11,310 --> 00:01:16,770 I'm going to leave it public for now, and then you can initialize a repository. 18 00:01:16,770 --> 00:01:20,710 I've already initialize a local repository, so I don't need to do that. 19 00:01:20,730 --> 00:01:23,180 You can either read me file if you want. 20 00:01:23,190 --> 00:01:25,200 You can always do this later. 21 00:01:25,230 --> 00:01:28,000 You can also add a take no file. 22 00:01:28,020 --> 00:01:29,460 You can also do that later. 23 00:01:29,490 --> 00:01:35,910 So I'm just going to click on the Create repository button and that will create my repository to my 24 00:01:35,910 --> 00:01:37,270 repository has been created. 25 00:01:37,290 --> 00:01:40,260 You can see the name of my repository displayed here. 26 00:01:40,350 --> 00:01:50,460 So once you've created a new repository on GitHub, the next step is to push my code that I have in 27 00:01:50,460 --> 00:01:52,980 my local repository on my computer. 28 00:01:52,980 --> 00:01:56,200 I want to push that into this new repository. 29 00:01:56,220 --> 00:02:01,240 If you scroll down the page here, there are some instructions on how to do that. 30 00:02:01,260 --> 00:02:06,420 So here I have already initialized the key repository, so I don't need to do that. 31 00:02:07,170 --> 00:02:09,390 I don't want to add a read me file. 32 00:02:09,800 --> 00:02:12,780 Now I've already committed my local one. 33 00:02:13,020 --> 00:02:19,020 I can add that what this would do, it would change the name of the kit branch. 34 00:02:19,140 --> 00:02:20,970 Apparently, it is called master. 35 00:02:21,090 --> 00:02:28,080 I can change that so that it's main, so I'm going to copy that line of code into my command prompt. 36 00:02:28,230 --> 00:02:31,200 I've pasted that line of code into my command prompt. 37 00:02:31,200 --> 00:02:34,410 I'm going to press, enter and execute it. 38 00:02:34,650 --> 00:02:41,770 The next thing is that I want to add the files from my local git repository. 39 00:02:41,790 --> 00:02:49,110 I want to push a copy of that to this remote repository of creators or copy the line of code and then 40 00:02:49,110 --> 00:02:51,180 put that in my command prompt. 41 00:02:51,270 --> 00:02:57,210 So I've copied that line of code here, and then I'm just going to press enter to execute it so that 42 00:02:57,210 --> 00:03:02,190 code has been executed, the command to actually push the code. 43 00:03:02,430 --> 00:03:07,260 Is this one here that says, get, push, dash, you origin main. 44 00:03:07,350 --> 00:03:13,500 So we are pushing what we have in our local repository to the repository on GitHub. 45 00:03:13,530 --> 00:03:21,180 So this is a command that those that have added this command here to push the code to my GitHub repository, 46 00:03:21,180 --> 00:03:22,250 so I press enter. 47 00:03:22,290 --> 00:03:26,380 You are prompted for your user name for GitHub. 48 00:03:26,400 --> 00:03:29,550 So enter your username for your GitHub account. 49 00:03:29,550 --> 00:03:32,560 Have entered my username for my GitHub account. 50 00:03:32,560 --> 00:03:35,400 Her press enter is asking for my password. 51 00:03:35,430 --> 00:03:44,730 After entering your personal access token, the code on your computer will be pushed to your local repository 52 00:03:44,760 --> 00:03:53,610 on GitHub, so you can see here that is the name of the repository where your code is being pushed to. 53 00:03:53,730 --> 00:04:01,260 So if we take a look at our repository on GitHub just by clicking on the name here, you will see that 54 00:04:01,260 --> 00:04:10,980 all the code from my local kit repository has been pushed across to the remote repository. 55 00:04:11,010 --> 00:04:20,290 So any time you make changes to any of the files here, you have to add them again to the local repository. 56 00:04:20,310 --> 00:04:28,470 You then need to commit them and then you need to use the command gate, push that you to push them 57 00:04:28,650 --> 00:04:31,410 back to the remote repository. 58 00:04:31,420 --> 00:04:38,820 So any changes you make locally, you always have to push it to the remote repository on GitHub. 59 00:04:39,000 --> 00:04:45,780 So that's it for this video In this video, we pushed out the code from our local GitHub repository 60 00:04:45,780 --> 00:04:49,470 to our remote repository on GitHub. 61 00:04:49,620 --> 00:04:50,700 Thanks for watching. 62 00:04:50,850 --> 00:04:51,660 Bye for now.