11.3.18

How to create a new project code repo in GitLab

Pre-requisites:-

1. Account in GitLab
2. Sourcetree setup on your system
3. Project Code to push into repo

Step for how to create a new project code repo:-

1. Go to Gitlab and create a new project
2. open the source tree and click on the + button just below the top menu, which adds a new tab.
3. once the new tab is opened click on the create"+". Click YES on popup
4. Browse the path and of the folder which you want to checkin and click on the create. you will see all the files
from that folder to be displaying in the bottom pane.
5. Go the windows folder view into the code/framework folder, add a .gitignore file into that folder.
make sure this file don't have extension of text, you can remove the .txt extension by save as option/all files.
6. we can get this .gitignore file content by searching in google, copy and past in the Notepad++ and
save it as .gitignore with out any .txt extension
7. Back to source tree and check the files count displaying, we will see some files removed from the pane,
As we always don't need to checkin all the files .gitignore know what to add and remove to the git repo.
8. Click on the stage all button on top of the bottom pane.files will move to top pane
9. write some comments and click on commit. Now the local repo is created. now we want this repo
to connect to centeral repo
10. Copy the url from the Gitlab project on top the project page.
11. Back to source tree, click on the settings--->Add--->
type Remote name:- origin
url/path:- Past the url copied from Gitlab project from step 10
12. click on the PUSH button to commit the code to remote branch.

No comments:

Post a Comment

How to create a new project code repo in GitLab

Pre-requisites:- 1. Account in GitLab 2. Sourcetree setup on your system 3. Project Code to push into repo Step for how to create a n...