Administrator@7PV3XG28ZW8YCKU MINGW64 /classes
$ git pull
fatal: Not a git repository (or any of the parent directories): .git
根据网上的提示
Administrator@7PV3XG28ZW8YCKU MINGW64 /classes
$ git init
Initialized empty Git repository in F:/Git/classes/.git/
Administrator@7PV3XG28ZW8YCKU MINGW64 /classes (master)
$ git status
On branch master
Initial commit
Untracked files:
(use "git add <file>..." to include in what will be committed)
Java0708Repo/
nothing added to commit but untracked files present (use "git add" to track)
又出现另外的错误
Administrator@7PV3XG28ZW8YCKU MINGW64 /classes (master)
$ git pull
fatal: No remote repository specified. Please, specify either a URL or a
remote name from which new revisions should be fetched.
原因是远程仓库损坏,解决方案如下
Administrator@7PV3XG28ZW8YCKU MINGW64 /classes (master)
$ git remote add origin https://gitee.com/ShrekerNil/Java0708Repo.git
Administrator@7PV3XG28ZW8YCKU MINGW64 /classes (master)
$ git pull
remote: Counting objects: 3371, done.
remote: Compressing objects: 100% (2490/2490), done.
remote: Total 3371 (delta 1076), reused 825 (delta 117)
Receiving objects: 100% (3371/3371), 162.15 MiB | 3.66 MiB/s, done.
Resolving deltas: 100% (1076/1076), done.
From https://gitee.com/ShrekerNil/Java0708Repo
* [new branch] master -> origin/master
There is no tracking information for the current branch.
Please specify which branch you want to merge with.
See git-pull(1) for details.
git pull <remote> <branch>
If you wish to set tracking information for this branch you can do so with:
git branch --set-upstream-to=origin/<branch> master
网友评论