git-annex/doc/submodules.mdwn
Joey Hess 20741b1eb4
Automatically convert direct mode repositories to v7 with adjusted unlocked branches
* Automatically convert direct mode repositories to v7 with adjusted
  unlocked branches and set annex.thin.
* init: When run on a crippled filesystem with --version=5,
  will error out, since version 7 is needed for adjusted unlocked branch.
* direct: This command always errors out as direct mode is no longer
  supported.
* indirect: This command has become a deprecated noop.
* proxy: This command is deprecated because it was only needed in direct
  mode. (But it continues to work.)

Also removed mentions of direct mode throughough the documentation.

I have not removed all the direct mode code yet.
2019-08-26 15:05:25 -04:00

22 lines
969 B
Markdown

[Git submodules](http://git-scm.com/book/en/v2/Git-Tools-Submodules) are
supported by git-annex since version 5.20150303.
Git normally makes a `.git` **file** in a
submodule, that points to the real git repository under `.git/modules/`.
This presents problems for git-annex. So, when used in a submodule,
git-annex will automatically replace the `.git` file with a symlink
pointing at the git repository. (When the filesystem doesn't support
symlinks, an adjusted unlocked branch is used, and submodules are
supported in that setup too.)
With that taken care of, git-annex should work ok in submodules. Although
this is a new and somewhat experimental feature.
The conversion of .git file to .git symlink mostly won't bother git.
Known problems:
* If you want to delete a whole submodule, `git rm submodule`
will refuse to delete it, complaining that the
submodule "uses a .git directory". Workaround: Use `rm -rf`
to delete the tree, and then `git commit`.