$ git init foo
Initialized empty Git repository in .../foo/.git/
$ git clone "file://$PWD/foo" bar
Cloning into 'bar'...
But it's redundant:
$ git clone bar baz
Cloning into 'baz'...
If you example .git/config in either clone, you'll see that remote.origin.url is the absolute path of the source repo.
Note that you can share objects across clones on the same machine in various ways. See "--local", "--shared", and "--reference" in the git-clone man page. (GitHub uses this feature heavily. Or at least they did. I have no idea what their backend implementation is these days, but they must be doing some sort of copy-on-write CAS for forks.)
Note that you can share objects across clones on the same machine in various ways. See "--local", "--shared", and "--reference" in the git-clone man page. (GitHub uses this feature heavily. Or at least they did. I have no idea what their backend implementation is these days, but they must be doing some sort of copy-on-write CAS for forks.)