Git-documentation
Git-documentation
1.Git Introduction
2.what is source code management?
3.what is Git?
4.Difference b/w svn and git?
5.How to install git in your windows?
6.How to configure user name and mail id in git
7.Three phases of git
8.How to push your code from local to github?
9.How to create github account?
10.How to give collaboration acesses to team members?
https://git-scm.com/downloads
touch rushi
touch devops aws
ERROR1:
Run
https://github.com/
echo "# Fundstransfer-feb-2020" >> README.md
git init
git add README.md
git commit -m "first commit"
git remote add origin https://github.com/devopsrishi/Fundstransfer-feb-2020.git
git push -u origin master
Conflict error
When two developers modifies same file in two different branches and when they try to merge the code conflict error will occur
Create a folder
git init
touch sample
Vi sample
ERROR1:
$ git push -u origin master
To https://github.com/devopsrishi/tag-2020.git
! [rejected] master -> master (fetch first)
error: failed to push some refs to 'https://github.com/devopsrishi/tag-2020.git'
hint: Updates were rejected because the remote contains work that you do
hint: not have locally. This is usually caused by another repository pushing
hint: to the same ref. You may want to first integrate the remote changes
hint: (e.g., 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
Solution:
1. Git pull
2. Git push -u origin master -f
Git tag:
Creatimg tag:
creating tag
git tag tagname