Open asolowiej94 opened 1 month ago
@Seithar2017
In general, to move forward with the development topic, you need to know Git perfectly so that we don’t waste time on it. It’s something you’ll always be using and constantly improving, but you need to master the basics. To complete this task, you can use anything—from chat, to YouTube, to tutorial videos—but you need to know and understand what it is, so I emphasize: you should be able to explain it.
Git is a version control system - it works locally so it means most of the tools such as branching, merging, commiting and so on can be done offline.
Github is a hosting platform where you can store your repos in cloud. Github helps to maintain projects, share code, make pull request, raise issues etc.
- Go to GitHub -> Developer Settings -> Personal access tokens -> Tokens(classic)
- in console type
- git config --global user.name "MyUserName"
- git config --global user.email "MyEmail@example.com"
- copy URL of repository from github, and type in console:
create a branch
- Make sure you are in your repository folder, e.g cd repository-name
- git checkout -b new-branch
- checkout -b means creating and switching to the new-branch
make changes,
- adding changes: git add .
save, commit:
- git commit -m "commit comment"
push:
- git push origin feature-branch
- origin just points at the repo that was cloned and that git currently points at.
Pull request and merge request is pretty much the same but used on different platform, that is Pull request is for GitHub and Merge request is for GitLab
https://www.youtube.com/watch?v=1SXpE08hvGs https://www.youtube.com/watch?v=N542A8DKoaI
Comparison as table attached