git init
git add README.md
git commit -m "first commit"
git branch -M main
git remote add origin git@github.com:Pisceshub/python_work.git
git push -u origin main
git remote add origin git@github.com:Pisceshub/- python_work.git
git branch -M main
git push -u origin main
git pull origin main
git merge origin/main --allow-unrelated-histories
git add .
git commit -m "first commit"
git push -u origin main
git clone git@github.com:Pisceshub/- python_work.git python_pro
git init # will create a new .git
git init newrepo # will create a new newrepo,which include data and resources of the repository
git add .
git add *.c # .c files
git add README # README files
...
git commit -m "first commit" # '__' that need to notes commit information
git clone <repo> <directory>
git config --list
# change information :
git config -e # for the current repository
git config -e --global # for the global repository
git config --global user.name "your github name "
git config --global user.email your_github_email@runoob.com
more information reference to git base operate
git merge origin/main --allow-unrelated-histories
- translate: 无法打开到您的身份验证代理的连接。
ssh-agent bash
ssh-add -D
ssh-add C:/Users/Xugx/.ssh/id_rsa
net stop sshd
net start sshd
git add .
git commit -m "first commit"
git push origin main
在其他vscode中使用如下更新
git add .
git commit -m "first commit"
git pull origin main
git merge origin/main --allow-unrelated-histories
the embedded repository and will not know how to obtain it.
hint: If you meant to add a submodule, use:
hint:
hint: git submodule add <url> DL
hint:
hint: If you added this path by mistake, you can remove it from the
hint: index with:
hint:
hint: git rm --cached DL
hint:
hint: See "git help submodule" for more information.
删除缓存
git rm --cached .env
git rm -r --cached .
git add .gitignore
git config --global core.autocrlf false