git rev-parse --is-inside-work-tree
git 工作树仓库(普通clone): true
git mirror仓库 和 git bare仓库: false
不是git仓库: fatal: not a git repository
相对的
git rev-parse --is-bare-repository
git 工作树仓库(普通clone): false
git mirror仓库 和 git bare仓库: true
不是git仓库: fatal: not a git repository