自定义 .git 文件夹的位置

初始化指定仓库

1
git init --separate-git-dir=.git文件路径 .

命令中指定仓库

1
git --git-dir=./git.nosync status

添加环境变量

1
GIT_DIR=/path/to/dot-git-directory

自定义 .git 文件夹的位置
https://blog.pangcy.cn/2023/04/13/服务器运维/Git/自定义 .git 文件夹的位置/
作者
子洋
发布于
2023年4月13日
许可协议