git工具上传文件超过100MB解决方法

Github 上传超过100M的大文件 - 简书 (jianshu.com)

看到一个不错的贴子。


29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system
$ git init
Initialized empty Git repository in D:/predict-system/.git/

29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ git lfs track predict-system.zip
Tracking "predict-system.zip"

29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ git add .gitattributes

29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ git commit -m "first"
[master (root-commit) f84f8d9] first
 1 file changed, 1 insertion(+)
 create mode 100644 .gitattributes

29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$  git remote add origin  https://github.com/Harzerr/Large_scale_Online_Academic_Performance_Prediction_System.git

29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ git push origin master
fatal: unable to access 'https://github.com/Harzerr/Large_scale_Online_Academic_Performance_Prediction_System.git/': Failed to connect to github.com port 443 after 21040 ms: Couldn't connect to server

29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ git push
fatal: The current branch master has no upstream branch.
To push the current branch and set the remote as upstream, use

    git push --set-upstream origin master

To have this happen automatically for branches without a tracking
upstream, see 'push.autoSetupRemote' in 'git help config'.


29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ git push
fatal: The current branch master has no upstream branch.
To push the current branch and set the remote as upstream, use

    git push --set-upstream origin master

To have this happen automatically for branches without a tracking
upstream, see 'push.autoSetupRemote' in 'git help config'.


29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ git push origin master
Remote "origin" does not support the Git LFS locking API. Consider disabling it with:
  $ git config lfs.https://github.com/Harzerr/Large_scale_Online_Academic_Performance_Prediction_System.git/info/lfs.locksverify false
Post "https://github.com/Harzerr/Large_scale_Online_Academic_Performance_Prediction_System.git/info/lfs/locks/verify": dial tcp 20.205.243.166:443: connectex: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.
error: failed to push some refs to 'https://github.com/Harzerr/Large_scale_Online_Academic_Performance_Prediction_System.git'

29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ git config lfs.https://github.com/xxx.git/info/lfs.locksverify falsefalse

29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ git push origin master
Enumerating objects: 3, done.
Counting objects: 100% (3/3), done.
Delta compression using up to 8 threads
Compressing objects: 100% (2/2), done.
Writing objects: 100% (3/3), 259 bytes | 259.00 KiB/s, done.
Total 3 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
remote:
remote: Create a pull request for 'master' on GitHub by visiting:
remote:      https://github.com/Harzerr/Large_scale_Online_Academic_Performance_Prediction_System/pull/new/master
remote:
To https://github.com/Harzerr/Large_scale_Online_Academic_Performance_Prediction_System.git
 * [new branch]      master -> master

29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ git add .
git commit -m "提交test大文件文件"
git push
[master 571c3f0] 提交test大文件文件
 1 file changed, 3 insertions(+)
 create mode 100644 predict-system.zip
fatal: The current branch master has no upstream branch.
To push the current branch and set the remote as upstream, use

    git push --set-upstream origin master

To have this happen automatically for branches without a tracking
upstream, see 'push.autoSetupRemote' in 'git help config'.


29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ git add .

29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ git commit -m "提交test大文件文件"
On branch master
nothing to commit, working tree clean

29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ git push master
fatal: 'master' does not appear to be a git repository
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ git push origin master
batch response: This repository is over its data quota. Account responsible for LFS bandwidth should purchase more data packs to restore access.
Uploading LFS objects:   0% (0/1), 0 B | 0 B/s, done.
error: failed to push some refs to 'https://github.com/Harzerr/Large_scale_Online_Academic_Performance_Prediction_System.git'

29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ # 删除 .git/hooks/pre-push 文件即可
That looks like a server issue with deploy keys. For now, try removing .git/hooks/pre-push.
bash: That: command not found

29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$ git push origin master
Enumerating objects: 4, done.
Counting objects: 100% (4/4), done.
Delta compression using up to 8 threads
Compressing objects: 100% (3/3), done.
Writing objects: 100% (3/3), 423 bytes | 423.00 KiB/s, done.
Total 3 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
To https://github.com/Harzerr/Large_scale_Online_Academic_Performance_Prediction_System.git
   f84f8d9..571c3f0  master -> master

29660@DESKTOP-CAB6SQB MINGW64 /d/predict-system (master)
$

最近更新

  1. docker php8.1+nginx base 镜像 dockerfile 配置

    2024-04-14 09:52:01       94 阅读
  2. Could not load dynamic library ‘cudart64_100.dll‘

    2024-04-14 09:52:01       100 阅读
  3. 在Django里面运行非项目文件

    2024-04-14 09:52:01       82 阅读
  4. Python语言-面向对象

    2024-04-14 09:52:01       91 阅读

热门阅读

  1. leetcode最长有效括号

    2024-04-14 09:52:01       36 阅读
  2. Swift中的结构体

    2024-04-14 09:52:01       33 阅读
  3. Swift中的枚举

    2024-04-14 09:52:01       38 阅读
  4. AJAX教程笔记,常用API

    2024-04-14 09:52:01       32 阅读
  5. 分布式基础环境搭建

    2024-04-14 09:52:01       35 阅读
  6. 数据结构_带头双向循环链表

    2024-04-14 09:52:01       36 阅读
  7. geekos-project3

    2024-04-14 09:52:01       40 阅读