@Puteulanus 本地路径做 remote 仓库,刚刚实验了一下,可以 pull,但是 push 会报错,不知道是不是姿势不对。
“`shell
$ git push origin master
Enumerating objects: 5, done.
Counting objects: 100% (5/5), done.
Writing objects: 100% (3/3), 257 bytes | 257.00 KiB/s, done.
Total 3 (delta 0), reused 0 (delta 0)
remote: error: refusing to update checked out branch: refs/heads/master
remote: error: By default, updating the current branch in a non-bare repository
remote: is denied, because it will make the index and work tree inconsistent
remote: with what you pushed, and will require ‘git reset –hard’ to match
remote: the work tree to HEAD.
…
! [remote rejected] master -> master (branch is currently checked out)
error: failed to push some refs to ‘/Volumes/NONAME/test.git’
…
“`