How do I upgrade git submodules to the “gitfile” format?

Since version 1.7.8 git stores the repository information for a submodule inside the GIT_DIR of the containing repository. In the submodule .git now is a file with a “textual symlink” to the actual GIT_DIR (usuall something like: gitdir: ../../.git/modules/submodule-path).

It seems that git doesn’t update old submodules to fit this new standard.

What is the recommended way of upgrading the format? Do I just:

  1. move the GIT_DIR of my submodule into the GIT_DIR of my containing repository and
  2. write the gitfile by hand

I’m asking because I’ve broken to many things by improvising. I suppose this has no impact whatsoever on how remotes store the repositories?

Git Baby is a git and github fan, let's start git clone.