git push问题

$ git push
fatal: No configured push destination.
Either specify the URL from the command-line or configure a remote repository using
配置:window 7专业版64位
前提:前面的配置已经完成 可以把GitHub上代码 clone下来
解决方法 在克隆下来的文件里 进行git push

小总结:
1、新建文件夹命名test 在该文件夹下 右键Git Bash here
2、设置用户名与邮箱(要与你的GitHub上对应)
git config --global user.name ‘自己用户名’
git config --global user.email ‘自己的邮箱’
3、初始化新的Git仓库
git init (看不见记得设置电脑显示隐藏文件)
4、添加文件
touch one_file.py #创建
git add one_file.py #添加到暂存区
git commit -m ‘自己的提示’ #添加到仓库
(以上都是本地的东西)
5、与GitHub联系
git clone 自己Github的.git地址
6、在clone下来的文件中
git push
7、当文件大于100M时,会上传不到Github
git rm -r --cached 文件名
删除本地大数据
重新git commit
方法二:git log 查看之前的提交日志
git reset XXX,恢复到你没有添加大文件那次的commit记录
删除本地大文件
git push

猜你喜欢

转载自blog.csdn.net/qq_22130823/article/details/87933526
今日推荐