git命令

配置公钥后的常用步骤,建议在要上传的文件中右键打开git

  1. 全局配置
  2. git init :初始化
  3. git add . :上传缓存区
  4. git commit - m "random" :添加说明
  5. git remote rm origin :切断原来链接
  6. git remote add origin +SSH地址或着http地址 :与远程仓库建立连接
  7. git push origin master

git push -f origin master :强制推送

设置为 Windows 风格的换行符

git config --global core.autocrlf true

设置为 Unix 风格的换行符

git config --global core.autocrlf input

相关推荐
SiYuanFeng1 天前
新手学Git:如何把本地 Git 项目上传到 GitHub
git·github
前端若水1 天前
git回退并合并分支操作
git
程序员鱼皮1 天前
Git WorkTree 是什么?凭什么能让 AI 编程效率翻倍?
git·ai·程序员·编程·ai编程
懵逼的小黑子1 天前
git与远程仓库创建连接
git
前端若水1 天前
Git 撤销与恢复完全指南(超级详细版)
大数据·git·elasticsearch
golang学习记1 天前
Git 2.54 来了,这个新命令让我终于敢重写历史了
git·后端
其实防守也摸鱼1 天前
AWVS下载和安装保姆级教程
linux·服务器·git
前端若水1 天前
Git 可以做的所有操作(完整分类)
大数据·git·elasticsearch
叹一曲当时只道是寻常1 天前
Reference 工具安装与使用教程:一条命令管理 Git 仓库引用与知识沉淀
人工智能·git·ai·开源·github
前端若水1 天前
Git 仓库管理命令完全指南(超级详细版)
大数据·git·elasticsearch