diff options
-rw-r--r-- | docs/internal-fs-layout.md | 24 |
1 files changed, 22 insertions, 2 deletions
diff --git a/docs/internal-fs-layout.md b/docs/internal-fs-layout.md index 53c42638..9cbdefb7 100644 --- a/docs/internal-fs-layout.md +++ b/docs/internal-fs-layout.md | |||
@@ -93,6 +93,23 @@ support, see the [manifest-format.md] file. | |||
93 | 93 | ||
94 | ### Project objects | 94 | ### Project objects |
95 | 95 | ||
96 | *** note | ||
97 | **Warning**: Please do not use repo's approach to projects/ & project-objects/ | ||
98 | layouts as a model for other tools to implement similar approaches. | ||
99 | It has a number of known downsides like: | ||
100 | * [Symlinks do not work well under Windows](./windows.md). | ||
101 | * Git sometimes replaces symlinks under .git/ with real files (under unknown | ||
102 | circumstances), and then the internal state gets out of sync, and data loss | ||
103 | may ensue. | ||
104 | * When sharing project-objects between multiple project checkouts, Git might | ||
105 | automatically run `gc` or `prune` which may lead to data loss or corruption | ||
106 | (since those operate on leaf projects and miss refs in other leaves). See | ||
107 | https://gerrit-review.googlesource.com/c/git-repo/+/254392 for more details. | ||
108 | |||
109 | Instead, you should use standard Git workflows like [git worktree] or | ||
110 | [gitsubmodules] with [superprojects]. | ||
111 | *** | ||
112 | |||
96 | * `project.list`: Tracking file used by `repo sync` to determine when projects | 113 | * `project.list`: Tracking file used by `repo sync` to determine when projects |
97 | are added or removed and need corresponding updates in the checkout. | 114 | are added or removed and need corresponding updates in the checkout. |
98 | * `projects/`: Bare checkouts of every project synced by the manifest. The | 115 | * `projects/`: Bare checkouts of every project synced by the manifest. The |
@@ -121,7 +138,7 @@ support, see the [manifest-format.md] file. | |||
121 | (i.e. the path on the remote server) with a `.git` suffix. This has the | 138 | (i.e. the path on the remote server) with a `.git` suffix. This has the |
122 | same advantages as the `project-objects/` layout above. | 139 | same advantages as the `project-objects/` layout above. |
123 | 140 | ||
124 | This is used when git worktrees are enabled. | 141 | This is used when [git worktree]'s are enabled. |
125 | 142 | ||
126 | ### Global settings | 143 | ### Global settings |
127 | 144 | ||
@@ -143,7 +160,7 @@ User controlled settings are initialized when running `repo init`. | |||
143 | | repo.reference | `--reference` | Reference repo client checkout | | 160 | | repo.reference | `--reference` | Reference repo client checkout | |
144 | | repo.submodules | `--submodules` | Sync git submodules | | 161 | | repo.submodules | `--submodules` | Sync git submodules | |
145 | | repo.superproject | `--use-superproject` | Sync [superproject] | | 162 | | repo.superproject | `--use-superproject` | Sync [superproject] | |
146 | | repo.worktree | `--worktree` | Use `git worktree` for checkouts | | 163 | | repo.worktree | `--worktree` | Use [git worktree] for checkouts | |
147 | | user.email | `--config-name` | User's e-mail address; Copied into `.git/config` when checking out a new project | | 164 | | user.email | `--config-name` | User's e-mail address; Copied into `.git/config` when checking out a new project | |
148 | | user.name | `--config-name` | User's name; Copied into `.git/config` when checking out a new project | | 165 | | user.name | `--config-name` | User's name; Copied into `.git/config` when checking out a new project | |
149 | 166 | ||
@@ -228,7 +245,10 @@ Repo will create & maintain a few files in the user's home directory. | |||
228 | 245 | ||
229 | 246 | ||
230 | [git-config]: https://git-scm.com/docs/git-config | 247 | [git-config]: https://git-scm.com/docs/git-config |
248 | [git worktree]: https://git-scm.com/docs/git-worktree | ||
249 | [gitsubmodules]: https://git-scm.com/docs/gitsubmodules | ||
231 | [manifest-format.md]: ./manifest-format.md | 250 | [manifest-format.md]: ./manifest-format.md |
232 | [local manifests]: ./manifest-format.md#Local-Manifests | 251 | [local manifests]: ./manifest-format.md#Local-Manifests |
252 | [superprojects]: https://en.wikibooks.org/wiki/Git/Submodules_and_Superprojects | ||
233 | [topic]: https://gerrit-review.googlesource.com/Documentation/intro-user.html#topics | 253 | [topic]: https://gerrit-review.googlesource.com/Documentation/intro-user.html#topics |
234 | [upload-notify]: https://gerrit-review.googlesource.com/Documentation/user-upload.html#notify | 254 | [upload-notify]: https://gerrit-review.googlesource.com/Documentation/user-upload.html#notify |