3 ms·
It's actually kind of mentioned at the end of the article: > Another approach is to use git’s --git-dir and --work-tree switches to move the git repository out
by glandium 9y ago
It's actually kind of mentioned at the end of the article:
> Another approach is to use git’s --git-dir and --work-tree switches to move the git repository out of the document root.
Yet another option is to make the htdocs directory a worktree of the git repository, which doesn't require passing flags around, or setting environment variables. Technically, this still leaves a .git, but it's only a file containing the actual location to the real .git directory.
https://git-scm.com/docs/git-worktree https://git-scm.com/docs/git-worktree
- paraknight 9y agoOr have a `www` directory and symlink it.