[git]git相关
生活随笔
收集整理的這篇文章主要介紹了
[git]git相关
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
2019獨角獸企業重金招聘Python工程師標準>>>
第一:如何創建空分支
git checkout --orphan test_i235 git rm -rf . 清空目錄 echo "README" > README git add . git commit -m 'add readme file' git push -u origin test_i235?
第二:報錯一
error: RPC failed; result=22, HTTP code = 4135 MiB/s fatal: The remote end hung up unexpectedly Writing objects: 100% (72/72), 31.35 MiB | 1.25 MiB/s, done. Total 72 (delta 22), reused 0 (delta 0) fatal: The remote end hung up unexpectedly Everything up-to-date原因:
If you get error 413, then the issue doesn't lie with git but with your web server. It's your web server that is blocking big upload files.Solution for nginxJust load your nginx.conf and add client_max_body_size 50m; ( changing the value to your needs ) in the http block.Reload nginx to accept the new config by executing sudo service nginx reload and try again to push your commit over http.Solution for ApacheIn your httpd.conf add LimitRequestBody 52428800 ( changing the value to your needs ) inside a <Directory /> block. Doing this you can limit the request of the whole server filesystem, just a single Virtual Host or a directory.I hope this helps.http://stackoverflow.com/questions/7489813/github-push-error-rpc-failed-result-22-http-code-413
?
第二:報錯二
Access denied. fatal: Could not read from remote repository.Please make sure you have the correct access rights and the repository exists.原因: 工程配置的公鑰只能pull和clone,而用戶配置的公鑰可以push?
第三: 將conflict恢復之前
git reset --merge?
第四:空目錄不能push
轉載于:https://my.oschina.net/u/259976/blog/760555
總結
以上是生活随笔為你收集整理的[git]git相关的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 配置DNS服务
- 下一篇: ElasticSearch大数据分布式弹