从Git服务器访问存储库文件

问题描述:

我必须访问存储在Git存储库中的某些文件,但看不到它们在存储库文件夹中的存储位置.

I have to access some files stored in a Git repository, but I don't see where they are stored inside the repository folder.

是否有一种特殊的方法可以访问从客户端推送的各种文件?

Is there a special way to access the various files pushed from the clients?

如果这是裸仓库,则不会在repo.git文件夹中找到这些文件.
参见"关于裸"存储库的所有信息":裸存储库没有工作树,用于推送到它(因为没有工作树与更新的分支保持同步)

If this is a bare repo, you wouldn't find those file in the repo.git folder.
See "all about "bare" repos": a bare repo has no working tree, and is used for pushing to it (since there is no working tree to keep in sync with an updated branch)

查看这些文件的最简单方法是克隆所说的裸仓库:

The easiest way to see those file is to clone said bare repo:

git clone /path/to/repo.git /path/to/repo