独習Git
リック・ウマリ
翔泳社
2016-02-26

の、11.5 さらなる探求の関連です。

git cloneでdepthオプションを使う場合でかつソースがローカルにある場合は、file://を先頭につける必要があります。
$ git clone --depth 1 math math.clone6
Cloning into 'math.clone6'...
warning: --depth is ignored in local clones; use file:// instead.
done.
mathがD:\git\mathにある場合でかつWindowsの場合、$ git clone --depth 1 file://D:\git\math math.clone7とうつとfatalになって失敗します。
$ git clone --depth 1 file://D:\git\math math.clone7
Cloning into 'math.clone7'...
fatal: 'D:gitmath' does not appear to be a git repository
fatal: Could not read from remote repository.
が消えているので、おそらく\をエスケープすればいけるだろうと思いました。
$ git clone --depth 1 file://D:\\git\\math math.clone7
Cloning into 'math.clone7'...
remote: Counting objects: 4, done.
remote: Compressing objects: 100% (2/2), done.
remote: Total 4 (delta 0), reused 0 (delta 0)
Receiving objects: 100% (4/4), done.
いけました。