已有项目如何上传新建的GIT仓库

59 阅读1分钟

1.Git 全局设置:

git config --global user.name "用户名" git config --global user.email "邮箱"

2.创建 git 仓库:

mkdir 文件夹 cd 文件夹 git init touch README.md git add README.md git commit -m "first commit" git remote add origin git远程地址 git push -u origin "master"

3.已有仓库? cd existing_git_repo git remote add origin git远程给地址 git push -u origin "master"