Skip to main content

Git

Git 关联本地文件夹到远程仓库

git init
git add README.md
git commit -m "first commit"
git branch -M main
git remote add origin git@github.com:Sunburst7/llm-learning.git
git push -u origin main

Git 分支管理

git checkout -b branch_name # 切换并新建
git branch # 查看分支
git checkout main
git branch -m old_name new_name # 重命名