sourcetree界面卡死,改用命令行提交

在github上创建了空仓库https://github.com/wantnon/UE-Yang-426,并clone到了本地(C:/GitHub2/UE-Yang-426),然后把自己修改过的ue4.26源码拷贝到这个路径,用sourcetree提交,结果由于一次性添加文件太多,“暂存所有”这一步sourcetree界面卡死,所以只能考虑用命令行提交了,问gpt4:

于是打开gitCmd

依次运行以后命令:

cd C:\GitHub2\UE-Yang-426
git init
git add .
git commit -m "Initial commit"
git remote add origin https://github.com/wantnon/UE-Yang-426.git
git push -u origin master
发现前面命令都成功,只有最后push不成功。
此时打开sourcetree,用sourcetree做最终push,发现界面又卡死了,但可以看到source的push命令写法:

于是复制这命命令放到gitCmd中去运行:

git -c diff.mnemonicprefix=false -c core.quotepath=false --no-optional-locks push -v --tags origin main:main
很快就push上去了。
 
 
 
 
 
 

posted on 2023-10-09 20:54  wantnon  阅读(173)  评论(0编辑  收藏  举报

导航