The page introduces concepts/terminologies in a pedagogically sound order, so if you read through the links to all the concepts in order, the likelihood of needing concepts you have never encountered before is minimized.
The page illustrates command options and their combinations/interactions with examples so that you can get a better feel for what each option does.
When you click a command's link, options appear on the left panel and examples appear on the right panel.
The page groups command options into intuitive categories for easy discovery, rather than arranging everything in a simple list in alphabetical order.
If the command you want to know is not illustrated here, please refer to the official documentation.
Documentation:
Reference:
types of links:
progress of features:
These concepts help you understand Git internals: how to configure Git, Git's object model, how to manage working trees and files within them. These are the basis of the source code management layer. (In theory, you can use those underlying commands to implement a revision control system yourself.)
These concepts help you understand Git interface.
refs: lightweight named pointers to an object or another ref.
Specify objects (especially commits) more easily in the presence of refs.
Init and sync repos.
Bundle files in the working tree into commits, move refs between commits.
View commit history and differences between commits.
Merge history and rewrite history.
https://git-scm.com/docs/git-ls-remote
List references in a remote repository.
https://git-scm.com/docs/git-init
Create an empty Git repository or reinitialize an existing one.
https://git-scm.com/docs/git-clone
Clone a repository into a new directory.
https://git-scm.com/docs/git-pull
Fetch from and integrate with another repository or a local branch.
https://git-scm.com/docs/git-push
Update remote refs along with associated objects.
https://git-scm.com/docs/git-ls-files
Show information about files in the index and the working tree.
https://git-scm.com/docs/git-diff
Show changes between commits, commit and working tree, etc.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git version
git version 2.55.0.windows.1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git version --build-options
git version 2.55.0.windows.1
cpu: x86_64
built from commit: bf5afdecc10478397d7059d07573630902fb2e2f
sizeof-long: 4
sizeof-size_t: 8
shell-path: D:/git-sdk-64-build-installers/usr/bin/sh
rust: disabled
feature: fsmonitor--daemon
gettext: enabled
libcurl: 8.21.0
OpenSSL: OpenSSL 3.5.7 9 Jun 2026
zlib: 1.3.2
SHA-1: SHA1_DC
SHA-256: SHA256_BLK
default-ref-format: files
default-hash: sha1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'section1.ke_y1' 'value1'
error: invalid key: section1.ke_y1
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'section2.ke-y2' 'value2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'section3.3key' 'value3'
error: invalid key: section3.3key
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'section4.-key4' 'value4'
error: invalid key: section4.-key4
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 's_ection5.key5' 'value5'
error: invalid key: s_ection5.key5
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 's-ection6.key6' 'value6'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' '7section.key7' 'value7'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' -- '-section81.key81' 'value81'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --end-of-options '-section82.key82' 'value82'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'section.'$'\x01\x02\x03\x04\x05\x06\x07\x08\x09''.key' 'value'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'section.'$'\x0B\x0C\x0D\x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\x1B\x1C\x1D\x1E\x1F\x20"\\\x7F''.key' 'value'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'section.subse.ction.key' 'value'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section2]\n
│ 2 \tke-y2 = value2\n
│ 3 [s-ection6]\n
│ 4 \tkey6 = value6\n
│ 5 [7section]\n
│ 6 \tkey7 = value7\n
│ 7 [-section81]\n
│ 8 \tkey81 = value81\n
│ 9 [-section82]\n
│ 10 \tkey82 = value82\n
│ 11 [section "\x01\x02\x03\x04\x05\x06\a\b\t"]\n
│ 12 \tkey = value\n
│ 13 [section "\v\f\r
│ 14 \x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\e\x1C\x1D\x1E\x1F \\"\\\\\x7F"]\n
│ 15 \tkey = value\n
│ 16 [section "subse.ction"]\n
│ 17 \tkey = value\n
│ 18
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config list --file='./config.txt' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 section2.ke-y2=value2\n
2 s-ection6.key6=value6\n
3 7section.key7=value7\n
4 -section81.key81=value81\n
5 -section82.key82=value82\n
6 section.\x01\x02\x03\x04\x05\x06\a\b\t.key=value\n
7 section.\v\f\r
8 \x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\e\x1C\x1D\x1E\x1F "\\\x7F.key=value\n
9 section.subse.ction.key=value\n
10
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ echo -n -e '[section "a\0b\0c"]
> key = value
> ' >>'./config.txt'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section2]\n
│ 2 \tke-y2 = value2\n
│ 3 [s-ection6]\n
│ 4 \tkey6 = value6\n
│ 5 [7section]\n
│ 6 \tkey7 = value7\n
│ 7 [-section81]\n
│ 8 \tkey81 = value81\n
│ 9 [-section82]\n
│ 10 \tkey82 = value82\n
│ 11 [section "\x01\x02\x03\x04\x05\x06\a\b\t"]\n
│ 12 \tkey = value\n
│ 13 [section "\v\f\r
│ 14 \x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\e\x1C\x1D\x1E\x1F \\"\\\\\x7F"]\n
│ 15 \tkey = value\n
│ 16 [section "subse.ction"]\n
│ 17 \tkey = value\n
│ 18 [section "a\0b\0c"]\n
│ 19 \tkey = value\n
│ 20
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config list --file='./config.txt' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 section2.ke-y2=value2\n
2 s-ection6.key6=value6\n
3 7section.key7=value7\n
4 -section81.key81=value81\n
5 -section82.key82=value82\n
6 section.\x01\x02\x03\x04\x05\x06\a\b\t.key=value\n
7 section.\v\f\r
8 \x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\e\x1C\x1D\x1E\x1F "\\\x7F.key=value\n
9 section.subse.ction.key=value\n
10 section.a=value\n
11
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ echo -n -e '[section "a\\nb\\nc"]
> key = value
> ' >>'./config.txt'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section2]\n
│ 2 \tke-y2 = value2\n
│ 3 [s-ection6]\n
│ 4 \tkey6 = value6\n
│ 5 [7section]\n
│ 6 \tkey7 = value7\n
│ 7 [-section81]\n
│ 8 \tkey81 = value81\n
│ 9 [-section82]\n
│ 10 \tkey82 = value82\n
│ 11 [section "\x01\x02\x03\x04\x05\x06\a\b\t"]\n
│ 12 \tkey = value\n
│ 13 [section "\v\f\r
│ 14 \x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\e\x1C\x1D\x1E\x1F \\"\\\\\x7F"]\n
│ 15 \tkey = value\n
│ 16 [section "subse.ction"]\n
│ 17 \tkey = value\n
│ 18 [section "a\0b\0c"]\n
│ 19 \tkey = value\n
│ 20 [section "a\\nb\\nc"]\n
│ 21 \tkey = value\n
│ 22
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config list --file='./config.txt' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 section2.ke-y2=value2\n
2 s-ection6.key6=value6\n
3 7section.key7=value7\n
4 -section81.key81=value81\n
5 -section82.key82=value82\n
6 section.\x01\x02\x03\x04\x05\x06\a\b\t.key=value\n
7 section.\v\f\r
8 \x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\e\x1C\x1D\x1E\x1F "\\\x7F.key=value\n
9 section.subse.ction.key=value\n
10 section.a=value\n
11 section.anbnc.key=value\n
12
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ echo -n -e '[section "a\nb\nc"]
> key = value
> ' >>'./config.txt'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section2]\n
│ 2 \tke-y2 = value2\n
│ 3 [s-ection6]\n
│ 4 \tkey6 = value6\n
│ 5 [7section]\n
│ 6 \tkey7 = value7\n
│ 7 [-section81]\n
│ 8 \tkey81 = value81\n
│ 9 [-section82]\n
│ 10 \tkey82 = value82\n
│ 11 [section "\x01\x02\x03\x04\x05\x06\a\b\t"]\n
│ 12 \tkey = value\n
│ 13 [section "\v\f\r
│ 14 \x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\e\x1C\x1D\x1E\x1F \\"\\\\\x7F"]\n
│ 15 \tkey = value\n
│ 16 [section "subse.ction"]\n
│ 17 \tkey = value\n
│ 18 [section "a\0b\0c"]\n
│ 19 \tkey = value\n
│ 20 [section "a\\nb\\nc"]\n
│ 21 \tkey = value\n
│ 22 [section "a\n
│ 23 b\n
│ 24 c"]\n
│ 25 \tkey = value\n
│ 26
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config list --file='./config.txt' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
fatal: bad config line 21 in file ./config.txt
1 section2.ke-y2=value2\n
2 s-ection6.key6=value6\n
3 7section.key7=value7\n
4 -section81.key81=value81\n
5 -section82.key82=value82\n
6 section.\x01\x02\x03\x04\x05\x06\a\b\t.key=value\n
7 section.\v\f\r
8 \x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\e\x1C\x1D\x1E\x1F "\\\x7F.key=value\n
9 section.subse.ction.key=value\n
10 section.a=value\n
11 section.anbnc.key=value\n
12
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'section.key'
error: missing value to set to the variable 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=129 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'section.key0' ''
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'section.key1' 'value'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'section.key2' ' val
> ue '
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'section.key3' $'\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0A\x0B\x0C\x0D\x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\x1B\x1C\x1D\x1E\x1F\x20"\\\x7F'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section]\n
│ 2 \tkey0 = \n
│ 3 \tkey1 = value\n
│ 4 \tkey2 = " val\\nue "\n
│ 5 \tkey3 = "\x01\x02\x03\x04\x05\x06\a\b\\t\\n\v\f\r
│ 6 \x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\e\x1C\x1D\x1E\x1F \\"\\\\\x7F"\n
│ 7
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config list --file='./config.txt' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 section.key0=\n
2 section.key1=value\n
3 section.key2= val\n
4 ue \n
5 section.key3=\x01\x02\x03\x04\x05\x06\a\b\t\n
6 \v\f\r
7 \x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\e\x1C\x1D\x1E\x1F "\\\x7F\n
8
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ echo -n -e '[section]
> key = v\0al\0ue
> ' >>'./config.txt'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section]\n
│ 2 \tkey0 = \n
│ 3 \tkey1 = value\n
│ 4 \tkey2 = " val\\nue "\n
│ 5 \tkey3 = "\x01\x02\x03\x04\x05\x06\a\b\\t\\n\v\f\r
│ 6 \x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\e\x1C\x1D\x1E\x1F \\"\\\\\x7F"\n
│ 7 [section]\n
│ 8 \tkey = v\0al\0ue\n
│ 9
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config list --file='./config.txt' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 section.key0=\n
2 section.key1=value\n
3 section.key2= val\n
4 ue \n
5 section.key3=\x01\x02\x03\x04\x05\x06\a\b\t\n
6 \v\f\r
7 \x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\e\x1C\x1D\x1E\x1F "\\\x7F\n
8 section.key=v\n
9
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ echo -n -e '[section]
> key = v\\0al\\0ue
> ' >>'./config.txt'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section]\n
│ 2 \tkey0 = \n
│ 3 \tkey1 = value\n
│ 4 \tkey2 = " val\\nue "\n
│ 5 \tkey3 = "\x01\x02\x03\x04\x05\x06\a\b\\t\\n\v\f\r
│ 6 \x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\e\x1C\x1D\x1E\x1F \\"\\\\\x7F"\n
│ 7 [section]\n
│ 8 \tkey = v\0al\0ue\n
│ 9 [section]\n
│ 10 \tkey = v\\0al\\0ue\n
│ 11
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config list --file='./config.txt' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
fatal: bad config line 9 in file ./config.txt
1 section.key0=\n
2 section.key1=value\n
3 section.key2= val\n
4 ue \n
5 section.key3=\x01\x02\x03\x04\x05\x06\a\b\t\n
6 \v\f\r
7 \x0E\x0F\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1A\e\x1C\x1D\x1E\x1F "\\\x7F\n
8 section.key=v\n
9
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section]\n
│ 2 \tkey = value52\n
│ 3 \tkey = value62\n
│ 4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value7 -c section.key=value8 config list --show-origin --show-scope
system file:C:/Program Files/Git/etc/gitconfig diff.astextplain.textconv=astextplain
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.clean=git-lfs clean -- %f
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.smudge=git-lfs smudge -- %f
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.process=git-lfs filter-process
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.required=true
system file:C:/Program Files/Git/etc/gitconfig http.sslbackend=openssl
system file:C:/Program Files/Git/etc/gitconfig http.sslcainfo=C:/Program Files/Git/mingw64/etc/ssl/certs/ca-bundle.crt
system file:C:/Program Files/Git/etc/gitconfig core.autocrlf=true
system file:C:/Program Files/Git/etc/gitconfig core.fscache=true
system file:C:/Program Files/Git/etc/gitconfig core.symlinks=true
system file:C:/Program Files/Git/etc/gitconfig core.editor="C:\\Program Files\\Notepad++\\notepad++.exe" -multiInst -notabbar -nosession -noPlugin
system file:C:/Program Files/Git/etc/gitconfig pull.ff=only
system file:C:/Program Files/Git/etc/gitconfig credential.helper=manager
system file:C:/Program Files/Git/etc/gitconfig credential.https://dev.azure.com.usehttppath=true
system file:C:/Program Files/Git/etc/gitconfig init.defaultbranch=master
system file:C:/Program Files/Git/etc/gitconfig section.key=value1
system file:C:/Program Files/Git/etc/gitconfig section.key=value2
global file:C:/Users/jhcar/.gitconfig user.name=Han Jiang
global file:C:/Users/jhcar/.gitconfig user.email=jhcarl0814@gmail.com
global file:C:/Users/jhcar/.gitconfig alias.lg=log --graph --abbrev-commit --decorate=full --date=format:'%Y-%m-%d %H:%M' --format=tformat:'%C(bold green)%h%C(reset) - %C(bold blue)%ad (%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(auto)%d%C(reset)'
global file:C:/Users/jhcar/.gitconfig gui.encoding=utf-8
global file:C:/Users/jhcar/.gitconfig gui.tabsize=4
global file:C:/Users/jhcar/.gitconfig diff.tool=kdiff3
global file:C:/Users/jhcar/.gitconfig difftool.kdiff3.path=C:/Program Files/KDiff3/bin/kdiff3.exe
global file:C:/Users/jhcar/.gitconfig difftool.kdiff3.trustexitcode=false
global file:C:/Users/jhcar/.gitconfig filter.lfs.clean=git-lfs clean -- %f
global file:C:/Users/jhcar/.gitconfig filter.lfs.smudge=git-lfs smudge -- %f
global file:C:/Users/jhcar/.gitconfig filter.lfs.process=git-lfs filter-process
global file:C:/Users/jhcar/.gitconfig filter.lfs.required=true
global file:C:/Users/jhcar/.gitconfig section.key=value3
global file:C:/Users/jhcar/.gitconfig section.key=value4
command command line: section.key=value7
command command line: section.key=value8
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value7 -c section.key=value8 config get --show-origin --show-scope --all 'section.key'
system file:C:/Program Files/Git/etc/gitconfig value1
system file:C:/Program Files/Git/etc/gitconfig value2
global file:C:/Users/jhcar/.gitconfig value3
global file:C:/Users/jhcar/.gitconfig value4
command command line: value7
command command line: value8
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config list --system --show-origin --show-scope
system file:C:/Program Files/Git/etc/gitconfig diff.astextplain.textconv=astextplain
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.clean=git-lfs clean -- %f
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.smudge=git-lfs smudge -- %f
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.process=git-lfs filter-process
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.required=true
system file:C:/Program Files/Git/etc/gitconfig http.sslbackend=openssl
system file:C:/Program Files/Git/etc/gitconfig http.sslcainfo=C:/Program Files/Git/mingw64/etc/ssl/certs/ca-bundle.crt
system file:C:/Program Files/Git/etc/gitconfig core.autocrlf=true
system file:C:/Program Files/Git/etc/gitconfig core.fscache=true
system file:C:/Program Files/Git/etc/gitconfig core.symlinks=true
system file:C:/Program Files/Git/etc/gitconfig core.editor="C:\\Program Files\\Notepad++\\notepad++.exe" -multiInst -notabbar -nosession -noPlugin
system file:C:/Program Files/Git/etc/gitconfig pull.ff=only
system file:C:/Program Files/Git/etc/gitconfig credential.helper=manager
system file:C:/Program Files/Git/etc/gitconfig credential.https://dev.azure.com.usehttppath=true
system file:C:/Program Files/Git/etc/gitconfig init.defaultbranch=master
system file:C:/Program Files/Git/etc/gitconfig section.key=value1
system file:C:/Program Files/Git/etc/gitconfig section.key=value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --system --show-origin --show-scope --all 'section.key'
system file:C:/Program Files/Git/etc/gitconfig value1
system file:C:/Program Files/Git/etc/gitconfig value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config list --global --show-origin --show-scope
global file:C:/Users/jhcar/.gitconfig user.name=Han Jiang
global file:C:/Users/jhcar/.gitconfig user.email=jhcarl0814@gmail.com
global file:C:/Users/jhcar/.gitconfig alias.lg=log --graph --abbrev-commit --decorate=full --date=format:'%Y-%m-%d %H:%M' --format=tformat:'%C(bold green)%h%C(reset) - %C(bold blue)%ad (%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(auto)%d%C(reset)'
global file:C:/Users/jhcar/.gitconfig gui.encoding=utf-8
global file:C:/Users/jhcar/.gitconfig gui.tabsize=4
global file:C:/Users/jhcar/.gitconfig diff.tool=kdiff3
global file:C:/Users/jhcar/.gitconfig difftool.kdiff3.path=C:/Program Files/KDiff3/bin/kdiff3.exe
global file:C:/Users/jhcar/.gitconfig difftool.kdiff3.trustexitcode=false
global file:C:/Users/jhcar/.gitconfig filter.lfs.clean=git-lfs clean -- %f
global file:C:/Users/jhcar/.gitconfig filter.lfs.smudge=git-lfs smudge -- %f
global file:C:/Users/jhcar/.gitconfig filter.lfs.process=git-lfs filter-process
global file:C:/Users/jhcar/.gitconfig filter.lfs.required=true
global file:C:/Users/jhcar/.gitconfig section.key=value3
global file:C:/Users/jhcar/.gitconfig section.key=value4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --global --show-origin --show-scope --all 'section.key'
global file:C:/Users/jhcar/.gitconfig value3
global file:C:/Users/jhcar/.gitconfig value4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config list --file='./config.txt' --show-origin --show-scope
command file:./config.txt section.key=value52
command file:./config.txt section.key=value62
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt value52
command file:./config.txt value62
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value7 -c section.key=value8 config list --show-origin --show-scope <<'EOF'
> [section]
> key = value51
> key = value61
> EOF
system file:C:/Program Files/Git/etc/gitconfig diff.astextplain.textconv=astextplain
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.clean=git-lfs clean -- %f
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.smudge=git-lfs smudge -- %f
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.process=git-lfs filter-process
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.required=true
system file:C:/Program Files/Git/etc/gitconfig http.sslbackend=openssl
system file:C:/Program Files/Git/etc/gitconfig http.sslcainfo=C:/Program Files/Git/mingw64/etc/ssl/certs/ca-bundle.crt
system file:C:/Program Files/Git/etc/gitconfig core.autocrlf=true
system file:C:/Program Files/Git/etc/gitconfig core.fscache=true
system file:C:/Program Files/Git/etc/gitconfig core.symlinks=true
system file:C:/Program Files/Git/etc/gitconfig core.editor="C:\\Program Files\\Notepad++\\notepad++.exe" -multiInst -notabbar -nosession -noPlugin
system file:C:/Program Files/Git/etc/gitconfig pull.ff=only
system file:C:/Program Files/Git/etc/gitconfig credential.helper=manager
system file:C:/Program Files/Git/etc/gitconfig credential.https://dev.azure.com.usehttppath=true
system file:C:/Program Files/Git/etc/gitconfig init.defaultbranch=master
system file:C:/Program Files/Git/etc/gitconfig section.key=value1
system file:C:/Program Files/Git/etc/gitconfig section.key=value2
global file:C:/Users/jhcar/.gitconfig user.name=Han Jiang
global file:C:/Users/jhcar/.gitconfig user.email=jhcarl0814@gmail.com
global file:C:/Users/jhcar/.gitconfig alias.lg=log --graph --abbrev-commit --decorate=full --date=format:'%Y-%m-%d %H:%M' --format=tformat:'%C(bold green)%h%C(reset) - %C(bold blue)%ad (%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(auto)%d%C(reset)'
global file:C:/Users/jhcar/.gitconfig gui.encoding=utf-8
global file:C:/Users/jhcar/.gitconfig gui.tabsize=4
global file:C:/Users/jhcar/.gitconfig diff.tool=kdiff3
global file:C:/Users/jhcar/.gitconfig difftool.kdiff3.path=C:/Program Files/KDiff3/bin/kdiff3.exe
global file:C:/Users/jhcar/.gitconfig difftool.kdiff3.trustexitcode=false
global file:C:/Users/jhcar/.gitconfig filter.lfs.clean=git-lfs clean -- %f
global file:C:/Users/jhcar/.gitconfig filter.lfs.smudge=git-lfs smudge -- %f
global file:C:/Users/jhcar/.gitconfig filter.lfs.process=git-lfs filter-process
global file:C:/Users/jhcar/.gitconfig filter.lfs.required=true
global file:C:/Users/jhcar/.gitconfig section.key=value3
global file:C:/Users/jhcar/.gitconfig section.key=value4
command command line: section.key=value7
command command line: section.key=value8
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value7 -c section.key=value8 config get --show-origin --show-scope --all 'section.key' <<'EOF'
> [section]
> key = value51
> key = value61
> EOF
system file:C:/Program Files/Git/etc/gitconfig value1
system file:C:/Program Files/Git/etc/gitconfig value2
global file:C:/Users/jhcar/.gitconfig value3
global file:C:/Users/jhcar/.gitconfig value4
command command line: value7
command command line: value8
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config list --file='-' --show-origin --show-scope <<'EOF'
> [section]
> key = value51
> key = value61
> EOF
command standard input: section.key=value51
command standard input: section.key=value61
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='-' --show-origin --show-scope --all 'section.key' <<'EOF'
> [section]
> key = value51
> key = value61
> EOF
command standard input: value51
command standard input: value61
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config list --file='./config.txt' --file='-' --show-origin --show-scope <<'EOF'
> [section]
> key = value51
> key = value61
> EOF
command standard input: section.key=value51
command standard input: section.key=value61
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --file='-' --show-origin --show-scope --all 'section.key' <<'EOF'
> [section]
> key = value51
> key = value61
> EOF
command standard input: value51
command standard input: value61
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config list --file='-' --file='./config.txt' --show-origin --show-scope <<'EOF'
> [section]
> key = value51
> key = value61
> EOF
command file:./config.txt section.key=value52
command file:./config.txt section.key=value62
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='-' --file='./config.txt' --show-origin --show-scope --all 'section.key' <<'EOF'
> [section]
> key = value51
> key = value61
> EOF
command file:./config.txt value52
command file:./config.txt value62
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value7 -c section.key=value8 config list --system --global --file='-' --show-origin --show-scope <<'EOF'
> [section]
> key = value51
> key = value61
> EOF
error: only one config file at a time
jhcarl0814@jhcarl0814 MINGW64 $?=129 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value7 -c section.key=value8 config get --system --global --file='-' --show-origin --show-scope --all 'section.key' <<'EOF'
> [section]
> key = value51
> key = value61
> EOF
error: only one config file at a time
jhcarl0814@jhcarl0814 MINGW64 $?=129 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value7 -c section.key=value8 config list --system --global --file='./config.txt' --show-origin --show-scope
error: only one config file at a time
jhcarl0814@jhcarl0814 MINGW64 $?=129 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value7 -c section.key=value8 config get --system --global --file='./config.txt' --show-origin --show-scope --all 'section.key'
error: only one config file at a time
jhcarl0814@jhcarl0814 MINGW64 $?=129 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --local --all 'section.key' 'value5'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --local --append 'section.key' 'value6'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c section.key=value9 -c section.key=value10 config list --show-scope --show-origin
system file:C:/Program Files/Git/etc/gitconfig diff.astextplain.textconv=astextplain
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.clean=git-lfs clean -- %f
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.smudge=git-lfs smudge -- %f
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.process=git-lfs filter-process
system file:C:/Program Files/Git/etc/gitconfig filter.lfs.required=true
system file:C:/Program Files/Git/etc/gitconfig http.sslbackend=openssl
system file:C:/Program Files/Git/etc/gitconfig http.sslcainfo=C:/Program Files/Git/mingw64/etc/ssl/certs/ca-bundle.crt
system file:C:/Program Files/Git/etc/gitconfig core.autocrlf=true
system file:C:/Program Files/Git/etc/gitconfig core.fscache=true
system file:C:/Program Files/Git/etc/gitconfig core.symlinks=true
system file:C:/Program Files/Git/etc/gitconfig core.editor="C:\\Program Files\\Notepad++\\notepad++.exe" -multiInst -notabbar -nosession -noPlugin
system file:C:/Program Files/Git/etc/gitconfig pull.ff=only
system file:C:/Program Files/Git/etc/gitconfig credential.helper=manager
system file:C:/Program Files/Git/etc/gitconfig credential.https://dev.azure.com.usehttppath=true
system file:C:/Program Files/Git/etc/gitconfig init.defaultbranch=master
global file:C:/Users/jhcar/.gitconfig user.name=Han Jiang
global file:C:/Users/jhcar/.gitconfig user.email=jhcarl0814@gmail.com
global file:C:/Users/jhcar/.gitconfig alias.lg=log --graph --abbrev-commit --decorate=full --date=format:'%Y-%m-%d %H:%M' --format=tformat:'%C(bold green)%h%C(reset) - %C(bold blue)%ad (%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(auto)%d%C(reset)'
global file:C:/Users/jhcar/.gitconfig gui.encoding=utf-8
global file:C:/Users/jhcar/.gitconfig gui.tabsize=4
global file:C:/Users/jhcar/.gitconfig diff.tool=kdiff3
global file:C:/Users/jhcar/.gitconfig difftool.kdiff3.path=C:/Program Files/KDiff3/bin/kdiff3.exe
global file:C:/Users/jhcar/.gitconfig difftool.kdiff3.trustexitcode=false
global file:C:/Users/jhcar/.gitconfig filter.lfs.clean=git-lfs clean -- %f
global file:C:/Users/jhcar/.gitconfig filter.lfs.smudge=git-lfs smudge -- %f
global file:C:/Users/jhcar/.gitconfig filter.lfs.process=git-lfs filter-process
global file:C:/Users/jhcar/.gitconfig filter.lfs.required=true
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config section.key=value5
local file:.git/config section.key=value6
command command line: section.key=value9
command command line: section.key=value10
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c section.key=value9 -c section.key=value10 config get --show-origin --show-scope --all 'section.key'
local file:.git/config value5
local file:.git/config value6
command command line: value9
command command line: value10
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config section.key=value5
local file:.git/config section.key=value6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --local --show-origin --show-scope --all 'section.key'
local file:.git/config value5
local file:.git/config value6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config list --worktree --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config section.key=value5
local file:.git/config section.key=value6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --worktree --show-origin --show-scope --all 'section.key'
local file:.git/config value5
local file:.git/config value6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1'
No possible source branch, inferring '--orphan'
Preparing worktree (new branch 'worktree1')
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config --local extensions.worktreeConfig true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config section.key=value5
local file:.git/config section.key=value6
local file:.git/config extensions.worktreeconfig=true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --local --show-origin --show-scope --all 'section.key'
local file:.git/config value5
local file:.git/config value6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config list --worktree --show-origin --show-scope
fatal: unable to read config file '.git/config.worktree': No such file or directory
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --worktree --show-origin --show-scope --all 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config list --local --show-origin --show-scope
local file:C:/Program Files/Git/test_git/repo/.git/config core.repositoryformatversion=0
local file:C:/Program Files/Git/test_git/repo/.git/config core.filemode=false
local file:C:/Program Files/Git/test_git/repo/.git/config core.bare=false
local file:C:/Program Files/Git/test_git/repo/.git/config core.logallrefupdates=true
local file:C:/Program Files/Git/test_git/repo/.git/config core.ignorecase=true
local file:C:/Program Files/Git/test_git/repo/.git/config section.key=value5
local file:C:/Program Files/Git/test_git/repo/.git/config section.key=value6
local file:C:/Program Files/Git/test_git/repo/.git/config extensions.worktreeconfig=true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --local --show-origin --show-scope --all 'section.key'
local file:C:/Program Files/Git/test_git/repo/.git/config value5
local file:C:/Program Files/Git/test_git/repo/.git/config value6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config list --worktree --show-origin --show-scope
fatal: unable to read config file 'C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree': No such file or directory
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --worktree --show-origin --show-scope --all 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --worktree --all 'section.key' 'value71'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --worktree --append 'section.key' 'value81'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config list --worktree --show-origin --show-scope
local file:.git/config.worktree section.key=value71
local file:.git/config.worktree section.key=value81
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --worktree --show-origin --show-scope --all 'section.key'
local file:.git/config.worktree value71
local file:.git/config.worktree value81
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config list --worktree --show-origin --show-scope
fatal: unable to read config file 'C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree': No such file or directory
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --worktree --show-origin --show-scope --all 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config set --worktree --all 'section.key' 'value72'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config set --worktree --append 'section.key' 'value82'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config list --worktree --show-origin --show-scope
local file:.git/config.worktree section.key=value71
local file:.git/config.worktree section.key=value81
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --worktree --show-origin --show-scope --all 'section.key'
local file:.git/config.worktree value71
local file:.git/config.worktree value81
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config list --worktree --show-origin --show-scope
local file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree section.key=value72
local file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree section.key=value82
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --worktree --show-origin --show-scope --all 'section.key'
local file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree value72
local file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree value82
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git config list --show-origin --show-scope | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 system\tfile:C:/Program Files/Git/etc/gitconfig\tdiff.astextplain.textconv=astextplain\n
2 system\tfile:C:/Program Files/Git/etc/gitconfig\tfilter.lfs.clean=git-lfs clean -- %f\n
3 system\tfile:C:/Program Files/Git/etc/gitconfig\tfilter.lfs.smudge=git-lfs smudge -- %f\n
4 system\tfile:C:/Program Files/Git/etc/gitconfig\tfilter.lfs.process=git-lfs filter-process\n
5 system\tfile:C:/Program Files/Git/etc/gitconfig\tfilter.lfs.required=true\n
6 system\tfile:C:/Program Files/Git/etc/gitconfig\thttp.sslbackend=openssl\n
7 system\tfile:C:/Program Files/Git/etc/gitconfig\thttp.sslcainfo=C:/Program Files/Git/mingw64/etc/ssl/certs/ca-bundle.crt\n
8 system\tfile:C:/Program Files/Git/etc/gitconfig\tcore.autocrlf=true\n
9 system\tfile:C:/Program Files/Git/etc/gitconfig\tcore.fscache=true\n
10 system\tfile:C:/Program Files/Git/etc/gitconfig\tcore.symlinks=true\n
11 system\tfile:C:/Program Files/Git/etc/gitconfig\tcore.editor="C:\\\\Program Files\\\\Notepad++\\\\notepad++.exe" -multiInst -notabbar -nosession -noPlugin\n
12 system\tfile:C:/Program Files/Git/etc/gitconfig\tpull.ff=only\n
13 system\tfile:C:/Program Files/Git/etc/gitconfig\tcredential.helper=manager\n
14 system\tfile:C:/Program Files/Git/etc/gitconfig\tcredential.https://dev.azure.com.usehttppath=true\n
15 system\tfile:C:/Program Files/Git/etc/gitconfig\tinit.defaultbranch=master\n
16 system\tfile:C:/Program Files/Git/etc/gitconfig\tsection.key=value1\n
17 system\tfile:C:/Program Files/Git/etc/gitconfig\tsection.key=value2\n
18 global\tfile:C:/Users/jhcar/.gitconfig\tuser.name=Han Jiang\n
19 global\tfile:C:/Users/jhcar/.gitconfig\tuser.email=jhcarl0814@gmail.com\n
20 global\tfile:C:/Users/jhcar/.gitconfig\talias.lg=log --graph --abbrev-commit --decorate=full --date=format:'%Y-%m-%d %H:%M' --format=tformat:'%C(bold green)%h%C(reset) - %C(bold blue)%ad (%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(auto)%d%C(reset)'\n
21 global\tfile:C:/Users/jhcar/.gitconfig\tgui.encoding=utf-8\n
22 global\tfile:C:/Users/jhcar/.gitconfig\tgui.tabsize=4\n
23 global\tfile:C:/Users/jhcar/.gitconfig\tdiff.tool=kdiff3\n
24 global\tfile:C:/Users/jhcar/.gitconfig\tdifftool.kdiff3.path=C:/Program Files/KDiff3/bin/kdiff3.exe\n
25 global\tfile:C:/Users/jhcar/.gitconfig\tdifftool.kdiff3.trustexitcode=false\n
26 global\tfile:C:/Users/jhcar/.gitconfig\tfilter.lfs.clean=git-lfs clean -- %f\n
27 global\tfile:C:/Users/jhcar/.gitconfig\tfilter.lfs.smudge=git-lfs smudge -- %f\n
28 global\tfile:C:/Users/jhcar/.gitconfig\tfilter.lfs.process=git-lfs filter-process\n
29 global\tfile:C:/Users/jhcar/.gitconfig\tfilter.lfs.required=true\n
30 global\tfile:C:/Users/jhcar/.gitconfig\tsection.key=value3\n
31 global\tfile:C:/Users/jhcar/.gitconfig\tsection.key=value4\n
32
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git config list --show-origin --show-scope --null | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 system\0file:C:/Program Files/Git/etc/gitconfig\0diff.astextplain.textconv\n
2 astextplain\0system\0file:C:/Program Files/Git/etc/gitconfig\0filter.lfs.clean\n
3 git-lfs clean -- %f\0system\0file:C:/Program Files/Git/etc/gitconfig\0filter.lfs.smudge\n
4 git-lfs smudge -- %f\0system\0file:C:/Program Files/Git/etc/gitconfig\0filter.lfs.process\n
5 git-lfs filter-process\0system\0file:C:/Program Files/Git/etc/gitconfig\0filter.lfs.required\n
6 true\0system\0file:C:/Program Files/Git/etc/gitconfig\0http.sslbackend\n
7 openssl\0system\0file:C:/Program Files/Git/etc/gitconfig\0http.sslcainfo\n
8 C:/Program Files/Git/mingw64/etc/ssl/certs/ca-bundle.crt\0system\0file:C:/Program Files/Git/etc/gitconfig\0core.autocrlf\n
9 true\0system\0file:C:/Program Files/Git/etc/gitconfig\0core.fscache\n
10 true\0system\0file:C:/Program Files/Git/etc/gitconfig\0core.symlinks\n
11 true\0system\0file:C:/Program Files/Git/etc/gitconfig\0core.editor\n
12 "C:\\\\Program Files\\\\Notepad++\\\\notepad++.exe" -multiInst -notabbar -nosession -noPlugin\0system\0file:C:/Program Files/Git/etc/gitconfig\0pull.ff\n
13 only\0system\0file:C:/Program Files/Git/etc/gitconfig\0credential.helper\n
14 manager\0system\0file:C:/Program Files/Git/etc/gitconfig\0credential.https://dev.azure.com.usehttppath\n
15 true\0system\0file:C:/Program Files/Git/etc/gitconfig\0init.defaultbranch\n
16 master\0system\0file:C:/Program Files/Git/etc/gitconfig\0section.key\n
17 value1\0system\0file:C:/Program Files/Git/etc/gitconfig\0section.key\n
18 value2\0global\0file:C:/Users/jhcar/.gitconfig\0user.name\n
19 Han Jiang\0global\0file:C:/Users/jhcar/.gitconfig\0user.email\n
20 jhcarl0814@gmail.com\0global\0file:C:/Users/jhcar/.gitconfig\0alias.lg\n
21 log --graph --abbrev-commit --decorate=full --date=format:'%Y-%m-%d %H:%M' --format=tformat:'%C(bold green)%h%C(reset) - %C(bold blue)%ad (%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(auto)%d%C(reset)'\0global\0file:C:/Users/jhcar/.gitconfig\0gui.encoding\n
22 utf-8\0global\0file:C:/Users/jhcar/.gitconfig\0gui.tabsize\n
23 4\0global\0file:C:/Users/jhcar/.gitconfig\0diff.tool\n
24 kdiff3\0global\0file:C:/Users/jhcar/.gitconfig\0difftool.kdiff3.path\n
25 C:/Program Files/KDiff3/bin/kdiff3.exe\0global\0file:C:/Users/jhcar/.gitconfig\0difftool.kdiff3.trustexitcode\n
26 false\0global\0file:C:/Users/jhcar/.gitconfig\0filter.lfs.clean\n
27 git-lfs clean -- %f\0global\0file:C:/Users/jhcar/.gitconfig\0filter.lfs.smudge\n
28 git-lfs smudge -- %f\0global\0file:C:/Users/jhcar/.gitconfig\0filter.lfs.process\n
29 git-lfs filter-process\0global\0file:C:/Users/jhcar/.gitconfig\0filter.lfs.required\n
30 true\0global\0file:C:/Users/jhcar/.gitconfig\0section.key\n
31 value3\0global\0file:C:/Users/jhcar/.gitconfig\0section.key\n
32 value4\0
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git config list --show-origin --show-scope --name-only | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 system\tfile:C:/Program Files/Git/etc/gitconfig\tdiff.astextplain.textconv\n
2 system\tfile:C:/Program Files/Git/etc/gitconfig\tfilter.lfs.clean\n
3 system\tfile:C:/Program Files/Git/etc/gitconfig\tfilter.lfs.smudge\n
4 system\tfile:C:/Program Files/Git/etc/gitconfig\tfilter.lfs.process\n
5 system\tfile:C:/Program Files/Git/etc/gitconfig\tfilter.lfs.required\n
6 system\tfile:C:/Program Files/Git/etc/gitconfig\thttp.sslbackend\n
7 system\tfile:C:/Program Files/Git/etc/gitconfig\thttp.sslcainfo\n
8 system\tfile:C:/Program Files/Git/etc/gitconfig\tcore.autocrlf\n
9 system\tfile:C:/Program Files/Git/etc/gitconfig\tcore.fscache\n
10 system\tfile:C:/Program Files/Git/etc/gitconfig\tcore.symlinks\n
11 system\tfile:C:/Program Files/Git/etc/gitconfig\tcore.editor\n
12 system\tfile:C:/Program Files/Git/etc/gitconfig\tpull.ff\n
13 system\tfile:C:/Program Files/Git/etc/gitconfig\tcredential.helper\n
14 system\tfile:C:/Program Files/Git/etc/gitconfig\tcredential.https://dev.azure.com.usehttppath\n
15 system\tfile:C:/Program Files/Git/etc/gitconfig\tinit.defaultbranch\n
16 system\tfile:C:/Program Files/Git/etc/gitconfig\tsection.key\n
17 system\tfile:C:/Program Files/Git/etc/gitconfig\tsection.key\n
18 global\tfile:C:/Users/jhcar/.gitconfig\tuser.name\n
19 global\tfile:C:/Users/jhcar/.gitconfig\tuser.email\n
20 global\tfile:C:/Users/jhcar/.gitconfig\talias.lg\n
21 global\tfile:C:/Users/jhcar/.gitconfig\tgui.encoding\n
22 global\tfile:C:/Users/jhcar/.gitconfig\tgui.tabsize\n
23 global\tfile:C:/Users/jhcar/.gitconfig\tdiff.tool\n
24 global\tfile:C:/Users/jhcar/.gitconfig\tdifftool.kdiff3.path\n
25 global\tfile:C:/Users/jhcar/.gitconfig\tdifftool.kdiff3.trustexitcode\n
26 global\tfile:C:/Users/jhcar/.gitconfig\tfilter.lfs.clean\n
27 global\tfile:C:/Users/jhcar/.gitconfig\tfilter.lfs.smudge\n
28 global\tfile:C:/Users/jhcar/.gitconfig\tfilter.lfs.process\n
29 global\tfile:C:/Users/jhcar/.gitconfig\tfilter.lfs.required\n
30 global\tfile:C:/Users/jhcar/.gitconfig\tsection.key\n
31 global\tfile:C:/Users/jhcar/.gitconfig\tsection.key\n
32
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git config list --show-origin --show-scope --null --name-only | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 system\0file:C:/Program Files/Git/etc/gitconfig\0diff.astextplain.textconv\0system\0file:C:/Program Files/Git/etc/gitconfig\0filter.lfs.clean\0system\0file:C:/Program Files/Git/etc/gitconfig\0filter.lfs.smudge\0system\0file:C:/Program Files/Git/etc/gitconfig\0filter.lfs.process\0system\0file:C:/Program Files/Git/etc/gitconfig\0filter.lfs.required\0system\0file:C:/Program Files/Git/etc/gitconfig\0http.sslbackend\0system\0file:C:/Program Files/Git/etc/gitconfig\0http.sslcainfo\0system\0file:C:/Program Files/Git/etc/gitconfig\0core.autocrlf\0system\0file:C:/Program Files/Git/etc/gitconfig\0core.fscache\0system\0file:C:/Program Files/Git/etc/gitconfig\0core.symlinks\0system\0file:C:/Program Files/Git/etc/gitconfig\0core.editor\0system\0file:C:/Program Files/Git/etc/gitconfig\0pull.ff\0system\0file:C:/Program Files/Git/etc/gitconfig\0credential.helper\0system\0file:C:/Program Files/Git/etc/gitconfig\0credential.https://dev.azure.com.usehttppath\0system\0file:C:/Program Files/Git/etc/gitconfig\0init.defaultbranch\0system\0file:C:/Program Files/Git/etc/gitconfig\0section.key\0system\0file:C:/Program Files/Git/etc/gitconfig\0section.key\0global\0file:C:/Users/jhcar/.gitconfig\0user.name\0global\0file:C:/Users/jhcar/.gitconfig\0user.email\0global\0file:C:/Users/jhcar/.gitconfig\0alias.lg\0global\0file:C:/Users/jhcar/.gitconfig\0gui.encoding\0global\0file:C:/Users/jhcar/.gitconfig\0gui.tabsize\0global\0file:C:/Users/jhcar/.gitconfig\0diff.tool\0global\0file:C:/Users/jhcar/.gitconfig\0difftool.kdiff3.path\0global\0file:C:/Users/jhcar/.gitconfig\0difftool.kdiff3.trustexitcode\0global\0file:C:/Users/jhcar/.gitconfig\0filter.lfs.clean\0global\0file:C:/Users/jhcar/.gitconfig\0filter.lfs.smudge\0global\0file:C:/Users/jhcar/.gitconfig\0filter.lfs.process\0global\0file:C:/Users/jhcar/.gitconfig\0filter.lfs.required\0global\0file:C:/Users/jhcar/.gitconfig\0section.key\0global\0file:C:/Users/jhcar/.gitconfig\0section.key\0
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git config get --show-origin --show-scope --all 'section.key' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 system\tfile:C:/Program Files/Git/etc/gitconfig\tvalue1\n
2 system\tfile:C:/Program Files/Git/etc/gitconfig\tvalue2\n
3 global\tfile:C:/Users/jhcar/.gitconfig\tvalue3\n
4 global\tfile:C:/Users/jhcar/.gitconfig\tvalue4\n
5
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git config get --show-origin --show-scope --null --all 'section.key' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 system\0file:C:/Program Files/Git/etc/gitconfig\0value1\0system\0file:C:/Program Files/Git/etc/gitconfig\0value2\0global\0file:C:/Users/jhcar/.gitconfig\0value3\0global\0file:C:/Users/jhcar/.gitconfig\0value4\0
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git config get --show-origin --show-scope --name-only --all 'section.key' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 system\tfile:C:/Program Files/Git/etc/gitconfig\t\n
2 system\tfile:C:/Program Files/Git/etc/gitconfig\t\n
3 global\tfile:C:/Users/jhcar/.gitconfig\t\n
4 global\tfile:C:/Users/jhcar/.gitconfig\t\n
5
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git config get --show-origin --show-scope --null --name-only --all 'section.key' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 system\0file:C:/Program Files/Git/etc/gitconfig\0\0system\0file:C:/Program Files/Git/etc/gitconfig\0\0global\0file:C:/Users/jhcar/.gitconfig\0\0global\0file:C:/Users/jhcar/.gitconfig\0\0
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git config get --show-origin --show-scope --show-names --all 'section.key' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 system\tfile:C:/Program Files/Git/etc/gitconfig\tsection.key value1\n
2 system\tfile:C:/Program Files/Git/etc/gitconfig\tsection.key value2\n
3 global\tfile:C:/Users/jhcar/.gitconfig\tsection.key value3\n
4 global\tfile:C:/Users/jhcar/.gitconfig\tsection.key value4\n
5
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git config get --show-origin --show-scope --show-names --null --all 'section.key' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 system\0file:C:/Program Files/Git/etc/gitconfig\0section.key\n
2 value1\0system\0file:C:/Program Files/Git/etc/gitconfig\0section.key\n
3 value2\0global\0file:C:/Users/jhcar/.gitconfig\0section.key\n
4 value3\0global\0file:C:/Users/jhcar/.gitconfig\0section.key\n
5 value4\0
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git config get --show-origin --show-scope --show-names --name-only --all 'section.key' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 system\tfile:C:/Program Files/Git/etc/gitconfig\tsection.key\n
2 system\tfile:C:/Program Files/Git/etc/gitconfig\tsection.key\n
3 global\tfile:C:/Users/jhcar/.gitconfig\tsection.key\n
4 global\tfile:C:/Users/jhcar/.gitconfig\tsection.key\n
5
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git config get --show-origin --show-scope --show-names --null --name-only --all 'section.key' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 system\0file:C:/Program Files/Git/etc/gitconfig\0section.key\0system\0file:C:/Program Files/Git/etc/gitconfig\0section.key\0global\0file:C:/Users/jhcar/.gitconfig\0section.key\0global\0file:C:/Users/jhcar/.gitconfig\0section.key\0
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value1 -c section.key=value4 config get --show-origin --show-scope --all 'section.key'
system file:C:/Program Files/Git/etc/gitconfig value1
system file:C:/Program Files/Git/etc/gitconfig value2
global file:C:/Users/jhcar/.gitconfig value1
global file:C:/Users/jhcar/.gitconfig value3
command command line: value1
command command line: value4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value1 -c section.key=value4 config get --show-origin --show-scope 'section.key'
command command line: value4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value1 -c section.key=value4 config get --show-origin --show-scope --all --regexp 'section.k[aeiou]y'
system file:C:/Program Files/Git/etc/gitconfig value1
system file:C:/Program Files/Git/etc/gitconfig value2
global file:C:/Users/jhcar/.gitconfig value1
global file:C:/Users/jhcar/.gitconfig value3
command command line: value1
command command line: value4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value1 -c section.key=value4 config get --show-origin --show-scope --regexp 'section.k[aeiou]y'
command command line: value4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value1 -c section.key=value4 config get --show-origin --show-scope --all --value='[13579]' 'section.key'
system file:C:/Program Files/Git/etc/gitconfig value1
global file:C:/Users/jhcar/.gitconfig value1
global file:C:/Users/jhcar/.gitconfig value3
command command line: value1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value1 -c section.key=value4 config get --show-origin --show-scope --value='[13579]' 'section.key'
command command line: value1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value1 -c section.key=value4 config get --show-origin --show-scope --all --value='[13579]' --fixed-value 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value1 -c section.key=value4 config get --show-origin --show-scope --all --value='1' --fixed-value 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value1 -c section.key=value4 config get --show-origin --show-scope --all --value='value1' --fixed-value 'section.key'
system file:C:/Program Files/Git/etc/gitconfig value1
global file:C:/Users/jhcar/.gitconfig value1
command command line: value1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value1 -c section.key=value4 config get --show-origin --show-scope --value='[13579]' --fixed-value 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value1 -c section.key=value4 config get --show-origin --show-scope --value='1' --fixed-value 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key=value1 -c section.key=value4 config get --show-origin --show-scope --value='value1' --fixed-value 'section.key'
command command line: value1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section]\n
│ 2 \tkey1 = value1\n
│ 3 \tkey2\n
│ 4 \tkey3 =\n
│ 5 \tkey4 = ""\n
│ 6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value' 'section.key'
command command line: default_value
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value' 'section.key1'
command file:./config.txt value1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value' 'section.key2'
command file:./config.txt
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value' 'section.key3'
command file:./config.txt
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value' 'section.key4'
command file:./config.txt
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value' 'section.key'
command command line: default_value
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value' 'section.key5'
command command line: value5
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value' 'section.key6'
command command line:
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value' 'section.key7'
command command line:
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value1' --value='[13579]' 'section.key1'
command file:./config.txt value1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value1' --value='[02468]' 'section.key1'
command command line: default_value1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value1' --value='[13579]' --fixed-value 'section.key1'
command command line: default_value1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value1' --value='[02468]' --fixed-value 'section.key1'
command command line: default_value1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='tRuE' --value='[02468]' --type=bool 'section.key1'
command command line: true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='tRuE' --value='[13579]' --fixed-value --type=bool 'section.key1'
command command line: true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='tRuE' --value='[02468]' --fixed-value --type=bool 'section.key1'
command command line: true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value2' --value='' 'section.key2'
command file:./config.txt
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value2' --value='^$' 'section.key2'
command file:./config.txt
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value2' --value='' --fixed-value 'section.key2'
command file:./config.txt
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value2' --value='^$' --fixed-value 'section.key2'
command command line: default_value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='fAlSe' --value='' --type=bool 'section.key2'
command file:./config.txt true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='fAlSe' --value='^$' --type=bool 'section.key2'
command file:./config.txt true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='fAlSe' --value='' --fixed-value --type=bool 'section.key2'
command file:./config.txt true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='fAlSe' --value='^$' --fixed-value --type=bool 'section.key2'
command command line: false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value3' --value='' 'section.key3'
command file:./config.txt
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value3' --value='^$' 'section.key3'
command file:./config.txt
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value3' --value='' --fixed-value 'section.key3'
command file:./config.txt
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value3' --value='^$' --fixed-value 'section.key3'
command command line: default_value3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='tRuE' --value='' --type=bool 'section.key3'
command file:./config.txt false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='tRuE' --value='^$' --type=bool 'section.key3'
command file:./config.txt false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='tRuE' --value='' --fixed-value --type=bool 'section.key3'
command file:./config.txt false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='tRuE' --value='^$' --fixed-value --type=bool 'section.key3'
command command line: true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value4' --value='' 'section.key4'
command file:./config.txt
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value4' --value='^$' 'section.key4'
command file:./config.txt
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value4' --value='' --fixed-value 'section.key4'
command file:./config.txt
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='default_value4' --value='^$' --fixed-value 'section.key4'
command command line: default_value4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='tRuE' --value='' --type=bool 'section.key4'
command file:./config.txt false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='tRuE' --value='^$' --type=bool 'section.key4'
command file:./config.txt false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='tRuE' --value='' --fixed-value --type=bool 'section.key4'
command file:./config.txt false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --default='tRuE' --value='^$' --fixed-value --type=bool 'section.key4'
command command line: true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value5' --value='[13579]' 'section.key5'
command command line: value5
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value5' --value='[02468]' 'section.key5'
command command line: default_value5
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value5' --value='[13579]' --fixed-value 'section.key5'
command command line: default_value5
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value5' --value='[02468]' --fixed-value 'section.key5'
command command line: default_value5
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='tRuE' --value='[02468]' --type=bool 'section.key5'
command command line: true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='tRuE' --value='[13579]' --fixed-value --type=bool 'section.key5'
command command line: true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='tRuE' --value='[02468]' --fixed-value --type=bool 'section.key5'
command command line: true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value6' --value='' 'section.key6'
command command line:
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value6' --value='^$' 'section.key6'
command command line:
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value6' --value='' --fixed-value 'section.key6'
command command line:
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value6' --value='^$' --fixed-value 'section.key6'
command command line: default_value6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='fAlSe' --value='' --type=bool 'section.key6'
command command line: true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='fAlSe' --value='^$' --type=bool 'section.key6'
command command line: true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='fAlSe' --value='' --fixed-value --type=bool 'section.key6'
command command line: true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='fAlSe' --value='^$' --fixed-value --type=bool 'section.key6'
command command line: false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value7' --value='' 'section.key7'
command command line:
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value7' --value='^$' 'section.key7'
command command line:
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value7' --value='' --fixed-value 'section.key7'
command command line:
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='default_value7' --value='^$' --fixed-value 'section.key7'
command command line: default_value7
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='tRuE' --value='' --type=bool 'section.key7'
command command line: false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='tRuE' --value='^$' --type=bool 'section.key7'
command command line: false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='tRuE' --value='' --fixed-value --type=bool 'section.key7'
command command line: false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c section.key5=value5 -c section.key6 -c section.key7= config get --show-origin --show-scope --default='tRuE' --value='^$' --fixed-value --type=bool 'section.key7'
command command line: true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section]\n
│ 2 \tkey1 = value1\n
│ 3 \tkey2 = value2\n
│ 4 [section "scheme://authority/path1"]\n
│ 5 \tkey1 = value3\n
│ 6 \tkey2 = value4\n
│ 7 [section "scheme://authority/path1/"]\n
│ 8 \tkey1 = value5\n
│ 9 \tkey2 = value6\n
│ 10 [section "scheme://authority/path1?query#fragment"]\n
│ 11 \tkey1 = value7\n
│ 12 \tkey2 = value8\n
│ 13 [section "scheme://authority/path1/?query#fragment"]\n
│ 14 \tkey1 = value9\n
│ 15 \tkey2 = value10\n
│ 16 [section "scheme://authority/path1/path2"]\n
│ 17 \tkey1 = value11\n
│ 18 \tkey2 = value12\n
│ 19 [section "scheme://authority/path1/path2/"]\n
│ 20 \tkey1 = value13\n
│ 21 \tkey2 = value14\n
│ 22 [section "scheme://authority/path1/path2?query#fragment"]\n
│ 23 \tkey1 = value15\n
│ 24 \tkey2 = value16\n
│ 25 [section "scheme://authority/path1/path2/?query#fragment"]\n
│ 26 \tkey1 = value17\n
│ 27 \tkey2 = value18\n
│ 28 [section "scheme://authority/path1/path2/path3"]\n
│ 29 \tkey1 = value19\n
│ 30 \tkey2 = value20\n
│ 31 [section "scheme://authority/path1/path2/path3/"]\n
│ 32 \tkey1 = value21\n
│ 33 \tkey2 = value22\n
│ 34 [section "scheme://authority/path1/path2/path3?query#fragment"]\n
│ 35 \tkey1 = value23\n
│ 36 \tkey2 = value24\n
│ 37 [section "scheme://authority/path1/path2/path3/?query#fragment"]\n
│ 38 \tkey1 = value25\n
│ 39 \tkey2 = value26\n
│ 40
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --all 'section'
error: key does not contain a section: section
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --all 'section.key2'
value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1' 'section'
section.key1 value5
section.key2 value6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1' 'section.key2'
value6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/' 'section'
section.key1 value5
section.key2 value6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/' 'section.key2'
value6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1?query' 'section'
section.key1 value1
section.key2 value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1?query' 'section.key2'
value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/?query' 'section'
section.key1 value5
section.key2 value6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/?query' 'section.key2'
value6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1?query#fragment' 'section'
section.key1 value7
section.key2 value8
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1?query#fragment' 'section.key2'
value8
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/?query#fragment' 'section'
section.key1 value9
section.key2 value10
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/?query#fragment' 'section.key2'
value10
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/path2' 'section'
section.key1 value13
section.key2 value14
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/path2' 'section.key2'
value14
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/path2/' 'section'
section.key1 value13
section.key2 value14
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/path2/' 'section.key2'
value14
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/path2?query' 'section'
section.key1 value5
section.key2 value6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/path2?query' 'section.key2'
value6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/path2/?query' 'section'
section.key1 value13
section.key2 value14
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/path2/?query' 'section.key2'
value14
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/path2?query#fragment' 'section'
section.key1 value15
section.key2 value16
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/path2?query#fragment' 'section.key2'
value16
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/path2/?query#fragment' 'section'
section.key1 value17
section.key2 value18
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --url='scheme://authority/path1/path2/?query#fragment' 'section.key2'
value18
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section]\n
│ 2 \tkey-bool\n
│ 3 \tkey-bool = yEs\n
│ 4 \tkey-bool = oN\n
│ 5 \tkey-bool = tRuE\n
│ 6 \tkey-bool = 1\n
│ 7 \tkey-bool = nO\n
│ 8 \tkey-bool = oFf\n
│ 9 \tkey-bool = fAlSe\n
│ 10 \tkey-bool = 0\n
│ 11 \tkey-bool =\n
│ 12 \tkey-bool = ""\n
│ 13 \n
│ 14 \tkey-int = 1\n
│ 15 \tkey-int = 2k\n
│ 16 \tkey-int = 3K\n
│ 17 \tkey-int = 4m\n
│ 18 \tkey-int = 5M\n
│ 19 \tkey-int = 6g\n
│ 20 \tkey-int = 7G\n
│ 21 \t#key-int = 8t\n
│ 22 \t#key-int = 9T\n
│ 23 \n
│ 24 \tkey-bool-or-int\n
│ 25 \tkey-bool-or-int = yEs\n
│ 26 \tkey-bool-or-int = oN\n
│ 27 \tkey-bool-or-int = tRuE\n
│ 28 \tkey-bool-or-int = 1\n
│ 29 \tkey-bool-or-int = nO\n
│ 30 \tkey-bool-or-int = oFf\n
│ 31 \tkey-bool-or-int = fAlSe\n
│ 32 \tkey-bool-or-int = 0\n
│ 33 \tkey-bool-or-int =\n
│ 34 \tkey-bool-or-int = ""\n
│ 35 \tkey-bool-or-int = 1\n
│ 36 \tkey-bool-or-int = 2k\n
│ 37 \tkey-bool-or-int = 3K\n
│ 38 \tkey-bool-or-int = 4m\n
│ 39 \tkey-bool-or-int = 5M\n
│ 40 \t#key-bool-or-int = 6g\n
│ 41 \t#key-bool-or-int = 7G\n
│ 42 \t#key-bool-or-int = 8t\n
│ 43 \t#key-bool-or-int = 9T\n
│ 44 \n
│ 45 \t#key-path\n
│ 46 \tkey-path =\n
│ 47 \tkey-path = ""\n
│ 48 \tkey-path = "/"\n
│ 49 \tkey-path = "//"\n
│ 50 \tkey-path = "///"\n
│ 51 \tkey-path = "////"\n
│ 52 \tkey-path = "~"\n
│ 53 \tkey-path = "~/"\n
│ 54 \tkey-path = "~//"\n
│ 55 \tkey-path = "~///"\n
│ 56 \tkey-path = "~////"\n
│ 57 \tkey-path = "%(prefix)"\n
│ 58 \tkey-path = "%(prefix)/"\n
│ 59 \tkey-path = "%(prefix)//"\n
│ 60 \tkey-path = "%(prefix)///"\n
│ 61 \tkey-path = "%(prefix)////"\n
│ 62 \n
│ 63 \t#key-color\n
│ 64 \tkey-color =\n
│ 65 \tkey-color = ""\n
│ 66 \tkey-color = "reset"\n
│ 67 \tkey-color = "blue reverse"\n
│ 68
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key-bool'
command file:./config.txt
command file:./config.txt yEs
command file:./config.txt oN
command file:./config.txt tRuE
command file:./config.txt 1
command file:./config.txt nO
command file:./config.txt oFf
command file:./config.txt fAlSe
command file:./config.txt 0
command file:./config.txt
command file:./config.txt
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all --value='' 'section.key-bool'
command file:./config.txt
command file:./config.txt yEs
command file:./config.txt oN
command file:./config.txt tRuE
command file:./config.txt 1
command file:./config.txt nO
command file:./config.txt oFf
command file:./config.txt fAlSe
command file:./config.txt 0
command file:./config.txt
command file:./config.txt
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all --value='^$' 'section.key-bool'
command file:./config.txt
command file:./config.txt
command file:./config.txt
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all --value='true' 'section.key-bool'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all --value='tRuE' 'section.key-bool'
command file:./config.txt tRuE
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all --type=bool 'section.key-bool'
command file:./config.txt true
command file:./config.txt true
command file:./config.txt true
command file:./config.txt true
command file:./config.txt true
command file:./config.txt false
command file:./config.txt false
command file:./config.txt false
command file:./config.txt false
command file:./config.txt false
command file:./config.txt false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all --type=bool --value='' 'section.key-bool'
command file:./config.txt true
command file:./config.txt true
command file:./config.txt true
command file:./config.txt true
command file:./config.txt true
command file:./config.txt false
command file:./config.txt false
command file:./config.txt false
command file:./config.txt false
command file:./config.txt false
command file:./config.txt false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all --type=bool --value='^$' 'section.key-bool'
command file:./config.txt true
command file:./config.txt false
command file:./config.txt false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all --type=bool --value='true' 'section.key-bool'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all --type=bool --value='tRuE' 'section.key-bool'
command file:./config.txt true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key-int'
command file:./config.txt 1
command file:./config.txt 2k
command file:./config.txt 3K
command file:./config.txt 4m
command file:./config.txt 5M
command file:./config.txt 6g
command file:./config.txt 7G
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all --type=int 'section.key-int'
command file:./config.txt 1
command file:./config.txt 2048
command file:./config.txt 3072
command file:./config.txt 4194304
command file:./config.txt 5242880
command file:./config.txt 6442450944
command file:./config.txt 7516192768
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key-bool-or-int'
command file:./config.txt
command file:./config.txt yEs
command file:./config.txt oN
command file:./config.txt tRuE
command file:./config.txt 1
command file:./config.txt nO
command file:./config.txt oFf
command file:./config.txt fAlSe
command file:./config.txt 0
command file:./config.txt
command file:./config.txt
command file:./config.txt 1
command file:./config.txt 2k
command file:./config.txt 3K
command file:./config.txt 4m
command file:./config.txt 5M
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all --type=bool-or-int 'section.key-bool-or-int'
command file:./config.txt true
command file:./config.txt true
command file:./config.txt true
command file:./config.txt true
command file:./config.txt 1
command file:./config.txt false
command file:./config.txt false
command file:./config.txt false
command file:./config.txt 0
command file:./config.txt false
command file:./config.txt false
command file:./config.txt 1
command file:./config.txt 2048
command file:./config.txt 3072
command file:./config.txt 4194304
command file:./config.txt 5242880
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key-path'
command file:./config.txt
command file:./config.txt
command file:./config.txt /
command file:./config.txt //
command file:./config.txt ///
command file:./config.txt ////
command file:./config.txt ~
command file:./config.txt ~/
command file:./config.txt ~//
command file:./config.txt ~///
command file:./config.txt ~////
command file:./config.txt %(prefix)
command file:./config.txt %(prefix)/
command file:./config.txt %(prefix)//
command file:./config.txt %(prefix)///
command file:./config.txt %(prefix)////
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all --type=path 'section.key-path'
command file:./config.txt
command file:./config.txt
command file:./config.txt /
command file:./config.txt //
command file:./config.txt ///
command file:./config.txt ////
command file:./config.txt C:/Users/jhcar
command file:./config.txt C:/Users/jhcar/
command file:./config.txt C:/Users/jhcar//
command file:./config.txt C:/Users/jhcar///
command file:./config.txt C:/Users/jhcar////
command file:./config.txt %(prefix)
command file:./config.txt C:/Program Files/Git/mingw64/
command file:./config.txt /
command file:./config.txt //
command file:./config.txt ///
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c 'section.key-path='"~$USERNAME" -c 'section.key-path='"~$USERNAME/" -c 'section.key-path='"~$USERNAME//" -c 'section.key-path='"~$USERNAME///" -c 'section.key-path='"~$USERNAME////" config get --show-origin --show-scope --all 'section.key-path'
command command line: ~jhcarl0814
command command line: ~jhcarl0814/
command command line: ~jhcarl0814//
command command line: ~jhcarl0814///
command command line: ~jhcarl0814////
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c 'section.key-path='"~$USERNAME" -c 'section.key-path='"~$USERNAME/" -c 'section.key-path='"~$USERNAME//" -c 'section.key-path='"~$USERNAME///" -c 'section.key-path='"~$USERNAME////" config get --show-origin --show-scope --all --type=path 'section.key-path'
fatal: failed to expand user dir in: '~jhcarl0814'
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c 'section.key-path='"~$(basename "$HOME")" -c 'section.key-path='"~$(basename "$HOME")/" -c 'section.key-path='"~$(basename "$HOME")//" -c 'section.key-path='"~$(basename "$HOME")///" -c 'section.key-path='"~$(basename "$HOME")////" config get --show-origin --show-scope --all 'section.key-path'
command command line: ~jhcar
command command line: ~jhcar/
command command line: ~jhcar//
command command line: ~jhcar///
command command line: ~jhcar////
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c 'section.key-path='"~$(basename "$HOME")" -c 'section.key-path='"~$(basename "$HOME")/" -c 'section.key-path='"~$(basename "$HOME")//" -c 'section.key-path='"~$(basename "$HOME")///" -c 'section.key-path='"~$(basename "$HOME")////" config get --show-origin --show-scope --all --type=path 'section.key-path'
fatal: failed to expand user dir in: '~jhcar'
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c 'section.key-path='":(optional)" -c 'section.key-path='":(optional)/" -c 'section.key-path='":(optional)//" -c 'section.key-path='":(optional)///" -c 'section.key-path='":(optional)////" config get --show-origin --show-scope --all 'section.key-path'
command command line: :(optional)
command command line: :(optional)/
command command line: :(optional)//
command command line: :(optional)///
command command line: :(optional)////
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c 'section.key-path='":(optional)" -c 'section.key-path='":(optional)/" -c 'section.key-path='":(optional)//" -c 'section.key-path='":(optional)///" -c 'section.key-path='":(optional)////" config get --show-origin --show-scope --all --type=path 'section.key-path'
fatal: could not stat //: Invalid argument
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c 'section.key-path='":(optional)" -c 'section.key-path='":(optional)/" config get --show-origin --show-scope --all --type=path 'section.key-path'
command command line: /
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c 'section.key-path='":(optional)//" config get --show-origin --show-scope --all --type=path 'section.key-path'
fatal: could not stat //: Invalid argument
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c 'section.key-path='":(optional)nonexistent" -c 'section.key-path='":(optional)/nonexistent" -c 'section.key-path='":(optional)//nonexistent" -c 'section.key-path='":(optional)///nonexistent" -c 'section.key-path='":(optional)////nonexistent" config get --show-origin --show-scope --all 'section.key-path'
command command line: :(optional)nonexistent
command command line: :(optional)/nonexistent
command command line: :(optional)//nonexistent
command command line: :(optional)///nonexistent
command command line: :(optional)////nonexistent
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c 'section.key-path='":(optional)nonexistent" -c 'section.key-path='":(optional)/nonexistent" -c 'section.key-path='":(optional)//nonexistent" -c 'section.key-path='":(optional)///nonexistent" -c 'section.key-path='":(optional)////nonexistent" config get --show-origin --show-scope --all --type=path 'section.key-path'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key-color'
command file:./config.txt
command file:./config.txt
command file:./config.txt reset
command file:./config.txt blue reverse
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all --type=color 'section.key-color' | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 command\tfile:./config.txt\t\n
2 command\tfile:./config.txt\t\n
3 command\tfile:./config.txt\t\e[m\n
4 command\tfile:./config.txt\t\e[7;34m\n
5
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ echo "$(git -c 'a.b=brightblue normal' config get --type=color 'a.b')fg_brightblue\
> $(git -c 'a.b=blue normal' config get --type=color 'a.b')fg_blue\
> $(git -c 'a.b=normal cyan' config get --type=color 'a.b')bg_cyan\
> $(git -c 'a.b=normal brightcyan' config get --type=color 'a.b')bg_brightcyan\
> $(git -c 'a.b=118 34' config get --type=color 'a.b')fg_118_bg_34\
> $(git -c 'a.b=#0000FF #00FFFF' config get --type=color 'a.b')fg_0000FF_bg_00FFFF\
> $(git -c 'a.b=normal default' config get --type=color 'a.b')bg_default\
> $(git -c 'a.b=default normal' config get --type=color 'a.b')fg_default\
> $(git -c 'a.b=reset' config get --type=color 'a.b')reset"
fg_brightbluefg_bluebg_cyanbg_brightcyanfg_118_bg_34fg_0000FF_bg_00FFFFbg_defaultfg_defaultreset
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ echo "$(git -c 'a.b=normal bold normal' config get --type=color 'a.b')bold\
> $(git -c 'a.b=normal ul italic normal' config get --type=color 'a.b')ul italic\
> $(git -c 'a.b=normal no-bold no-ul normal' config get --type=color 'a.b')no-bold no-ul\
> $(git -c 'a.b=normal reset strike dim normal' config get --type=color 'a.b')reset strike dim\
> $(git -c 'a.b=normal no-dim reverse normal' config get --type=color 'a.b')no-dim reverse\
> $(git -c 'a.b=normal blink normal' config get --type=color 'a.b')blink\
> $(git -c 'a.b=reset' config get --type=color 'a.b')reset"
boldul italicno-bold no-ulreset strike dimno-dim reverseblinkreset
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1'
No possible source branch, inferring '--orphan'
Preparing worktree (new branch 'worktree1')
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config --local extensions.worktreeConfig true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --system 'section.key' 'value11'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --global 'section.key' 'value21'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --local 'section.key' 'value31'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --worktree 'section.key' 'value411'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config set --worktree 'section.key' 'value412'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --show-origin --show-scope --all 'section.key'
system file:C:/Program Files/Git/etc/gitconfig value11
global file:C:/Users/jhcar/.gitconfig value21
local file:.git/config value31
worktree file:.git/config.worktree value411
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --show-origin --show-scope 'section.key'
worktree file:.git/config.worktree value411
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --show-origin --show-scope --all 'section.key'
system file:C:/Program Files/Git/etc/gitconfig value11
global file:C:/Users/jhcar/.gitconfig value21
local file:C:/Program Files/Git/test_git/repo/.git/config value31
worktree file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree value412
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --show-origin --show-scope 'section.key'
worktree file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree value412
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'section.key' 'value31'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt value31
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value31
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --system 'section.key' 'value12'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --global 'section.key' 'value22'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --local 'section.key' 'value32'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --worktree 'section.key' 'value421'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config set --worktree 'section.key' 'value422'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --show-origin --show-scope --all 'section.key'
system file:C:/Program Files/Git/etc/gitconfig value12
global file:C:/Users/jhcar/.gitconfig value22
local file:.git/config value32
worktree file:.git/config.worktree value421
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --show-origin --show-scope 'section.key'
worktree file:.git/config.worktree value421
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --show-origin --show-scope --all 'section.key'
system file:C:/Program Files/Git/etc/gitconfig value12
global file:C:/Users/jhcar/.gitconfig value22
local file:C:/Program Files/Git/test_git/repo/.git/config value32
worktree file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree value422
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --show-origin --show-scope 'section.key'
worktree file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree value422
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'section.key' 'value32'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt value32
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value32
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --system --append 'section.key' 'value13'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --global --append 'section.key' 'value23'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --local --append 'section.key' 'value33'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --worktree --append 'section.key' 'value431'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config set --worktree --append 'section.key' 'value432'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --show-origin --show-scope --all 'section.key'
system file:C:/Program Files/Git/etc/gitconfig value12
system file:C:/Program Files/Git/etc/gitconfig value13
global file:C:/Users/jhcar/.gitconfig value22
global file:C:/Users/jhcar/.gitconfig value23
local file:.git/config value32
local file:.git/config value33
worktree file:.git/config.worktree value421
worktree file:.git/config.worktree value431
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --show-origin --show-scope 'section.key'
worktree file:.git/config.worktree value431
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --show-origin --show-scope --all 'section.key'
system file:C:/Program Files/Git/etc/gitconfig value12
system file:C:/Program Files/Git/etc/gitconfig value13
global file:C:/Users/jhcar/.gitconfig value22
global file:C:/Users/jhcar/.gitconfig value23
local file:C:/Program Files/Git/test_git/repo/.git/config value32
local file:C:/Program Files/Git/test_git/repo/.git/config value33
worktree file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree value422
worktree file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree value432
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --show-origin --show-scope 'section.key'
worktree file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree value432
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --append 'section.key' 'value33'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt value32
command file:./config.txt value33
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value33
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --system 'section.key' 'value14'
warning: section.key has multiple values
error: cannot overwrite multiple values with a single value
Use --value=<pattern>, --append or --all to change section.key.
jhcarl0814@jhcarl0814 MINGW64 $?=5 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --system --all 'section.key' 'value14'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --global 'section.key' 'value24'
warning: section.key has multiple values
error: cannot overwrite multiple values with a single value
Use --value=<pattern>, --append or --all to change section.key.
jhcarl0814@jhcarl0814 MINGW64 $?=5 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --global --all 'section.key' 'value24'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --local 'section.key' 'value34'
warning: section.key has multiple values
error: cannot overwrite multiple values with a single value
Use --value=<pattern>, --append or --all to change section.key.
jhcarl0814@jhcarl0814 MINGW64 $?=5 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --local --all 'section.key' 'value34'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --worktree 'section.key' 'value441'
warning: section.key has multiple values
error: cannot overwrite multiple values with a single value
Use --value=<pattern>, --append or --all to change section.key.
jhcarl0814@jhcarl0814 MINGW64 $?=5 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --worktree --all 'section.key' 'value441'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config set --worktree 'section.key' 'value442'
warning: section.key has multiple values
error: cannot overwrite multiple values with a single value
Use --value=<pattern>, --append or --all to change section.key.
jhcarl0814@jhcarl0814 MINGW64 $?=5 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config set --worktree --all 'section.key' 'value442'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --show-origin --show-scope --all 'section.key'
system file:C:/Program Files/Git/etc/gitconfig value14
global file:C:/Users/jhcar/.gitconfig value24
local file:.git/config value34
worktree file:.git/config.worktree value441
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --show-origin --show-scope 'section.key'
worktree file:.git/config.worktree value441
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --show-origin --show-scope --all 'section.key'
system file:C:/Program Files/Git/etc/gitconfig value14
global file:C:/Users/jhcar/.gitconfig value24
local file:C:/Program Files/Git/test_git/repo/.git/config value34
worktree file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree value442
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --show-origin --show-scope 'section.key'
worktree file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree value442
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'section.key' 'value34'
warning: section.key has multiple values
error: cannot overwrite multiple values with a single value
Use --value=<pattern>, --append or --all to change section.key.
jhcarl0814@jhcarl0814 MINGW64 $?=5 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --all 'section.key' 'value34'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt value34
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value34
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config unset --system 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config unset --global 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config unset --local 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config unset --worktree 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config unset --worktree 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --show-origin --show-scope --all 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --show-origin --show-scope 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --show-origin --show-scope --all 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --show-origin --show-scope 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config unset --file='./config.txt' 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --system --append 'section.key' 'value15'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --system --append 'section.key' 'value16'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --global --append 'section.key' 'value25'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --global --append 'section.key' 'value26'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --local --append 'section.key' 'value35'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --local --append 'section.key' 'value36'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --worktree --append 'section.key' 'value451'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config set --worktree --append 'section.key' 'value461'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config set --worktree --append 'section.key' 'value452'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config set --worktree --append 'section.key' 'value462'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --show-origin --show-scope --all 'section.key'
system file:C:/Program Files/Git/etc/gitconfig value15
system file:C:/Program Files/Git/etc/gitconfig value16
global file:C:/Users/jhcar/.gitconfig value25
global file:C:/Users/jhcar/.gitconfig value26
local file:.git/config value35
local file:.git/config value36
worktree file:.git/config.worktree value451
worktree file:.git/config.worktree value461
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --show-origin --show-scope 'section.key'
worktree file:.git/config.worktree value461
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --show-origin --show-scope --all 'section.key'
system file:C:/Program Files/Git/etc/gitconfig value15
system file:C:/Program Files/Git/etc/gitconfig value16
global file:C:/Users/jhcar/.gitconfig value25
global file:C:/Users/jhcar/.gitconfig value26
local file:C:/Program Files/Git/test_git/repo/.git/config value35
local file:C:/Program Files/Git/test_git/repo/.git/config value36
worktree file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree value452
worktree file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree value462
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --show-origin --show-scope 'section.key'
worktree file:C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/config.worktree value462
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --append 'section.key' 'value35'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --append 'section.key' 'value36'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt value35
command file:./config.txt value36
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value36
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config unset --system 'section.key'
warning: section.key has multiple values
jhcarl0814@jhcarl0814 MINGW64 $?=5 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config unset --system --all 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config unset --global 'section.key'
warning: section.key has multiple values
jhcarl0814@jhcarl0814 MINGW64 $?=5 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config unset --global --all 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config unset --local 'section.key'
warning: section.key has multiple values
jhcarl0814@jhcarl0814 MINGW64 $?=5 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config unset --local --all 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config unset --worktree 'section.key'
warning: section.key has multiple values
jhcarl0814@jhcarl0814 MINGW64 $?=5 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config unset --worktree --all 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config unset --worktree 'section.key'
warning: section.key has multiple values
jhcarl0814@jhcarl0814 MINGW64 $?=5 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config unset --worktree --all 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --show-origin --show-scope --all 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config get --show-origin --show-scope 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --show-origin --show-scope --all 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' config get --show-origin --show-scope 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config unset --file='./config.txt' 'section.key'
warning: section.key has multiple values
jhcarl0814@jhcarl0814 MINGW64 $?=5 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config unset --file='./config.txt' --all 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex .
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section]\n
│ 2 \tkey\n
│ 3 \tkey =\n
│ 4 \tkey = value1\n
│ 5 \tkey = value2\n
│ 6 \tkey = value3\n
│ 7 \tkey = value4\n
│ 8
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --value='[13579]' 'section.key' 'value5'
warning: section.key has multiple values
jhcarl0814@jhcarl0814 MINGW64 $?=5 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt
command file:./config.txt
command file:./config.txt value1
command file:./config.txt value2
command file:./config.txt value3
command file:./config.txt value4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --value='[1]' 'section.key' 'value5'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt
command file:./config.txt
command file:./config.txt value5
command file:./config.txt value2
command file:./config.txt value3
command file:./config.txt value4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --value='[2]' --fixed-value 'section.key' 'value6'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt value6
command file:./config.txt
command file:./config.txt value5
command file:./config.txt value2
command file:./config.txt value3
command file:./config.txt value4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --value='2' --fixed-value 'section.key' 'value7'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt value6
command file:./config.txt
command file:./config.txt value5
command file:./config.txt value2
command file:./config.txt value3
command file:./config.txt value4
command file:./config.txt value7
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value7
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --value='value2' --fixed-value 'section.key' 'value8'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt value6
command file:./config.txt
command file:./config.txt value5
command file:./config.txt value8
command file:./config.txt value3
command file:./config.txt value4
command file:./config.txt value7
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value7
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --value='abcdefg' 'section.key' 'value9'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt value6
command file:./config.txt
command file:./config.txt value5
command file:./config.txt value8
command file:./config.txt value3
command file:./config.txt value4
command file:./config.txt value7
command file:./config.txt value9
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value9
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cat >'./config.txt' <<'EOF'
> [section]
> key
> key =
> key = value1
> key = value2
> EOF
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --value='^$' 'section.key' 'value3'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt
command file:./config.txt value3
command file:./config.txt value1
command file:./config.txt value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cat >'./config.txt' <<'EOF'
> [section]
> key
> key =
> key = value1
> key = value2
> EOF
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --value='^$' --fixed-value 'section.key' 'value4'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt value4
command file:./config.txt
command file:./config.txt value1
command file:./config.txt value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cat >'./config.txt' <<'EOF'
> [section]
> key
> key =
> key = value1
> key = value2
> EOF
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --value='' 'section.key' 'value5'
warning: section.key has multiple values
jhcarl0814@jhcarl0814 MINGW64 $?=5 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt
command file:./config.txt
command file:./config.txt value1
command file:./config.txt value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cat >'./config.txt' <<'EOF'
> [section]
> key
> key =
> key = value1
> key = value2
> EOF
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --value='' --fixed-value 'section.key' 'value6'
warning: section.key has multiple values
jhcarl0814@jhcarl0814 MINGW64 $?=5 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt
command file:./config.txt
command file:./config.txt value1
command file:./config.txt value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cat >'./config.txt' <<'EOF'
> [section]
> key
> key =
> key = value1
> key = value2
> EOF
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' --value='!' 'section.key' 'value7'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope --all 'section.key'
command file:./config.txt value7
command file:./config.txt
command file:./config.txt value1
command file:./config.txt value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config get --file='./config.txt' --show-origin --show-scope 'section.key'
command file:./config.txt value2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex .
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section1]\n
│ 2 \tkey1 = value1\n
│ 3 \tkey2 = value2\n
│ 4 [section2]\n
│ 5 \tkey1 = value1\n
│ 6 \tkey3 = value3\n
│ 7 [section3]\n
│ 8 \tkey1 = value1\n
│ 9 \tkey4 = value4\n
│ 10
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config rename-section --file='./config.txt' 'section4' 'section5'
fatal: no such section: section4
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config rename-section --file='./config.txt' 'section4' 'section3'
fatal: no such section: section4
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config rename-section --file='./config.txt' 'section1' 'section4'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex .
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section4]\n
│ 2 \tkey1 = value1\n
│ 3 \tkey2 = value2\n
│ 4 [section2]\n
│ 5 \tkey1 = value1\n
│ 6 \tkey3 = value3\n
│ 7 [section3]\n
│ 8 \tkey1 = value1\n
│ 9 \tkey4 = value4\n
│ 10
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config rename-section --file='./config.txt' 'section4' 'section2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex .
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section2]\n
│ 2 \tkey1 = value1\n
│ 3 \tkey2 = value2\n
│ 4 [section2]\n
│ 5 \tkey1 = value1\n
│ 6 \tkey3 = value3\n
│ 7 [section3]\n
│ 8 \tkey1 = value1\n
│ 9 \tkey4 = value4\n
│ 10
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config rename-section --file='./config.txt' 'section2' 'section5'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex .
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section5]\n
│ 2 \tkey1 = value1\n
│ 3 \tkey2 = value2\n
│ 4 [section5]\n
│ 5 \tkey1 = value1\n
│ 6 \tkey3 = value3\n
│ 7 [section3]\n
│ 8 \tkey1 = value1\n
│ 9 \tkey4 = value4\n
│ 10
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config remove-section --file='./config.txt' 'section3'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex .
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section5]\n
│ 2 \tkey1 = value1\n
│ 3 \tkey2 = value2\n
│ 4 [section5]\n
│ 5 \tkey1 = value1\n
│ 6 \tkey3 = value3\n
│ 7
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config remove-section --file='./config.txt' 'section5'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex .
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular empty file rw-r--r--/0o644
│ 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex .
./ d/0o040/directory rwxr-xr-x/0o755
├╴config.txt -/0o100/regular file rw-r--r--/0o644
│ 1 [section]\n
│ 2 \tkey1\n
│ 3 \tkey2 =\n
│ 4 \tkey3 = false\n
│ 5 \tkey4 = never\n
│ 6 \tkey5 = true\n
│ 7 \tkey6 = auto\n
│ 8 \tkey7 = always\n
│ 9
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ test -t 0
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key1'; echo "$?"
0
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key2'; echo "$?"
1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key3'; echo "$?"
1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key4'; echo "$?"
1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key5'; echo "$?"
0
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key6'; echo "$?"
0
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key7'; echo "$?"
0
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key1' false
false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key2' false
false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key3' false
false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key4' false
false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key5' false
false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key6' false
false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key7' false
true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key1' true
true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key2' true
false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key3' true
false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key4' true
false
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key5' true
true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key6' true
true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key7' true
true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'color.ui' 'never'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key'; echo "$?"
1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'color.ui' 'auto'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key'; echo "$?"
0
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config set --file='./config.txt' 'color.ui' 'always'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git config --file='./config.txt' --get-colorbool 'section.key'; echo "$?"
0
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git var -l
diff.astextplain.textconv=astextplain
filter.lfs.clean=git-lfs clean -- %f
filter.lfs.smudge=git-lfs smudge -- %f
filter.lfs.process=git-lfs filter-process
filter.lfs.required=true
http.sslbackend=openssl
http.sslcainfo=C:/Program Files/Git/mingw64/etc/ssl/certs/ca-bundle.crt
core.autocrlf=true
core.fscache=true
core.symlinks=true
core.editor="C:\\Program Files\\Notepad++\\notepad++.exe" -multiInst -notabbar -nosession -noPlugin
pull.ff=only
credential.helper=manager
credential.https://dev.azure.com.usehttppath=true
init.defaultbranch=master
user.name=Han Jiang
user.email=jhcarl0814@gmail.com
alias.lg=log --graph --abbrev-commit --decorate=full --date=format:'%Y-%m-%d %H:%M' --format=tformat:'%C(bold green)%h%C(reset) - %C(bold blue)%ad (%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(auto)%d%C(reset)'
gui.encoding=utf-8
gui.tabsize=4
diff.tool=kdiff3
difftool.kdiff3.path=C:/Program Files/KDiff3/bin/kdiff3.exe
difftool.kdiff3.trustexitcode=false
filter.lfs.clean=git-lfs clean -- %f
filter.lfs.smudge=git-lfs smudge -- %f
filter.lfs.process=git-lfs filter-process
filter.lfs.required=true
GIT_COMMITTER_IDENT=Han Jiang <jhcarl0814@gmail.com> 1783422653 +1200
GIT_AUTHOR_IDENT=Han Jiang <jhcarl0814@gmail.com> 1783422653 +1200
GIT_EDITOR="C:\\Program Files\\Notepad++\\notepad++.exe" -multiInst -notabbar -nosession -noPlugin
GIT_SEQUENCE_EDITOR="C:\\Program Files\\Notepad++\\notepad++.exe" -multiInst -notabbar -nosession -noPlugin
GIT_PAGER=cat
GIT_DEFAULT_BRANCH=master
GIT_SHELL_PATH=C:/Program Files/Git/usr/bin/sh.exe
GIT_ATTR_SYSTEM=C:/Program Files/Git/etc/gitattributes
GIT_ATTR_GLOBAL=C:/Users/jhcar/.config/git/attributes
GIT_CONFIG_SYSTEM=C:/Program Files/Git/etc/gitconfig
GIT_CONFIG_GLOBAL=C:/Users/jhcar/.config/git/config
GIT_CONFIG_GLOBAL=C:/Users/jhcar/.gitconfig
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git var GIT_CONFIG_SYSTEM
C:/Program Files/Git/etc/gitconfig
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git var GIT_CONFIG_GLOBAL
C:/Users/jhcar/.config/git/config
C:/Users/jhcar/.gitconfig
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git --version
git version 2.55.0.windows.1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git --version --build-options
git version 2.55.0.windows.1
cpu: x86_64
built from commit: bf5afdecc10478397d7059d07573630902fb2e2f
sizeof-long: 4
sizeof-size_t: 8
shell-path: D:/git-sdk-64-build-installers/usr/bin/sh
rust: disabled
feature: fsmonitor--daemon
gettext: enabled
libcurl: 8.21.0
OpenSSL: OpenSSL 3.5.7 9 Jun 2026
zlib: 1.3.2
SHA-1: SHA1_DC
SHA-256: SHA256_BLK
default-ref-format: files
default-hash: sha1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git --exec-path
C:/Program Files/Git/mingw64/libexec/git-core
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ ls --group-directories-first --escape --classify --quoting-style=shell-escape-always -- "$(git --exec-path)"
'mergetools'/ 'git-imap-send.exe'*
'Atlassian.Bitbucket.dll'* 'git-merge-octopus'*
'Avalonia.Base.dll'* 'git-merge-one-file'*
'Avalonia.Controls.dll'* 'git-merge-resolve'*
'Avalonia.DesignerSupport.dll'* 'git-mergetool'*
'Avalonia.Dialogs.dll'* 'git-mergetool--lib'
'Avalonia.Markup.Xaml.dll'* 'git-quiltimport'*
'Avalonia.Markup.dll'* 'git-remote-ftp.exe'*
'Avalonia.Metal.dll'* 'git-remote-ftps.exe'*
'Avalonia.MicroCom.dll'* 'git-remote-http.exe'*
'Avalonia.OpenGL.dll'* 'git-remote-https.exe'*
'Avalonia.Remote.Protocol.dll'* 'git-request-pull'*
'Avalonia.Skia.dll'* 'git-send-email'*
'Avalonia.Themes.Fluent.dll'* 'git-sh-i18n'
'Avalonia.Vulkan.dll'* 'git-sh-i18n--envsubst.exe'*
'Avalonia.Win32.dll'* 'git-sh-setup'
'Avalonia.dll'* 'git-submodule'*
'GitHub.dll'* 'git-subtree'*
'GitLab.dll'* 'git-update'*
'HarfBuzzSharp.dll'* 'git-web--browse'*
'MicroCom.Runtime.dll'* 'git.exe'*
'Microsoft.AzureRepos.dll'* 'headless-git.exe'*
'Microsoft.Bcl.AsyncInterfaces.dll'* 'libHarfBuzzSharp.dll'*
'Microsoft.Identity.Client.Broker.dll'* 'libSkiaSharp.dll'*
'Microsoft.Identity.Client.Extensions.Msal.dll'* 'libbrotlicommon.dll'*
'Microsoft.Identity.Client.NativeInterop.dll'* 'libbrotlidec.dll'*
'Microsoft.Identity.Client.dll'* 'libbrotlienc.dll'*
'Microsoft.IdentityModel.Abstractions.dll'* 'libbz2-1.dll'*
'SkiaSharp.dll'* 'libcares-2.dll'*
'System.Buffers.dll'* 'libcrypto-3-x64.dll'*
'System.CommandLine.dll'* 'libcurl-4.dll'*
'System.ComponentModel.Annotations.dll'* 'libcurl-openssl-4.dll'*
'System.Diagnostics.DiagnosticSource.dll'* 'libexpat-1.dll'*
'System.IO.FileSystem.AccessControl.dll'* 'libffi-8.dll'*
'System.Memory.dll'* 'libgcc_s_seh-1.dll'*
'System.Numerics.Vectors.dll'* 'libgmp-10.dll'*
'System.Runtime.CompilerServices.Unsafe.dll'* 'libhogweed-6.dll'*
'System.Security.AccessControl.dll'* 'libiconv-2.dll'*
'System.Security.Cryptography.ProtectedData.dll'* 'libidn2-0.dll'*
'System.Security.Principal.Windows.dll'* 'libintl-8.dll'*
'System.Text.Encodings.Web.dll'* 'liblzma-5.dll'*
'System.Text.Json.dll'* 'libnettle-8.dll'*
'System.Threading.Tasks.Extensions.dll'* 'libnghttp2-14.dll'*
'System.ValueTuple.dll'* 'libp11-kit-0.dll'*
'av_libglesv2.dll'* 'libpcre2-8-0.dll'*
'edit.dll'* 'libpcre2-posix-3.dll'*
'gcmcore.dll'* 'libpsl-5.dll'*
'git-citool'* 'libssh2-1.dll'*
'git-credential-wincred.exe'* 'libssl-3-x64.dll'*
'git-daemon.exe'* 'libstdc++-6.dll'*
'git-difftool--helper'* 'libtasn1-6.dll'*
'git-filter-branch'* 'libunistring-5.dll'*
'git-gui'* 'libwinpthread-1.dll'*
'git-gui--askpass'* 'libzstd.dll'*
'git-gui--askyesno'* 'msalruntime.dll'*
'git-gui.tcl'* 'scalar.exe'*
'git-http-backend.exe'* 'tcl86.dll'*
'git-http-fetch.exe'* 'tk86.dll'*
'git-http-push.exe'* 'zlib1.dll'*
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git --html-path
C:/Program Files/Git/mingw64/share/doc/git-doc
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git --man-path
C:/Program Files/Git/mingw64/share/man
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git --info-path
C:/Program Files/Git/mingw64/share/info
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git
usage: git [-v | --version] [-h | --help] [-C <path>] [-c <name>=<value>]
[--exec-path[=<path>]] [--html-path] [--man-path] [--info-path]
[-p | --paginate | -P | --no-pager] [--no-replace-objects] [--no-lazy-fetch]
[--no-optional-locks] [--no-advice] [--bare] [--git-dir=<path>]
[--work-tree=<path>] [--namespace=<name>] [--config-env=<name>=<envvar>]
<command> [<args>]
These are common Git commands used in various situations:
start a working area (see also: git help tutorial)
clone Clone a repository into a new directory
init Create an empty Git repository or reinitialize an existing one
work on the current change (see also: git help everyday)
add Add file contents to the index
mv Move or rename a file, a directory, or a symlink
restore Restore working tree files
rm Remove files from the working tree and from the index
examine the history and state (see also: git help revisions)
bisect Use binary search to find the commit that introduced a bug
diff Show changes between commits, commit and working tree, etc
grep Print lines matching a pattern
log Show commit logs
show Show various types of objects
status Show the working tree status
grow, mark and tweak your common history
backfill Download missing objects in a partial clone
branch List, create, or delete branches
commit Record changes to the repository
history EXPERIMENTAL: Rewrite history
merge Join two or more development histories together
rebase Reapply commits on top of another base tip
reset Set `HEAD` or the index to a known state
switch Switch branches
tag Create, list, delete or verify tags
collaborate (see also: git help workflows)
fetch Download objects and refs from another repository
pull Fetch from and integrate with another repository or a local branch
push Update remote refs along with associated objects
'git help -a' and 'git help -g' list available subcommands and some
concept guides. See 'git help <command>' or 'git help <concept>'
to read about a specific subcommand or concept.
See 'git help git' for an overview of the system.
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git --help
usage: git [-v | --version] [-h | --help] [-C <path>] [-c <name>=<value>]
[--exec-path[=<path>]] [--html-path] [--man-path] [--info-path]
[-p | --paginate | -P | --no-pager] [--no-replace-objects] [--no-lazy-fetch]
[--no-optional-locks] [--no-advice] [--bare] [--git-dir=<path>]
[--work-tree=<path>] [--namespace=<name>] [--config-env=<name>=<envvar>]
<command> [<args>]
These are common Git commands used in various situations:
start a working area (see also: git help tutorial)
clone Clone a repository into a new directory
init Create an empty Git repository or reinitialize an existing one
work on the current change (see also: git help everyday)
add Add file contents to the index
mv Move or rename a file, a directory, or a symlink
restore Restore working tree files
rm Remove files from the working tree and from the index
examine the history and state (see also: git help revisions)
bisect Use binary search to find the commit that introduced a bug
diff Show changes between commits, commit and working tree, etc
grep Print lines matching a pattern
log Show commit logs
show Show various types of objects
status Show the working tree status
grow, mark and tweak your common history
backfill Download missing objects in a partial clone
branch List, create, or delete branches
commit Record changes to the repository
history EXPERIMENTAL: Rewrite history
merge Join two or more development histories together
rebase Reapply commits on top of another base tip
reset Set `HEAD` or the index to a known state
switch Switch branches
tag Create, list, delete or verify tags
collaborate (see also: git help workflows)
fetch Download objects and refs from another repository
pull Fetch from and integrate with another repository or a local branch
push Update remote refs along with associated objects
'git help -a' and 'git help -g' list available subcommands and some
concept guides. See 'git help <command>' or 'git help <concept>'
to read about a specific subcommand or concept.
See 'git help git' for an overview of the system.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git --help --all
See 'git help <command>' to read about a specific subcommand
Main Porcelain Commands
add Add file contents to the index
am Apply a series of patches from a mailbox
archive Create an archive of files from a named tree
backfill Download missing objects in a partial clone
bisect Use binary search to find the commit that introduced a bug
branch List, create, or delete branches
bundle Move objects and refs by archive
checkout Switch branches or restore working tree files
cherry-pick Apply the changes introduced by some existing commits
citool Graphical alternative to git-commit
clean Remove untracked files from the working tree
clone Clone a repository into a new directory
commit Record changes to the repository
describe Give an object a human readable name based on an available ref
diff Show changes between commits, commit and working tree, etc
fetch Download objects and refs from another repository
format-patch Prepare patches for e-mail submission
gc Cleanup unnecessary files and optimize the local repository
gitk The Git repository browser
grep Print lines matching a pattern
gui A portable graphical interface to Git
history EXPERIMENTAL: Rewrite history
init Create an empty Git repository or reinitialize an existing one
log Show commit logs
maintenance Run tasks to optimize Git repository data
merge Join two or more development histories together
mv Move or rename a file, a directory, or a symlink
notes Add or inspect object notes
pull Fetch from and integrate with another repository or a local branch
push Update remote refs along with associated objects
range-diff Compare two commit ranges (e.g. two versions of a branch)
rebase Reapply commits on top of another base tip
reset Set `HEAD` or the index to a known state
restore Restore working tree files
revert Revert some existing commits
rm Remove files from the working tree and from the index
scalar A tool for managing large Git repositories
shortlog Summarize `git log` output
show Show various types of objects
sparse-checkout Reduce your working tree to a subset of tracked files
stash Stash the changes in a dirty working directory away
status Show the working tree status
submodule Initialize, update or inspect submodules
survey EXPERIMENTAL: Measure various repository dimensions of scale
switch Switch branches
tag Create, list, delete or verify tags
worktree Manage multiple working trees
Ancillary Commands / Manipulators
config Get and set repository or global options
fast-export Git data exporter
fast-import Backend for fast Git data importers
filter-branch Rewrite branches
mergetool Run merge conflict resolution tools to resolve merge conflicts
pack-refs Pack heads and tags for efficient repository access
prune Prune all unreachable objects from the object database
reflog Manage reflog information
refs Low-level access to refs
remote Manage set of tracked repositories
repack Pack unpacked objects in a repository
replace Create, list, delete refs to replace objects
Ancillary Commands / Interrogators
annotate Annotate file lines with commit information
blame Show what revision and author last modified each line of a file
bugreport Collect information for user to file a bug report
count-objects Count unpacked number of objects and their disk consumption
diagnose Generate a zip archive of diagnostic information
difftool Show changes using common diff tools
fsck Verifies the connectivity and validity of the objects in the database
gitweb Git web interface (web frontend to Git repositories)
help Display help information about Git
instaweb Instantly browse your working repository in gitweb
merge-tree Perform merge without touching index or working tree
rerere Reuse recorded resolution of conflicted merges
show-branch Show branches and their commits
verify-commit Check the GPG signature of commits
verify-tag Check the GPG signature of tags
version Display version information about Git
whatchanged Show logs with differences each commit introduces
Interacting with Others
archimport Import a GNU Arch repository into Git
cvsexportcommit Export a single commit to a CVS checkout
cvsimport Salvage your data out of another SCM people love to hate
cvsserver A CVS server emulator for Git
imap-send Send a collection of patches from stdin to an IMAP folder
p4 Import from and submit to Perforce repositories
quiltimport Applies a quilt patchset onto the current branch
request-pull Generates a summary of pending changes
send-email Send a collection of patches as emails
svn Bidirectional operation between a Subversion repository and Git
Low-level Commands / Manipulators
apply Apply a patch to files and/or to the index
checkout-index Copy files from the index to the working tree
commit-graph Write and verify Git commit-graph files
commit-tree Create a new commit object
hash-object Compute object ID and optionally create an object from a file
index-pack Build pack index file for an existing packed archive
merge-file Run a three-way file merge
merge-index Run a merge for files needing merging
mktag Creates a tag object with extra validation
mktree Build a tree-object from ls-tree formatted text
multi-pack-index Write and verify multi-pack-indexes
pack-objects Create a packed archive of objects
prune-packed Remove extra objects that are already in pack files
read-tree Reads tree information into the index
replay EXPERIMENTAL: Replay commits on a new base, works with bare repos too
symbolic-ref Read, modify and delete symbolic refs
unpack-objects Unpack objects from a packed archive
update-index Register file contents in the working tree to the index
update-ref Update the object name stored in a ref safely
write-tree Create a tree object from the current index
Low-level Commands / Interrogators
cat-file Provide contents or details of repository objects
cherry Find commits yet to be applied to upstream
diff-files Compares files in the working tree and the index
diff-index Compare a tree to the working tree or index
diff-pairs Compare the content and mode of provided blob pairs
diff-tree Compares the content and mode of blobs found via two tree objects
for-each-ref Output information on each ref
for-each-repo Run a Git command on a list of repositories
format-rev EXPERIMENTAL: Pretty format revisions on demand
get-tar-commit-id Extract commit ID from an archive created using git-archive
last-modified EXPERIMENTAL: Show when files were last modified
ls-files Show information about files in the index and the working tree
ls-remote List references in a remote repository
ls-tree List the contents of a tree object
merge-base Find as good common ancestors as possible for a merge
name-rev Find symbolic names for given revs
pack-redundant Find redundant pack files
repo Retrieve information about the repository
rev-list Lists commit objects in reverse chronological order
rev-parse Pick out and massage parameters
show-index Show packed archive index
show-ref List references in a local repository
unpack-file Creates a temporary file with a blob's contents
var Show a Git logical variable
verify-pack Validate packed Git archive files
Low-level Commands / Syncing Repositories
daemon A really simple server for Git repositories
fetch-pack Receive missing objects from another repository
http-backend Server side implementation of Git over HTTP
send-pack Push objects over Git protocol to another repository
update-server-info Update auxiliary info file to help dumb servers
Low-level Commands / Internal Helpers
check-attr Display gitattributes information
check-ignore Debug gitignore / exclude files
check-mailmap Show canonical names and email addresses of contacts
check-ref-format Ensures that a reference name is well formed
column Display data in columns
credential Retrieve and store user credentials
credential-cache Helper to temporarily store passwords in memory
credential-store Helper to store credentials on disk
fmt-merge-msg Produce a merge commit message
hook Run Git hooks
interpret-trailers Add or parse structured information in commit messages
mailinfo Extracts patch and authorship from a single e-mail message
mailsplit Simple UNIX mbox splitter program
merge-one-file The standard helper program to use with git-merge-index
patch-id Compute unique IDs for patches
sh-i18n Git's i18n setup code for shell scripts
sh-setup Common Git shell script setup code
stripspace Remove unnecessary whitespace
url-parse Parse and extract git URL components
User-facing repository, command and file interfaces
attributes Defining attributes per path
cli Git command-line interface and conventions
hooks Hooks used by Git
ignore Specifies intentionally untracked files to ignore
mailmap Map author/committer names and/or E-Mail addresses
modules Defining submodule properties
repository-layout Git Repository Layout
revisions Specifying revisions and ranges for Git
Developer-facing file formats, protocols and other interfaces
format-bundle The bundle file format
format-chunk Chunk-based file formats
format-commit-graph Git commit-graph format
format-index Git index format
format-pack Git pack format
format-signature Git cryptographic signature formats
protocol-capabilities Protocol v0 and v1 capabilities
protocol-common Things common to various protocols
protocol-http Git HTTP-based protocols
protocol-pack How packs are transferred over-the-wire
protocol-v2 Git Wire Protocol, Version 2
External commands
askpass
askyesno
credential-helper-selector
credential-manager
lfs
update-git-for-windows
Command aliases
lg log --graph --abbrev-commit --decorate=full --date=format:'%Y-%m-%d %H:%M' --format=tformat:'%C(bold green)%h%C(reset) - %C(bold blue)%ad (%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(auto)%d%C(reset)'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git --help --all --no-verbose
usage: git [-v | --version] [-h | --help] [-C <path>] [-c <name>=<value>]
[--exec-path[=<path>]] [--html-path] [--man-path] [--info-path]
[-p | --paginate | -P | --no-pager] [--no-replace-objects] [--no-lazy-fetch]
[--no-optional-locks] [--no-advice] [--bare] [--git-dir=<path>]
[--work-tree=<path>] [--namespace=<name>] [--config-env=<name>=<envvar>]
<command> [<args>]
available git commands in 'C:/Program Files/Git/mingw64/libexec/git-core'
add merge-one-file
am merge-ours
annotate merge-recursive
apply merge-recursive-ours
archive merge-recursive-theirs
backfill merge-resolve
bisect merge-subtree
blame merge-tree
branch mergetool
bugreport mktag
bundle mktree
cat-file multi-pack-index
check-attr mv
check-ignore name-rev
check-mailmap notes
check-ref-format pack-objects
checkout pack-redundant
checkout--worker pack-refs
checkout-index patch-id
cherry pickaxe
cherry-pick prune
citool prune-packed
clean pull
clone push
column quiltimport
commit range-diff
commit-graph read-tree
commit-tree rebase
config receive-pack
count-objects reflog
credential refs
credential-cache remote
credential-cache--daemon remote-ext
credential-store remote-fd
credential-wincred remote-ftp
daemon remote-ftps
describe remote-http
diagnose remote-https
diff repack
diff-files replace
diff-index replay
diff-pairs repo
diff-tree request-pull
difftool rerere
difftool--helper reset
fast-export restore
fast-import rev-list
fetch rev-parse
fetch-pack revert
filter-branch rm
fmt-merge-msg send-email
for-each-ref send-pack
for-each-repo sh-i18n--envsubst
format-patch shortlog
format-rev show
fsck show-branch
fsck-objects show-index
fsmonitor--daemon show-ref
gc sparse-checkout
get-tar-commit-id stage
grep stash
gui status
gui--askpass stripspace
gui--askyesno submodule
gui.tcl submodule--helper
hash-object subtree
help survey
history switch
hook symbolic-ref
http-backend tag
http-fetch unpack-file
http-push unpack-objects
imap-send update
index-pack update-index
init update-ref
init-db update-server-info
interpret-trailers upload-archive
last-modified upload-archive--writer
log upload-pack
ls-files url-parse
ls-remote var
ls-tree verify-commit
mailinfo verify-pack
mailsplit verify-tag
maintenance version
merge web--browse
merge-base whatchanged
merge-file worktree
merge-index write-tree
merge-octopus
git commands available from elsewhere on your $PATH
askpass credential-manager
askyesno lfs
credential-helper-selector update-git-for-windows
'git help -a' and 'git help -g' list available subcommands and some
concept guides. See 'git help <command>' or 'git help <concept>'
to read about a specific subcommand or concept.
See 'git help git' for an overview of the system.
usage: git [-v | --version] [-h | --help] [-C <path>] [-c <name>=<value>]
[--exec-path[=<path>]] [--html-path] [--man-path] [--info-path]
[-p | --paginate | -P | --no-pager] [--no-replace-objects] [--no-lazy-fetch]
[--no-optional-locks] [--no-advice] [--bare] [--git-dir=<path>]
[--work-tree=<path>] [--namespace=<name>] [--config-env=<name>=<envvar>]
<command> [<args>]
These are common Git commands used in various situations:
start a working area (see also: git help tutorial)
clone Clone a repository into a new directory
init Create an empty Git repository or reinitialize an existing one
work on the current change (see also: git help everyday)
add Add file contents to the index
mv Move or rename a file, a directory, or a symlink
restore Restore working tree files
rm Remove files from the working tree and from the index
examine the history and state (see also: git help revisions)
bisect Use binary search to find the commit that introduced a bug
diff Show changes between commits, commit and working tree, etc
grep Print lines matching a pattern
log Show commit logs
show Show various types of objects
status Show the working tree status
grow, mark and tweak your common history
backfill Download missing objects in a partial clone
branch List, create, or delete branches
commit Record changes to the repository
history EXPERIMENTAL: Rewrite history
merge Join two or more development histories together
rebase Reapply commits on top of another base tip
reset Set `HEAD` or the index to a known state
switch Switch branches
tag Create, list, delete or verify tags
collaborate (see also: git help workflows)
fetch Download objects and refs from another repository
pull Fetch from and integrate with another repository or a local branch
push Update remote refs along with associated objects
'git help -a' and 'git help -g' list available subcommands and some
concept guides. See 'git help <command>' or 'git help <concept>'
to read about a specific subcommand or concept.
See 'git help git' for an overview of the system.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git --help --guides
The Git concept guides are:
core-tutorial A Git core tutorial for developers
credentials Providing usernames and passwords to Git
cvs-migration Git for CVS users
diffcore Tweaking diff output
everyday A useful minimum set of commands for Everyday Git
faq Frequently asked questions about using Git
glossary A Git Glossary
namespaces Git namespaces
remote-helpers Helper programs to interact with remote repositories
submodules Mounting one repository inside another
tutorial A tutorial introduction to Git
tutorial-2 A tutorial introduction to Git: part two
workflows An overview of recommended workflows with Git
'git help -a' and 'git help -g' list available subcommands and some
concept guides. See 'git help <command>' or 'git help <concept>'
to read about a specific subcommand or concept.
See 'git help git' for an overview of the system.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git --help --config
add.ignoreErrors
advice.addEmbeddedRepo
advice.addEmptyPathspec
advice.addIgnoredFile
advice.amWorkDir
advice.ambiguousFetchRefspec
advice.checkoutAmbiguousRemoteBranchName
advice.commitBeforeMerge
advice.defaultBranchName
advice.detachedHead
advice.diverging
advice.fetchRemoteHEADWarn
advice.fetchShowForcedUpdates
advice.forceDeleteBranch
advice.graftFileDeprecated
advice.ignoredHook
advice.implicitIdentity
advice.mergeConflict
advice.nameTooLong
advice.nestedTag
advice.objectNameWarning
advice.pushAlreadyExists
advice.pushFetchFirst
advice.pushNeedsForce
advice.pushNonFFCurrent
advice.pushNonFFMatching
advice.pushNonFastForward
advice.pushRefNeedsUpdate
advice.pushUnqualifiedRefName
advice.pushUpdateRejected
advice.rebaseTodoError
advice.refSyntax
advice.resetNoRefresh
advice.resolveConflict
advice.rmHints
advice.sequencerInUse
advice.setUpstreamFailure
advice.skippedCherryPicks
advice.sparseIndexExpanded
advice.statusAheadBehindWarning
advice.statusHints
advice.statusUoption
advice.submoduleAlternateErrorStrategyDie
advice.submoduleMergeConflict
advice.submodulesNotUpdated
advice.suggestDetachingHead
advice.updateSparsePath
advice.useCoreFSMonitorConfig
advice.waitingForEditor
advice.worktreeAddOrphan
alias.*
alias.*.command
am.keepcr
am.messageId
am.threeWay
apply.ignoreWhitespace
apply.whitespace
attr.tree
author.email
author.name
bitmapPseudoMerge.<name>.decay
bitmapPseudoMerge.<name>.maxMerges
bitmapPseudoMerge.<name>.pattern
bitmapPseudoMerge.<name>.sampleRate
bitmapPseudoMerge.<name>.stableSize
bitmapPseudoMerge.<name>.stableThreshold
bitmapPseudoMerge.<name>.threshold
blame.blankBoundary
blame.coloring
blame.date
blame.ignoreRevsFile
blame.markIgnoredLines
blame.markUnblamableLines
blame.showEmail
blame.showRoot
branch.<name>.description
branch.<name>.merge
branch.<name>.mergeOptions
branch.<name>.pushRemote
branch.<name>.rebase
branch.<name>.remote
branch.autoSetupMerge
branch.autoSetupRebase
branch.sort
browser.<tool>.cmd
browser.<tool>.path
bundle.*
bundle.<id>.*
bundle.<id>.uri
bundle.heuristic
bundle.mode
bundle.version
checkout.defaultRemote
checkout.guess
checkout.thresholdForParallelism
checkout.workers
clean.requireForce
clone.defaultRemoteName
clone.filterSubmodules
clone.rejectShallow
color.advice
color.advice.hint
color.blame.highlightRecent
color.blame.repeatedLines
color.branch
color.branch.current
color.branch.local
color.branch.plain
color.branch.remote
color.branch.reset
color.branch.upstream
color.branch.worktree
color.decorate.HEAD
color.decorate.branch
color.decorate.grafted
color.decorate.remoteBranch
color.decorate.stash
color.decorate.tag
color.diff
color.diff.commit
color.diff.context
color.diff.contextBold
color.diff.contextDimmed
color.diff.frag
color.diff.func
color.diff.meta
color.diff.new
color.diff.newBold
color.diff.newDimmed
color.diff.newMoved
color.diff.newMovedAlternative
color.diff.newMovedAlternativeDimmed
color.diff.newMovedDimmed
color.diff.old
color.diff.oldBold
color.diff.oldDimmed
color.diff.oldMoved
color.diff.oldMovedAlternative
color.diff.oldMovedAlternativeDimmed
color.diff.oldMovedDimmed
color.diff.plain
color.diff.whitespace
color.grep
color.grep.column
color.grep.context
color.grep.filename
color.grep.function
color.grep.lineNumber
color.grep.match
color.grep.matchContext
color.grep.matchSelected
color.grep.selected
color.grep.separator
color.interactive
color.interactive.error
color.interactive.header
color.interactive.help
color.interactive.plain
color.interactive.prompt
color.interactive.reset
color.pager
color.push
color.push.error
color.remote
color.remote.error
color.remote.hint
color.remote.success
color.remote.warning
color.showBranch
color.status
color.status.added
color.status.branch
color.status.changed
color.status.header
color.status.localBranch
color.status.noBranch
color.status.remoteBranch
color.status.unmerged
color.status.untracked
color.status.updated
color.transport
color.transport.rejected
color.ui
column.branch
column.clean
column.status
column.tag
column.ui
commit.cleanup
commit.gpgSign
commit.status
commit.template
commit.verbose
commitGraph.changedPaths
commitGraph.changedPathsVersion
commitGraph.generationVersion
commitGraph.maxNewFilters
commitGraph.readChangedPaths
committer.email
committer.name
completion.commands
core.WSLCompat
core.abbrev
core.alternateRefsCommand
core.alternateRefsPrefixes
core.askPass
core.attributesFile
core.autocrlf
core.bare
core.bigFileThreshold
core.checkRoundtripEncoding
core.checkStat
core.commentChar
core.commentString
core.commitGraph
core.compression
core.createObject
core.deltaBaseCacheLimit
core.editor
core.eol
core.excludesFile
core.fileMode
core.filesRefLockTimeout
core.fscache
core.fsmonitor
core.fsmonitorHookVersion
core.fsync
core.fsyncMethod
core.fsyncObjectFiles
core.gitProxy
core.hideDotFiles
core.hooksPath
core.ignoreCase
core.ignoreStat
core.lockfilePid
core.logAllRefUpdates
core.longpaths
core.looseCompression
core.maxTreeDepth
core.multiPackIndex
core.notesRef
core.packedGitLimit
core.packedGitWindowSize
core.packedRefsTimeout
core.pager
core.precomposeUnicode
core.preferSymlinkRefs
core.preloadIndex
core.protectHFS
core.protectNTFS
core.quotePath
core.repositoryFormatVersion
core.safecrlf
core.sharedRepository
core.sparseCheckout
core.sparseCheckoutCone
core.splitIndex
core.sshCommand
core.symlinks
core.trustctime
core.unsetenvvars
core.untrackedCache
core.useReplaceRefs
core.warnAmbiguousRefs
core.whitespace
core.worktree
credential.<url>.*
credential.helper
credential.interactive
credential.protectProtocol
credential.sanitizePrompt
credential.useHttpPath
credential.username
credentialCache.ignoreSIGHUP
credentialStore.lockTimeoutMS
diff.<driver>.binary
diff.<driver>.cachetextconv
diff.<driver>.command
diff.<driver>.textconv
diff.<driver>.trustExitCode
diff.<driver>.wordRegex
diff.<driver>.xfuncname
diff.algorithm
diff.autoRefreshIndex
diff.colorMoved
diff.colorMovedWS
diff.context
diff.dirstat
diff.dstPrefix
diff.external
diff.guitool
diff.ignoreSubmodules
diff.indentHeuristic
diff.interHunkContext
diff.mnemonicPrefix
diff.noPrefix
diff.orderFile
diff.relative
diff.renameLimit
diff.renames
diff.srcPrefix
diff.statGraphWidth
diff.statNameWidth
diff.submodule
diff.suppressBlankEmpty
diff.tool
diff.trustExitCode
diff.wordRegex
diff.wsErrorHighlight
difftool.<tool>.cmd
difftool.<tool>.path
difftool.guiDefault
difftool.prompt
difftool.trustExitCode
extensions.*
fastimport.unpackLimit
feature.*
feature.experimental
feature.manyFiles
fetch.all
fetch.bundleCreationToken
fetch.bundleURI
fetch.fsck.<msg-id>
fetch.fsck.skipList
fetch.fsckObjects
fetch.negotiationAlgorithm
fetch.output
fetch.parallel
fetch.prune
fetch.pruneTags
fetch.recurseSubmodules
fetch.showForcedUpdates
fetch.unpackLimit
fetch.writeCommitGraph
filter.<driver>.clean
filter.<driver>.smudge
format.attach
format.cc
format.commitListFormat
format.coverFromDescription
format.coverLetter
format.encodeEmailHeaders
format.filenameMaxLength
format.forceInBodyFrom
format.from
format.headers
format.mboxrd
format.noprefix
format.notes
format.numbered
format.outputDirectory
format.pretty
format.signOff
format.signature
format.signatureFile
format.subjectPrefix
format.suffix
format.thread
format.to
format.useAutoBase
fsck.badDate
fsck.badDateOverflow
fsck.badEmail
fsck.badFilemode
fsck.badGpgsig
fsck.badHeadTarget
fsck.badHeaderContinuation
fsck.badName
fsck.badObjectSha1
fsck.badPackedRefEntry
fsck.badPackedRefHeader
fsck.badParentSha1
fsck.badRefContent
fsck.badRefFiletype
fsck.badRefName
fsck.badRefOid
fsck.badReferentName
fsck.badReftableTableName
fsck.badTagName
fsck.badTimezone
fsck.badTree
fsck.badTreeSha1
fsck.badType
fsck.duplicateEntries
fsck.emptyName
fsck.emptyPackedRefsFile
fsck.extraHeaderEntry
fsck.fullPathname
fsck.gitattributesBlob
fsck.gitattributesLarge
fsck.gitattributesLineLength
fsck.gitattributesMissing
fsck.gitattributesSymlink
fsck.gitignoreSymlink
fsck.gitmodulesBlob
fsck.gitmodulesLarge
fsck.gitmodulesMissing
fsck.gitmodulesName
fsck.gitmodulesParse
fsck.gitmodulesPath
fsck.gitmodulesSymlink
fsck.gitmodulesUpdate
fsck.gitmodulesUrl
fsck.hasDot
fsck.hasDotdot
fsck.hasDotgit
fsck.largePathname
fsck.mailmapSymlink
fsck.missingAuthor
fsck.missingCommitter
fsck.missingEmail
fsck.missingNameBeforeEmail
fsck.missingObject
fsck.missingSpaceBeforeDate
fsck.missingSpaceBeforeEmail
fsck.missingTag
fsck.missingTagEntry
fsck.missingTaggerEntry
fsck.missingTree
fsck.missingType
fsck.missingTypeEntry
fsck.multipleAuthors
fsck.nulInCommit
fsck.nulInHeader
fsck.nullSha1
fsck.packedRefEntryNotTerminated
fsck.packedRefUnsorted
fsck.refMissingNewline
fsck.skipList
fsck.symlinkRef
fsck.symrefTargetIsNotARef
fsck.trailingRefContent
fsck.treeNotSorted
fsck.unknownType
fsck.unterminatedHeader
fsck.zeroPaddedDate
fsck.zeroPaddedFilemode
fsmonitor.allowRemote
fsmonitor.socketDir
gc.<pattern>.reflogExpire
gc.<pattern>.reflogExpireUnreachable
gc.aggressiveDepth
gc.aggressiveWindow
gc.auto
gc.autoDetach
gc.autoPackLimit
gc.bigPackThreshold
gc.cruftPacks
gc.logExpiry
gc.maxCruftSize
gc.packRefs
gc.pruneExpire
gc.recentObjectsHook
gc.reflogExpire
gc.reflogExpireUnreachable
gc.repackFilter
gc.repackFilterTo
gc.rerereResolved
gc.rerereUnresolved
gc.worktreePruneExpire
gc.writeCommitGraph
gitcvs.allBinary
gitcvs.commitMsgAnnotation
gitcvs.dbDriver
gitcvs.dbName
gitcvs.dbPass
gitcvs.dbTableNamePrefix
gitcvs.dbUser
gitcvs.enabled
gitcvs.logFile
gitcvs.usecrlfattr
gitweb.avatar
gitweb.blame
gitweb.category
gitweb.description
gitweb.grep
gitweb.highlight
gitweb.owner
gitweb.patches
gitweb.pickaxe
gitweb.remote_heads
gitweb.showSizes
gitweb.snapshot
gitweb.url
gpg.<format>.program
gpg.format
gpg.minTrustLevel
gpg.program
gpg.ssh.allowedSignersFile
gpg.ssh.defaultKeyCommand
gpg.ssh.revocationFile
grep.column
grep.extendedRegexp
grep.fallbackToNoIndex
grep.fullName
grep.lineNumber
grep.patternType
grep.threads
gui.GCWarning
gui.blamehistoryctx
gui.commitMsgWidth
gui.copyBlameThreshold
gui.diffContext
gui.displayUntracked
gui.encoding
gui.fastCopyBlame
gui.matchTrackingBranch
gui.newBranchTemplate
gui.pruneDuringFetch
gui.spellingDictionary
gui.trustmtime
guitool.<name>.argPrompt
guitool.<name>.cmd
guitool.<name>.confirm
guitool.<name>.needsFile
guitool.<name>.noConsole
guitool.<name>.noRescan
guitool.<name>.prompt
guitool.<name>.revPrompt
guitool.<name>.revUnmerged
guitool.<name>.title
hasconfig:remote.*.url
help.autoCorrect
help.browser
help.format
help.htmlPath
hook.<event>.enabled
hook.<event>.jobs
hook.<friendly-name>.command
hook.<friendly-name>.enabled
hook.<friendly-name>.event
hook.<friendly-name>.parallel
hook.jobs
http.<url>.*
http.allowNTLMAuth
http.cookieFile
http.curloptResolve
http.delegation
http.emptyAuth
http.extraHeader
http.followRedirects
http.keepAliveCount
http.keepAliveIdle
http.keepAliveInterval
http.lowSpeedLimit
http.lowSpeedTime
http.maxRequests
http.maxRetries
http.maxRetryTime
http.minSessions
http.noEPSV
http.pinnedPubkey
http.postBuffer
http.proactiveAuth
http.proxy
http.proxyAuthMethod
http.proxySSLCAInfo
http.proxySSLCert
http.proxySSLCertPasswordProtected
http.proxySSLKey
http.retryAfter
http.saveCookies
http.schannelCheckRevoke
http.schannelUseSSLCAInfo
http.sslAutoClientCert
http.sslBackend
http.sslCAInfo
http.sslCAPath
http.sslCert
http.sslCertPasswordProtected
http.sslCertType
http.sslCipherList
http.sslKey
http.sslKeyType
http.sslTry
http.sslVerify
http.sslVersion
http.userAgent
http.version
i18n.commitEncoding
i18n.logOutputEncoding
imap.authMethod
imap.folder
imap.host
imap.pass
imap.port
imap.preformattedHTML
imap.sslverify
imap.tunnel
imap.user
include.path
includeIf.<condition>.path
index.recordEndOfIndexEntries
index.recordOffsetTable
index.skipHash
index.sparse
index.threads
index.version
init.defaultBranch
init.defaultObjectFormat
init.defaultRefFormat
init.defaultSubmodulePathConfig
init.templateDir
instaweb.browser
instaweb.httpd
instaweb.local
instaweb.modulePath
instaweb.port
interactive.diffFilter
interactive.singleKey
log.abbrevCommit
log.date
log.decorate
log.diffMerges
log.excludeDecoration
log.follow
log.graphColors
log.initialDecorationSet
log.mailmap
log.showRoot
log.showSignature
lsrefs.unborn
mailinfo.scissors
mailmap.blob
mailmap.file
maintenance.<task>.enabled
maintenance.<task>.schedule
maintenance.auto
maintenance.autoDetach
maintenance.commit-graph.auto
maintenance.geometric-repack.auto
maintenance.geometric-repack.splitFactor
maintenance.incremental-repack.auto
maintenance.loose-objects.auto
maintenance.loose-objects.batchSize
maintenance.reflog-expire.auto
maintenance.rerere-gc.auto
maintenance.strategy
maintenance.worktree-prune.auto
man.<tool>.cmd
man.<tool>.path
man.viewer
merge.<driver>.driver
merge.<driver>.name
merge.<driver>.recursive
merge.autoStash
merge.branchdesc
merge.conflictStyle
merge.defaultToUpstream
merge.directoryRenames
merge.ff
merge.guitool
merge.log
merge.renameLimit
merge.renames
merge.renormalize
merge.stat
merge.suppressDest
merge.tool
merge.verbosity
merge.verifySignatures
mergetool.<tool>.cmd
mergetool.<tool>.hideResolved
mergetool.<tool>.path
mergetool.<tool>.trustExitCode
mergetool.<variant>.layout
mergetool.guiDefault
mergetool.hideResolved
mergetool.keepBackup
mergetool.keepTemporaries
mergetool.meld.hasOutput
mergetool.meld.useAutoMerge
mergetool.prompt
mergetool.writeToTemp
notes.<name>.mergeStrategy
notes.displayRef
notes.mergeStrategy
notes.rewrite.<command>
notes.rewriteMode
notes.rewriteRef
pack.allowPackReuse
pack.compression
pack.deltaCacheLimit
pack.deltaCacheSize
pack.depth
pack.indexVersion
pack.island
pack.islandCore
pack.packSizeLimit
pack.preferBitmapTips
pack.readReverseIndex
pack.threads
pack.useBitmapBoundaryTraversal
pack.useBitmaps
pack.usePathWalk
pack.useSparse
pack.window
pack.windowMemory
pack.writeBitmapHashCache
pack.writeBitmapLookupTable
pack.writeReverseIndex
pager.<cmd>
pretty.<name>
promisor.acceptFromServer
promisor.advertise
promisor.checkFields
promisor.quiet
promisor.sendFields
promisor.storeFields
protocol.<name>.allow
protocol.allow
protocol.version
pull.autoStash
pull.ff
pull.octopus
pull.rebase
pull.twohead
push.autoSetupRemote
push.default
push.followTags
push.gpgSign
push.negotiate
push.pushOption
push.recurseSubmodules
push.useBitmaps
push.useForceIfIncludes
rebase.abbreviateCommands
rebase.autoSquash
rebase.autoStash
rebase.backend
rebase.forkPoint
rebase.instructionFormat
rebase.maxLabelLength
rebase.missingCommitsCheck
rebase.rebaseMerges
rebase.rescheduleFailedExec
rebase.stat
rebase.updateRefs
receive.advertiseAtomic
receive.advertisePushOptions
receive.autogc
receive.certNonceSeed
receive.certNonceSlop
receive.denyCurrentBranch
receive.denyDeleteCurrent
receive.denyDeletes
receive.denyNonFastForwards
receive.fsck.badDate
receive.fsck.badDateOverflow
receive.fsck.badEmail
receive.fsck.badFilemode
receive.fsck.badGpgsig
receive.fsck.badHeadTarget
receive.fsck.badHeaderContinuation
receive.fsck.badName
receive.fsck.badObjectSha1
receive.fsck.badPackedRefEntry
receive.fsck.badPackedRefHeader
receive.fsck.badParentSha1
receive.fsck.badRefContent
receive.fsck.badRefFiletype
receive.fsck.badRefName
receive.fsck.badRefOid
receive.fsck.badReferentName
receive.fsck.badReftableTableName
receive.fsck.badTagName
receive.fsck.badTimezone
receive.fsck.badTree
receive.fsck.badTreeSha1
receive.fsck.badType
receive.fsck.duplicateEntries
receive.fsck.emptyName
receive.fsck.emptyPackedRefsFile
receive.fsck.extraHeaderEntry
receive.fsck.fullPathname
receive.fsck.gitattributesBlob
receive.fsck.gitattributesLarge
receive.fsck.gitattributesLineLength
receive.fsck.gitattributesMissing
receive.fsck.gitattributesSymlink
receive.fsck.gitignoreSymlink
receive.fsck.gitmodulesBlob
receive.fsck.gitmodulesLarge
receive.fsck.gitmodulesMissing
receive.fsck.gitmodulesName
receive.fsck.gitmodulesParse
receive.fsck.gitmodulesPath
receive.fsck.gitmodulesSymlink
receive.fsck.gitmodulesUpdate
receive.fsck.gitmodulesUrl
receive.fsck.hasDot
receive.fsck.hasDotdot
receive.fsck.hasDotgit
receive.fsck.largePathname
receive.fsck.mailmapSymlink
receive.fsck.missingAuthor
receive.fsck.missingCommitter
receive.fsck.missingEmail
receive.fsck.missingNameBeforeEmail
receive.fsck.missingObject
receive.fsck.missingSpaceBeforeDate
receive.fsck.missingSpaceBeforeEmail
receive.fsck.missingTag
receive.fsck.missingTagEntry
receive.fsck.missingTaggerEntry
receive.fsck.missingTree
receive.fsck.missingType
receive.fsck.missingTypeEntry
receive.fsck.multipleAuthors
receive.fsck.nulInCommit
receive.fsck.nulInHeader
receive.fsck.nullSha1
receive.fsck.packedRefEntryNotTerminated
receive.fsck.packedRefUnsorted
receive.fsck.refMissingNewline
receive.fsck.skipList
receive.fsck.symlinkRef
receive.fsck.symrefTargetIsNotARef
receive.fsck.trailingRefContent
receive.fsck.treeNotSorted
receive.fsck.unknownType
receive.fsck.unterminatedHeader
receive.fsck.zeroPaddedDate
receive.fsck.zeroPaddedFilemode
receive.fsckObjects
receive.hideRefs
receive.keepAlive
receive.maxInputSize
receive.procReceiveRefs
receive.shallowUpdate
receive.unpackLimit
receive.updateServerInfo
reftable.blockSize
reftable.geometricFactor
reftable.indexObjects
reftable.lockTimeout
reftable.restartInterval
remote.<name>.fetch
remote.<name>.followRemoteHEAD
remote.<name>.mirror
remote.<name>.negotiationInclude
remote.<name>.negotiationRestrict
remote.<name>.partialclonefilter
remote.<name>.promisor
remote.<name>.proxy
remote.<name>.proxyAuthMethod
remote.<name>.prune
remote.<name>.pruneTags
remote.<name>.push
remote.<name>.pushurl
remote.<name>.receivepack
remote.<name>.serverOption
remote.<name>.skipDefaultUpdate
remote.<name>.skipFetchAll
remote.<name>.tagOpt
remote.<name>.uploadpack
remote.<name>.url
remote.<name>.vcs
remote.pushDefault
remotes.<group>
repack.cruftDepth
repack.cruftThreads
repack.cruftWindow
repack.cruftWindowMemory
repack.midxMustContainCruft
repack.midxNewLayerThreshold
repack.midxSplitFactor
repack.packKeptObjects
repack.updateServerInfo
repack.useDeltaBaseOffset
repack.useDeltaIslands
repack.writeBitmaps
replay.refAction
rerere.autoUpdate
rerere.enabled
revert.reference
safe.bareRepository
safe.directory
sendemail.<identity>.*
sendemail.aliasFileType
sendemail.aliasesFile
sendemail.annotate
sendemail.bcc
sendemail.cc
sendemail.ccCmd
sendemail.chainReplyTo
sendemail.confirm
sendemail.envelopeSender
sendemail.forbidSendmailVariables
sendemail.from
sendemail.headerCmd
sendemail.identity
sendemail.imapSentFolder
sendemail.mailmap
sendemail.mailmap.blob
sendemail.mailmap.file
sendemail.multiEdit
sendemail.outlookidfix
sendemail.signedOffByCc
sendemail.smtpBatchSize
sendemail.smtpDomain
sendemail.smtpEncryption
sendemail.smtpPass
sendemail.smtpReloginDelay
sendemail.smtpSSLCertPath
sendemail.smtpSSLClientCert
sendemail.smtpSSLClientKey
sendemail.smtpServer
sendemail.smtpServerOption
sendemail.smtpServerPort
sendemail.smtpUser
sendemail.suppressCc
sendemail.suppressFrom
sendemail.thread
sendemail.to
sendemail.toCmd
sendemail.transferEncoding
sendemail.useImapOnly
sendemail.validate
sendemail.xmailer
sendpack.sideband
sequence.editor
showBranch.default
sideband.<url>.*
sideband.allowControlCharacters
sparse.expectFilesOutsideOfPatterns
splitIndex.maxPercentChange
splitIndex.sharedIndexExpire
ssh.variant
stash.index
stash.showIncludeUntracked
stash.showPatch
stash.showStat
status.aheadBehind
status.branch
status.compareBranches
status.displayCommentPrefix
status.relativePaths
status.renameLimit
status.renames
status.short
status.showStash
status.showUntrackedFiles
status.submoduleSummary
submodule.<name>.active
submodule.<name>.branch
submodule.<name>.fetchRecurseSubmodules
submodule.<name>.gitdir
submodule.<name>.ignore
submodule.<name>.update
submodule.<name>.url
submodule.active
submodule.alternateErrorStrategy
submodule.alternateLocation
submodule.fetchJobs
submodule.propagateBranches
submodule.recurse
survey.*
tag.forceSignAnnotated
tag.gpgSign
tag.sort
tar.umask
trace2.configParams
trace2.destinationDebug
trace2.envVars
trace2.eventBrief
trace2.eventNesting
trace2.eventTarget
trace2.maxFiles
trace2.normalBrief
trace2.normalTarget
trace2.perfBrief
trace2.perfTarget
trailer.<key-alias>.cmd
trailer.<key-alias>.command
trailer.<key-alias>.ifexists
trailer.<key-alias>.ifmissing
trailer.<key-alias>.key
trailer.<key-alias>.where
trailer.ifexists
trailer.ifmissing
trailer.separators
trailer.where
transfer.advertiseObjectInfo
transfer.advertiseSID
transfer.bundleURI
transfer.credentialsInUrl
transfer.fsckObjects
transfer.hideRefs
transfer.unpackLimit
uploadarchive.allowUnreachable
uploadpack.allowAnySHA1InWant
uploadpack.allowFilter
uploadpack.allowReachableSHA1InWant
uploadpack.allowRefInWant
uploadpack.allowTipSHA1InWant
uploadpack.hideRefs
uploadpack.keepAlive
uploadpack.packObjectsHook
uploadpackfilter.<filter>.allow
uploadpackfilter.allow
uploadpackfilter.tree.maxDepth
url.<base>.insteadOf
url.<base>.pushInsteadOf
user.email
user.name
user.signingKey
user.useConfigOnly
versionsort.suffix
web.browser
windows.appendAtomically
worktree.guessRemote
worktree.useRelativePaths
'git help config' for more information
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git --help --user-interfaces
User-facing repository, command and file interfaces:
attributes Defining attributes per path
cli Git command-line interface and conventions
hooks Hooks used by Git
ignore Specifies intentionally untracked files to ignore
mailmap Map author/committer names and/or E-Mail addresses
modules Defining submodule properties
repository-layout Git Repository Layout
revisions Specifying revisions and ranges for Git
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ git --help --developer-interfaces
File formats, protocols and other developer interfaces:
format-bundle The bundle file format
format-chunk Chunk-based file formats
format-commit-graph Git commit-graph format
format-index Git index format
format-pack Git pack format
format-signature Git cryptographic signature formats
protocol-capabilities Protocol v0 and v1 capabilities
protocol-common Things common to various protocols
protocol-http Git HTTP-based protocols
protocol-pack How packs are transferred over-the-wire
protocol-v2 Git Wire Protocol, Version 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/ %cd%=C:\Program Files\Git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) dd68b9a] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1; git -C './repo' branch branch2; git -C './repo' branch branch3; git -C './repo' branch branch4; git -C './repo' branch branch5; git -C './repo' branch branch6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at dd68b9a 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree2' branch2
Preparing worktree (checking out 'branch2')
HEAD is now at dd68b9a 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --lock '../worktree3' branch3
Preparing worktree (checking out 'branch3')
HEAD is now at dd68b9a 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --lock '../worktree4' branch4
Preparing worktree (checking out 'branch4')
HEAD is now at dd68b9a 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --lock --reason='lock reason' '../worktree5' branch5
Preparing worktree (checking out 'branch5')
HEAD is now at dd68b9a 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --lock --reason='lock reason' '../worktree6' branch6
Preparing worktree (checking out 'branch6')
HEAD is now at dd68b9a 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ rm --force --recursive -- './worktree2' './worktree4' './worktree6'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 C:/Program Files/Git/test_git/repo dd68b9a [master]\n
2 C:/Program Files/Git/test_git/worktree1 dd68b9a [branch1]\n
3 C:/Program Files/Git/test_git/worktree2 dd68b9a [branch2] prunable\n
4 C:/Program Files/Git/test_git/worktree3 dd68b9a [branch3] locked\n
5 C:/Program Files/Git/test_git/worktree4 dd68b9a [branch4] locked\n
6 C:/Program Files/Git/test_git/worktree5 dd68b9a [branch5] locked\n
7 C:/Program Files/Git/test_git/worktree6 dd68b9a [branch6] locked\n
8
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 C:/Program Files/Git/test_git/repo dd68b9a [master]\n
2 C:/Program Files/Git/test_git/worktree1 dd68b9a [branch1]\n
3 C:/Program Files/Git/test_git/worktree2 dd68b9a [branch2]\n
4 \tprunable: gitdir file points to non-existent location\n
5 C:/Program Files/Git/test_git/worktree3 dd68b9a [branch3]\n
6 \tlocked: added with --lock\n
7 C:/Program Files/Git/test_git/worktree4 dd68b9a [branch4]\n
8 \tlocked: added with --lock\n
9 C:/Program Files/Git/test_git/worktree5 dd68b9a [branch5]\n
10 \tlocked: lock reason\n
11 C:/Program Files/Git/test_git/worktree6 dd68b9a [branch6]\n
12 \tlocked: lock reason\n
13
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --porcelain | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 worktree C:/Program Files/Git/test_git/repo\n
2 HEAD dd68b9a331669b558014a694514698763cd186a7\n
3 branch refs/heads/master\n
4 \n
5 worktree C:/Program Files/Git/test_git/worktree1\n
6 HEAD dd68b9a331669b558014a694514698763cd186a7\n
7 branch refs/heads/branch1\n
8 \n
9 worktree C:/Program Files/Git/test_git/worktree2\n
10 HEAD dd68b9a331669b558014a694514698763cd186a7\n
11 branch refs/heads/branch2\n
12 prunable gitdir file points to non-existent location\n
13 \n
14 worktree C:/Program Files/Git/test_git/worktree3\n
15 HEAD dd68b9a331669b558014a694514698763cd186a7\n
16 branch refs/heads/branch3\n
17 locked added with --lock\n
18 \n
19 worktree C:/Program Files/Git/test_git/worktree4\n
20 HEAD dd68b9a331669b558014a694514698763cd186a7\n
21 branch refs/heads/branch4\n
22 locked added with --lock\n
23 \n
24 worktree C:/Program Files/Git/test_git/worktree5\n
25 HEAD dd68b9a331669b558014a694514698763cd186a7\n
26 branch refs/heads/branch5\n
27 locked lock reason\n
28 \n
29 worktree C:/Program Files/Git/test_git/worktree6\n
30 HEAD dd68b9a331669b558014a694514698763cd186a7\n
31 branch refs/heads/branch6\n
32 locked lock reason\n
33 \n
34
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --porcelain -z | special_character_to_escape_sequence_preserve_line_ending | cat_with_line_number
1 worktree C:/Program Files/Git/test_git/repo\0HEAD dd68b9a331669b558014a694514698763cd186a7\0branch refs/heads/master\0\0worktree C:/Program Files/Git/test_git/worktree1\0HEAD dd68b9a331669b558014a694514698763cd186a7\0branch refs/heads/branch1\0\0worktree C:/Program Files/Git/test_git/worktree2\0HEAD dd68b9a331669b558014a694514698763cd186a7\0branch refs/heads/branch2\0prunable gitdir file points to non-existent location\0\0worktree C:/Program Files/Git/test_git/worktree3\0HEAD dd68b9a331669b558014a694514698763cd186a7\0branch refs/heads/branch3\0locked added with --lock\0\0worktree C:/Program Files/Git/test_git/worktree4\0HEAD dd68b9a331669b558014a694514698763cd186a7\0branch refs/heads/branch4\0locked added with --lock\0\0worktree C:/Program Files/Git/test_git/worktree5\0HEAD dd68b9a331669b558014a694514698763cd186a7\0branch refs/heads/branch5\0locked lock reason\0\0worktree C:/Program Files/Git/test_git/worktree6\0HEAD dd68b9a331669b558014a694514698763cd186a7\0branch refs/heads/branch6\0locked lock reason\0\0
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) ead3115] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo ead3115 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* ead3115 - 2026-07-07 23:11 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at ead3115 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master 8273dc8] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 8273dc8 [master]
C:/Program Files/Git/test_git/worktree1 ead3115 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 8273dc8 - 2026-07-07 23:11 (1 second ago) 2 - Han Jiang (HEAD -> refs/heads/master)
* ead3115 - 2026-07-07 23:11 (3 seconds ago) 1 - Han Jiang (refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 8273dc8 [master]
C:/Program Files/Git/test_git/worktree1 ead3115 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 8273dc8 - 2026-07-07 23:11 (3 seconds ago) 2 - Han Jiang (refs/heads/master)
* ead3115 - 2026-07-07 23:11 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' commit --message="$((++number))" --allow-empty
[branch1 9614a5c] 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 8273dc8 [master]
C:/Program Files/Git/test_git/worktree1 9614a5c [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 9614a5c - 2026-07-07 23:11 (1 second ago) 3 - Han Jiang (refs/heads/branch1)
| * 8273dc8 - 2026-07-07 23:11 (4 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
|/
* ead3115 - 2026-07-07 23:11 (6 seconds ago) 1 - Han Jiang
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 8273dc8 [master]
C:/Program Files/Git/test_git/worktree1 9614a5c [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 9614a5c - 2026-07-07 23:11 (2 seconds ago) 3 - Han Jiang (HEAD -> refs/heads/branch1)
| * 8273dc8 - 2026-07-07 23:11 (5 seconds ago) 2 - Han Jiang (refs/heads/master)
|/
* ead3115 - 2026-07-07 23:11 (7 seconds ago) 1 - Han Jiang
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴COMMIT_EDITMSG -/0o100/regular file rw-r--r--/0o644
│ │ ├╴config -/0o100/regular file rw-r--r--/0o644
│ │ ├╴description -/0o100/regular file rw-r--r--/0o644
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴index -/0o100/regular file rw-r--r--/0o644
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ │ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ │ ├╴branch1 -/0o100/regular file rw-r--r--/0o644
│ │ │ │ │ ├╴master -/0o100/regular file rw-r--r--/0o644
│ │ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴4b/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴825dc642cb6eb9a060e54bf8d69288fbee4904 -/0o100/regular file r--r--r--/0o444
│ │ │ ├╴82/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴73dc8d0eb392f4b7c3918ee30aafe0bf3972af -/0o100/regular file r--r--r--/0o444
│ │ │ ├╴96/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴14a5cf4d80330b1f1e98deaeada4a0b64dfc9e -/0o100/regular file r--r--r--/0o444
│ │ │ ├╴ea/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴d31157afdd0b97bd904b42b54a80608f86a295 -/0o100/regular file r--r--r--/0o444
│ │ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴branch1 -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴master -/0o100/regular file rw-r--r--/0o644
│ │ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴worktrees/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴COMMIT_EDITMSG -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴index -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git -/0o100/regular file rw-r--r--/0o644
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees' './worktree1'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴COMMIT_EDITMSG -/0o100/regular file rw-r--r--/0o644
│ │ 1 3\n
│ │ 2
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 ead31157afdd0b97bd904b42b54a80608f86a295 Han Jiang <jhcarl0814@gmail.com> 1783422713 +1200\n
│ │ │ 2 ead31157afdd0b97bd904b42b54a80608f86a295 ead31157afdd0b97bd904b42b54a80608f86a295 Han Jiang <jhcarl0814@gmail.com> 1783422713 +1200\treset: moving to HEAD\n
│ │ │ 3 ead31157afdd0b97bd904b42b54a80608f86a295 9614a5cf4d80330b1f1e98deaeada4a0b64dfc9e Han Jiang <jhcarl0814@gmail.com> 1783422716 +1200\tcommit: 3\n
│ │ │ 4
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ead31157afdd0b97bd904b42b54a80608f86a295\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
./worktree1/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 7197ba4] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' checkout -b branch1
Switched to a new branch 'branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 7197ba4 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 7197ba4 - 2026-07-07 23:12 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
fatal: 'branch1' is already used by worktree at 'C:/Program Files/Git/test_git/repo'
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --force '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at 7197ba4 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 7197ba4 [branch1]
C:/Program Files/Git/test_git/worktree1 7197ba4 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 7197ba4 - 2026-07-07 23:12 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 7197ba4 [branch1]
C:/Program Files/Git/test_git/worktree1 7197ba4 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 7197ba4 - 2026-07-07 23:12 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 221281b] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 221281b [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 221281b - 2026-07-07 23:12 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at 221281b 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 221281b [master]
C:/Program Files/Git/test_git/worktree1 221281b [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ rm --force --recursive -- './worktree1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 221281b [master]
C:/Program Files/Git/test_git/worktree1 221281b [branch1]
prunable: gitdir file points to non-existent location
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
fatal: '../worktree1' is a missing but already registered worktree;
use 'add -f' to override, or 'prune' or 'remove' to clear
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --force '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at 221281b 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 221281b [master]
C:/Program Files/Git/test_git/worktree1 221281b [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 221281b - 2026-07-07 23:12 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 221281b [master]
C:/Program Files/Git/test_git/worktree1 221281b [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 221281b - 2026-07-07 23:12 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) ae40a48] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo ae40a48 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* ae40a48 - 2026-07-07 23:12 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --lock '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at ae40a48 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo ae40a48 [master]
C:/Program Files/Git/test_git/worktree1 ae40a48 [branch1]
locked: added with --lock
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ rm --force --recursive -- './worktree1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo ae40a48 [master]
C:/Program Files/Git/test_git/worktree1 ae40a48 [branch1]
locked: added with --lock
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
fatal: '../worktree1' is a missing but locked worktree;
use 'add -f -f' to override, or 'unlock' and 'prune' or 'remove' to clear
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --force '../worktree1' branch1
Preparing worktree (checking out 'branch1')
fatal: '../worktree1' is a missing but locked worktree;
use 'add -f -f' to override, or 'unlock' and 'prune' or 'remove' to clear
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --force --force '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at ae40a48 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo ae40a48 [master]
C:/Program Files/Git/test_git/worktree1 ae40a48 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* ae40a48 - 2026-07-07 23:12 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo ae40a48 [master]
C:/Program Files/Git/test_git/worktree1 ae40a48 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* ae40a48 - 2026-07-07 23:12 (6 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
if without --orphan would checkout existent local branch, error out; otherwise create a new worktree with empty index, empty working tree and unborn branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 0636d3b] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 0636d3b [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 0636d3b - 2026-07-07 23:12 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --orphan '../branch1'
Preparing worktree (new branch 'branch1')
fatal: a branch named 'branch1' already exists
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --orphan '../worktree1'
Preparing worktree (new branch 'worktree1')
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 0636d3b [master]
C:/Program Files/Git/test_git/worktree1 0000000 [worktree1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 0636d3b - 2026-07-07 23:12 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 0636d3b [master]
C:/Program Files/Git/test_git/worktree1 0000000 [worktree1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 0636d3b - 2026-07-07 23:12 (5 seconds ago) 1 - Han Jiang (refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' branch --show-current
worktree1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
create a new worktree with empty index, empty working tree and unborn branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 3b43b02] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 3b43b02 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 3b43b02 - 2026-07-07 23:13 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --orphan -b branch1 '../worktree1'
Preparing worktree (new branch 'branch1')
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 3b43b02 [master]
C:/Program Files/Git/test_git/worktree1 0000000 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 3b43b02 - 2026-07-07 23:13 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 3b43b02 [master]
C:/Program Files/Git/test_git/worktree1 0000000 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 3b43b02 - 2026-07-07 23:13 (4 seconds ago) 1 - Han Jiang (refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' branch --show-current
branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
if without --orphan would reset existent local branch, error out; otherwise create a new worktree with empty index, empty working tree and unborn branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) ec8d044] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo ec8d044 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* ec8d044 - 2026-07-07 23:13 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --orphan -B branch1 '../worktree1'
Preparing worktree (resetting branch 'branch1'; was at ec8d044)
fatal: a branch named 'branch1' already exists
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --delete branch1
Deleted branch branch1 (was ec8d044).
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --orphan -B branch1 '../worktree1'
Preparing worktree (new branch 'branch1')
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo ec8d044 [master]
C:/Program Files/Git/test_git/worktree1 0000000 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* ec8d044 - 2026-07-07 23:13 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo ec8d044 [master]
C:/Program Files/Git/test_git/worktree1 0000000 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* ec8d044 - 2026-07-07 23:13 (5 seconds ago) 1 - Han Jiang (refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' branch --show-current
branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
isn't allowed
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 1809f56] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 1809f56 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 1809f56 - 2026-07-07 23:13 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --orphan --detach '../worktree1'
fatal: options '--orphan' and '--detach' cannot be used together
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
(see below)
create new branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) a3fa29e] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo a3fa29e [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* a3fa29e - 2026-07-07 23:13 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add -b branch1 '../worktree1'
Preparing worktree (new branch 'branch1')
fatal: a branch named 'branch1' already exists
jhcarl0814@jhcarl0814 MINGW64 $?=255 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add -b branch2 '../worktree1'
Preparing worktree (new branch 'branch2')
HEAD is now at a3fa29e 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo a3fa29e [master]
C:/Program Files/Git/test_git/worktree1 a3fa29e [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* a3fa29e - 2026-07-07 23:13 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo a3fa29e [master]
C:/Program Files/Git/test_git/worktree1 a3fa29e [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* a3fa29e - 2026-07-07 23:13 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch2, refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
create new branch or reset existent local branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 5029fd1] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 5029fd1 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 5029fd1 - 2026-07-07 23:13 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add -b branch1 '../worktree1'
Preparing worktree (new branch 'branch1')
fatal: a branch named 'branch1' already exists
jhcarl0814@jhcarl0814 MINGW64 $?=255 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add -B branch1 '../worktree1'
Preparing worktree (resetting branch 'branch1'; was at 5029fd1)
HEAD is now at 5029fd1 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 5029fd1 [master]
C:/Program Files/Git/test_git/worktree1 5029fd1 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 5029fd1 - 2026-07-07 23:13 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 5029fd1 [master]
C:/Program Files/Git/test_git/worktree1 5029fd1 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 5029fd1 - 2026-07-07 23:13 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
new worktree's HEAD is detached
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) f5ac76a] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo f5ac76a [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* f5ac76a - 2026-07-07 23:13 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --detach '../worktree1'
Preparing worktree (detached HEAD f5ac76a)
HEAD is now at f5ac76a 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo f5ac76a [master]
C:/Program Files/Git/test_git/worktree1 f5ac76a (detached HEAD)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* f5ac76a - 2026-07-07 23:13 (2 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo f5ac76a [master]
C:/Program Files/Git/test_git/worktree1 f5ac76a (detached HEAD)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* f5ac76a - 2026-07-07 23:13 (3 seconds ago) 1 - Han Jiang (HEAD, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
(see below)
behaves as if --orphan is used
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 0000000 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add -b branch1 '../worktree1'
No possible source branch, inferring '--orphan'
Preparing worktree (new branch 'branch1')
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 0000000 [master]
C:/Program Files/Git/test_git/worktree1 0000000 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 0000000 [master]
C:/Program Files/Git/test_git/worktree1 0000000 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' branch --show-current
branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
behaves as if --orphan is used
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' checkout --orphan branch1
Switched to a new branch 'branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 0000000 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add -B branch1 '../worktree1'
No possible source branch, inferring '--orphan'
Preparing worktree (new branch 'branch1')
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 0000000 [branch1]
C:/Program Files/Git/test_git/worktree1 0000000 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 0000000 [branch1]
C:/Program Files/Git/test_git/worktree1 0000000 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' branch --show-current
branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
error out with message saying --orphan should be used
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 0000000 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --detach '../worktree1'
hint: If you meant to create a worktree containing a new unborn branch
hint: (branch with no commits) for this repository, you can do so
hint: using the --orphan flag:
hint:
hint: git worktree add --orphan ../worktree1
hint:
hint: Disable this message with "git config set advice.worktreeAddOrphan false"
fatal: invalid reference: HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
checkout the existent local branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 454a20e] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 454a20e [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 454a20e - 2026-07-07 23:14 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at 454a20e 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master 56a1ad9] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 56a1ad9 [master]
C:/Program Files/Git/test_git/worktree1 454a20e [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 56a1ad9 - 2026-07-07 23:14 (2 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
* 454a20e - 2026-07-07 23:14 (4 seconds ago) 1 - Han Jiang (refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 56a1ad9 [master]
C:/Program Files/Git/test_git/worktree1 454a20e [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 56a1ad9 - 2026-07-07 23:14 (3 seconds ago) 2 - Han Jiang (refs/heads/master)
* 454a20e - 2026-07-07 23:14 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' commit --message="$((++number))" --allow-empty
[branch1 5419211] 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 56a1ad9 [master]
C:/Program Files/Git/test_git/worktree1 5419211 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 5419211 - 2026-07-07 23:14 (1 second ago) 3 - Han Jiang (refs/heads/branch1)
| * 56a1ad9 - 2026-07-07 23:14 (5 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
|/
* 454a20e - 2026-07-07 23:14 (7 seconds ago) 1 - Han Jiang
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 56a1ad9 [master]
C:/Program Files/Git/test_git/worktree1 5419211 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 5419211 - 2026-07-07 23:14 (2 seconds ago) 3 - Han Jiang (HEAD -> refs/heads/branch1)
| * 56a1ad9 - 2026-07-07 23:14 (6 seconds ago) 2 - Han Jiang (refs/heads/master)
|/
* 454a20e - 2026-07-07 23:14 (8 seconds ago) 1 - Han Jiang
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
when 0 or more than 1 remotes have tracking branch with matching name
error out
when more than 1 remotes have tracking branch with matching name but one of the remote is checkout.defaultRemote, or 1 remote has tracking branch with matching name
equivalent to git worktree add -b <branch> --track <path> <remote-tracking branch>
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server1/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server1/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 329e11a] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' branch branch2; git -C './server1/repo.git' branch branch3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server2' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server2/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server2/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) e79161c] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server2/repo.git' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server1 'file://'"$(realpath './server1/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server2 'file://'"$(realpath './server2/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
Fetching server1
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 19.00 KiB/s, done.
From file:///test_git/server1/repo
* [new branch] branch2 -> server1/branch2
* [new branch] branch3 -> server1/branch3
* [new branch] master -> server1/master
Fetching server2
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 27.00 KiB/s, done.
From file:///test_git/server2/repo
* [new branch] branch2 -> server2/branch2
* [new branch] master -> server2/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 329e11a 1
remotes/server1/branch3 329e11a 1
remotes/server1/master 329e11a 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 e79161c 2
remotes/server2/master e79161c 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
* e79161c - 2026-07-07 23:14 (4 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* 329e11a - 2026-07-07 23:14 (6 seconds ago) 1 - Han Jiang (refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add '../worktree1' branch1
fatal: invalid reference: branch1
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add '../worktree2' branch2
fatal: invalid reference: branch2
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' -c checkout.defaultRemote='server1' worktree add '../worktree2' branch2
Preparing worktree (new branch 'branch2')
branch 'branch2' set up to track 'server1/branch2'.
HEAD is now at 329e11a 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add '../worktree3' branch3
Preparing worktree (new branch 'branch3')
branch 'branch3' set up to track 'server1/branch3'.
HEAD is now at 329e11a 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
+ branch2 329e11a (C:/Program Files/Git/test_git/client/worktree2) [server1/branch2] 1
+ branch3 329e11a (C:/Program Files/Git/test_git/client/worktree3) [server1/branch3] 1
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 329e11a 1
remotes/server1/branch3 329e11a 1
remotes/server1/master 329e11a 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 e79161c 2
remotes/server2/master e79161c 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
C:/Program Files/Git/test_git/client/worktree2 329e11a [branch2]
C:/Program Files/Git/test_git/client/worktree3 329e11a [branch3]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
* e79161c - 2026-07-07 23:14 (8 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* 329e11a - 2026-07-07 23:14 (10 seconds ago) 1 - Han Jiang (refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD, refs/heads/branch3, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree2' branch --list --all --verbose --verbose
* branch2 329e11a [server1/branch2] 1
+ branch3 329e11a (C:/Program Files/Git/test_git/client/worktree3) [server1/branch3] 1
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 329e11a 1
remotes/server1/branch3 329e11a 1
remotes/server1/master 329e11a 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 e79161c 2
remotes/server2/master e79161c 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree2' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
C:/Program Files/Git/test_git/client/worktree2 329e11a [branch2]
C:/Program Files/Git/test_git/client/worktree3 329e11a [branch3]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree2' lg --all
* e79161c - 2026-07-07 23:14 (9 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* 329e11a - 2026-07-07 23:14 (11 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch2, refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD, refs/heads/branch3)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree3' branch --list --all --verbose --verbose
+ branch2 329e11a (C:/Program Files/Git/test_git/client/worktree2) [server1/branch2] 1
* branch3 329e11a [server1/branch3] 1
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 329e11a 1
remotes/server1/branch3 329e11a 1
remotes/server1/master 329e11a 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 e79161c 2
remotes/server2/master e79161c 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree3' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
C:/Program Files/Git/test_git/client/worktree2 329e11a [branch2]
C:/Program Files/Git/test_git/client/worktree3 329e11a [branch3]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree3' lg --all
* e79161c - 2026-07-07 23:14 (10 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* 329e11a - 2026-07-07 23:14 (12 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch3, refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
checkout the existent local branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 4d6958d] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 4d6958d [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 4d6958d - 2026-07-07 23:14 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../branch1'
Preparing worktree (checking out 'branch1')
HEAD is now at 4d6958d 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 4d6958d [master]
C:/Program Files/Git/test_git/branch1 4d6958d [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 4d6958d - 2026-07-07 23:14 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './branch1' worktree list --verbose
C:/Program Files/Git/test_git/repo 4d6958d [master]
C:/Program Files/Git/test_git/branch1 4d6958d [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './branch1' lg --all
* 4d6958d - 2026-07-07 23:14 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
(see below)
create new branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 0f779a2] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 0f779a2 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 0f779a2 - 2026-07-07 23:14 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1'
Preparing worktree (new branch 'worktree1')
HEAD is now at 0f779a2 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 0f779a2 [master]
C:/Program Files/Git/test_git/worktree1 0f779a2 [worktree1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 0f779a2 - 2026-07-07 23:14 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/worktree1, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 0f779a2 [master]
C:/Program Files/Git/test_git/worktree1 0f779a2 [worktree1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 0f779a2 - 2026-07-07 23:14 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/worktree1, refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
behaves as if --orphan is used
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 0000000 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1'
No possible source branch, inferring '--orphan'
Preparing worktree (new branch 'worktree1')
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 0000000 [master]
C:/Program Files/Git/test_git/worktree1 0000000 [worktree1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 0000000 [master]
C:/Program Files/Git/test_git/worktree1 0000000 [worktree1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' branch --show-current
worktree1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
needs --force, behaves as if --orphan is used
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server 'file://'"$(realpath './server/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote '../worktree'
fatal: No local or remote refs exist despite at least one remote
present, stopping; use 'add -f' to override or fetch a remote first
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote --force '../worktree'
No possible source branch, inferring '--orphan'
Preparing worktree (new branch 'worktree')
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
C:/Program Files/Git/test_git/client/worktree 0000000 [worktree]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
C:/Program Files/Git/test_git/client/worktree 0000000 [worktree]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree' lg --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree' branch --show-current
worktree
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
when 0 or more than 1 remotes have tracking branch with matching name
error out saying "use --orphan"
when more than 1 remotes have tracking branch with matching name but one of the remote is checkout.defaultRemote, or 1 remote has tracking branch with matching name
equivalent to git worktree add -b "$(basename <path>)" --track <path> <remote-tracking branch>
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server1/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server1/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) e1db344] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' branch branch2; git -C './server1/repo.git' branch branch3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server2' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server2/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server2/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 7de8ba3] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server2/repo.git' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server1 'file://'"$(realpath './server1/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server2 'file://'"$(realpath './server2/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
Fetching server1
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 23.00 KiB/s, done.
From file:///test_git/server1/repo
* [new branch] branch2 -> server1/branch2
* [new branch] branch3 -> server1/branch3
* [new branch] master -> server1/master
Fetching server2
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 23.00 KiB/s, done.
From file:///test_git/server2/repo
* [new branch] branch2 -> server2/branch2
* [new branch] master -> server2/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 e1db344 1
remotes/server1/branch3 e1db344 1
remotes/server1/master e1db344 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 7de8ba3 2
remotes/server2/master 7de8ba3 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
* 7de8ba3 - 2026-07-07 23:15 (4 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* e1db344 - 2026-07-07 23:15 (6 seconds ago) 1 - Han Jiang (refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote '../branch1'
hint: If you meant to create a worktree containing a new unborn branch
hint: (branch with no commits) for this repository, you can do so
hint: using the --orphan flag:
hint:
hint: git worktree add --orphan ../branch1
hint:
hint: Disable this message with "git config set advice.worktreeAddOrphan false"
fatal: invalid reference: HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote --force '../branch1'
hint: If you meant to create a worktree containing a new unborn branch
hint: (branch with no commits) for this repository, you can do so
hint: using the --orphan flag:
hint:
hint: git worktree add --orphan ../branch1
hint:
hint: Disable this message with "git config set advice.worktreeAddOrphan false"
fatal: invalid reference: HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote --force --force '../branch1'
hint: If you meant to create a worktree containing a new unborn branch
hint: (branch with no commits) for this repository, you can do so
hint: using the --orphan flag:
hint:
hint: git worktree add --orphan ../branch1
hint:
hint: Disable this message with "git config set advice.worktreeAddOrphan false"
fatal: invalid reference: HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote '../branch2'
hint: If you meant to create a worktree containing a new unborn branch
hint: (branch with no commits) for this repository, you can do so
hint: using the --orphan flag:
hint:
hint: git worktree add --orphan ../branch2
hint:
hint: Disable this message with "git config set advice.worktreeAddOrphan false"
fatal: invalid reference: HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote --force '../branch2'
hint: If you meant to create a worktree containing a new unborn branch
hint: (branch with no commits) for this repository, you can do so
hint: using the --orphan flag:
hint:
hint: git worktree add --orphan ../branch2
hint:
hint: Disable this message with "git config set advice.worktreeAddOrphan false"
fatal: invalid reference: HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote --force --force '../branch2'
hint: If you meant to create a worktree containing a new unborn branch
hint: (branch with no commits) for this repository, you can do so
hint: using the --orphan flag:
hint:
hint: git worktree add --orphan ../branch2
hint:
hint: Disable this message with "git config set advice.worktreeAddOrphan false"
fatal: invalid reference: HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' -c checkout.defaultRemote='server1' worktree add --guess-remote '../branch2'
Preparing worktree (new branch 'branch2')
branch 'branch2' set up to track 'server1/branch2'.
HEAD is now at e1db344 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote '../branch3'
Preparing worktree (new branch 'branch3')
branch 'branch3' set up to track 'server1/branch3'.
HEAD is now at e1db344 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
+ branch2 e1db344 (C:/Program Files/Git/test_git/client/branch2) [server1/branch2] 1
+ branch3 e1db344 (C:/Program Files/Git/test_git/client/branch3) [server1/branch3] 1
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 e1db344 1
remotes/server1/branch3 e1db344 1
remotes/server1/master e1db344 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 7de8ba3 2
remotes/server2/master 7de8ba3 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
C:/Program Files/Git/test_git/client/branch2 e1db344 [branch2]
C:/Program Files/Git/test_git/client/branch3 e1db344 [branch3]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
* 7de8ba3 - 2026-07-07 23:15 (9 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* e1db344 - 2026-07-07 23:15 (11 seconds ago) 1 - Han Jiang (refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD, refs/heads/branch3, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/branch2' branch --list --all --verbose --verbose
* branch2 e1db344 [server1/branch2] 1
+ branch3 e1db344 (C:/Program Files/Git/test_git/client/branch3) [server1/branch3] 1
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 e1db344 1
remotes/server1/branch3 e1db344 1
remotes/server1/master e1db344 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 7de8ba3 2
remotes/server2/master 7de8ba3 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/branch2' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
C:/Program Files/Git/test_git/client/branch2 e1db344 [branch2]
C:/Program Files/Git/test_git/client/branch3 e1db344 [branch3]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/branch2' lg --all
* 7de8ba3 - 2026-07-07 23:15 (11 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* e1db344 - 2026-07-07 23:15 (13 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch2, refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD, refs/heads/branch3)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/branch3' branch --list --all --verbose --verbose
+ branch2 e1db344 (C:/Program Files/Git/test_git/client/branch2) [server1/branch2] 1
* branch3 e1db344 [server1/branch3] 1
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 e1db344 1
remotes/server1/branch3 e1db344 1
remotes/server1/master e1db344 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 7de8ba3 2
remotes/server2/master 7de8ba3 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/branch3' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
C:/Program Files/Git/test_git/client/branch2 e1db344 [branch2]
C:/Program Files/Git/test_git/client/branch3 e1db344 [branch3]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/branch3' lg --all
* 7de8ba3 - 2026-07-07 23:15 (12 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* e1db344 - 2026-07-07 23:15 (14 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch3, refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server1/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server1/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 0f0ae2e] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' branch branch2; git -C './server1/repo.git' branch branch3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server2' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server2/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server2/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 1597294] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server2/repo.git' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server1 'file://'"$(realpath './server1/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server2 'file://'"$(realpath './server2/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
Fetching server1
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 23.00 KiB/s, done.
From file:///test_git/server1/repo
* [new branch] branch2 -> server1/branch2
* [new branch] branch3 -> server1/branch3
* [new branch] master -> server1/master
Fetching server2
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 27.00 KiB/s, done.
From file:///test_git/server2/repo
* [new branch] branch2 -> server2/branch2
* [new branch] master -> server2/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 0f0ae2e 1
remotes/server1/branch3 0f0ae2e 1
remotes/server1/master 0f0ae2e 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 1597294 2
remotes/server2/master 1597294 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
* 1597294 - 2026-07-07 23:15 (5 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* 0f0ae2e - 2026-07-07 23:15 (6 seconds ago) 1 - Han Jiang (refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ HEAD_old="$(git -C './client/repo' symbolic-ref HEAD)"; echo "$HEAD_old"
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' checkout --orphan branch0
Switched to a new branch 'branch0'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --show-current
branch0
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' symbolic-ref HEAD
refs/heads/branch0
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' commit --message="$((++number))" --allow-empty
[branch0 (root-commit) f9b1a92] 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' symbolic-ref HEAD "$HEAD_old"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' symbolic-ref HEAD
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote '../branch1'
warning: HEAD points to an invalid (or orphaned) reference.
hint: If you meant to create a worktree containing a new unborn branch
hint: (branch with no commits) for this repository, you can do so
hint: using the --orphan flag:
hint:
hint: git worktree add --orphan ../branch1
hint:
hint: Disable this message with "git config set advice.worktreeAddOrphan false"
fatal: invalid reference: HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote --force '../branch1'
warning: HEAD points to an invalid (or orphaned) reference.
hint: If you meant to create a worktree containing a new unborn branch
hint: (branch with no commits) for this repository, you can do so
hint: using the --orphan flag:
hint:
hint: git worktree add --orphan ../branch1
hint:
hint: Disable this message with "git config set advice.worktreeAddOrphan false"
fatal: invalid reference: HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote --force --force '../branch1'
warning: HEAD points to an invalid (or orphaned) reference.
hint: If you meant to create a worktree containing a new unborn branch
hint: (branch with no commits) for this repository, you can do so
hint: using the --orphan flag:
hint:
hint: git worktree add --orphan ../branch1
hint:
hint: Disable this message with "git config set advice.worktreeAddOrphan false"
fatal: invalid reference: HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote '../branch2'
warning: HEAD points to an invalid (or orphaned) reference.
hint: If you meant to create a worktree containing a new unborn branch
hint: (branch with no commits) for this repository, you can do so
hint: using the --orphan flag:
hint:
hint: git worktree add --orphan ../branch2
hint:
hint: Disable this message with "git config set advice.worktreeAddOrphan false"
fatal: invalid reference: HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote --force '../branch2'
warning: HEAD points to an invalid (or orphaned) reference.
hint: If you meant to create a worktree containing a new unborn branch
hint: (branch with no commits) for this repository, you can do so
hint: using the --orphan flag:
hint:
hint: git worktree add --orphan ../branch2
hint:
hint: Disable this message with "git config set advice.worktreeAddOrphan false"
fatal: invalid reference: HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote --force --force '../branch2'
warning: HEAD points to an invalid (or orphaned) reference.
hint: If you meant to create a worktree containing a new unborn branch
hint: (branch with no commits) for this repository, you can do so
hint: using the --orphan flag:
hint:
hint: git worktree add --orphan ../branch2
hint:
hint: Disable this message with "git config set advice.worktreeAddOrphan false"
fatal: invalid reference: HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' -c checkout.defaultRemote='server1' worktree add --guess-remote '../branch2'
Preparing worktree (new branch 'branch2')
branch 'branch2' set up to track 'server1/branch2'.
HEAD is now at 0f0ae2e 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --guess-remote '../branch3'
Preparing worktree (new branch 'branch3')
branch 'branch3' set up to track 'server1/branch3'.
HEAD is now at 0f0ae2e 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
branch0 f9b1a92 3
+ branch2 0f0ae2e (C:/Program Files/Git/test_git/client/branch2) [server1/branch2] 1
+ branch3 0f0ae2e (C:/Program Files/Git/test_git/client/branch3) [server1/branch3] 1
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 0f0ae2e 1
remotes/server1/branch3 0f0ae2e 1
remotes/server1/master 0f0ae2e 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 1597294 2
remotes/server2/master 1597294 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
C:/Program Files/Git/test_git/client/branch2 0f0ae2e [branch2]
C:/Program Files/Git/test_git/client/branch3 0f0ae2e [branch3]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
* f9b1a92 - 2026-07-07 23:15 (6 seconds ago) 3 - Han Jiang (refs/heads/branch0)
* 1597294 - 2026-07-07 23:15 (14 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* 0f0ae2e - 2026-07-07 23:15 (15 seconds ago) 1 - Han Jiang (refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD, refs/heads/branch3, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/branch2' branch --list --all --verbose --verbose
branch0 f9b1a92 3
* branch2 0f0ae2e [server1/branch2] 1
+ branch3 0f0ae2e (C:/Program Files/Git/test_git/client/branch3) [server1/branch3] 1
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 0f0ae2e 1
remotes/server1/branch3 0f0ae2e 1
remotes/server1/master 0f0ae2e 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 1597294 2
remotes/server2/master 1597294 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/branch2' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
C:/Program Files/Git/test_git/client/branch2 0f0ae2e [branch2]
C:/Program Files/Git/test_git/client/branch3 0f0ae2e [branch3]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/branch2' lg --all
* f9b1a92 - 2026-07-07 23:15 (7 seconds ago) 3 - Han Jiang (refs/heads/branch0)
* 1597294 - 2026-07-07 23:15 (15 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* 0f0ae2e - 2026-07-07 23:15 (16 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch2, refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD, refs/heads/branch3)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/branch3' branch --list --all --verbose --verbose
branch0 f9b1a92 3
+ branch2 0f0ae2e (C:/Program Files/Git/test_git/client/branch2) [server1/branch2] 1
* branch3 0f0ae2e [server1/branch3] 1
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 0f0ae2e 1
remotes/server1/branch3 0f0ae2e 1
remotes/server1/master 0f0ae2e 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 1597294 2
remotes/server2/master 1597294 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/branch3' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
C:/Program Files/Git/test_git/client/branch2 0f0ae2e [branch2]
C:/Program Files/Git/test_git/client/branch3 0f0ae2e [branch3]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/branch3' lg --all
* f9b1a92 - 2026-07-07 23:15 (9 seconds ago) 3 - Han Jiang (refs/heads/branch0)
* 1597294 - 2026-07-07 23:15 (17 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* 0f0ae2e - 2026-07-07 23:15 (18 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch3, refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
error out saying "use --orphan"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server 'file://'"$(realpath './server/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ HEAD_old="$(git -C './client/repo' symbolic-ref HEAD)"; echo "$HEAD_old"
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' checkout --orphan branch1
Switched to a new branch 'branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --show-current
branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' symbolic-ref HEAD
refs/heads/branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' commit --message="$((++number))" --allow-empty
[branch1 (root-commit) 3c89f27] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' symbolic-ref HEAD "$HEAD_old"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' symbolic-ref HEAD
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add '../branch2'
warning: HEAD points to an invalid (or orphaned) reference.
hint: If you meant to create a worktree containing a new unborn branch
hint: (branch with no commits) for this repository, you can do so
hint: using the --orphan flag:
hint:
hint: git worktree add --orphan ../branch2
hint:
hint: Disable this message with "git config set advice.worktreeAddOrphan false"
fatal: invalid reference: HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
use --no-track to override the default behavior for remote-tracking branches
-b
create new branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 86e69aa] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' commit --message="$((++number))" --allow-empty
[master (root-commit) f462e77] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server 'file://'"$(realpath './server/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
* master f462e77 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 23.00 KiB/s, done.
From file:///test_git/server/repo
* [new branch] branch1 -> server/branch1
* [new branch] master -> server/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
* master f462e77 2
remotes/server/HEAD -> server/master
remotes/server/branch1 86e69aa 1
remotes/server/master 86e69aa 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list --verbose
C:/Program Files/Git/test_git/client/repo f462e77 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
* f462e77 - 2026-07-07 23:16 (3 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
* 86e69aa - 2026-07-07 23:16 (5 seconds ago) 1 - Han Jiang (refs/remotes/server/master, refs/remotes/server/branch1, refs/remotes/server/HEAD)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add -b branch11 '../worktree11' remotes/server/branch1
Preparing worktree (new branch 'branch11')
branch 'branch11' set up to track 'server/branch1'.
HEAD is now at 86e69aa 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add -b branch12 --no-track '../worktree12' remotes/server/branch1
Preparing worktree (new branch 'branch12')
HEAD is now at 86e69aa 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
+ branch11 86e69aa (C:/Program Files/Git/test_git/client/worktree11) [server/branch1] 1
+ branch12 86e69aa (C:/Program Files/Git/test_git/client/worktree12) 1
* master f462e77 2
remotes/server/HEAD -> server/master
remotes/server/branch1 86e69aa 1
remotes/server/master 86e69aa 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list --verbose
C:/Program Files/Git/test_git/client/repo f462e77 [master]
C:/Program Files/Git/test_git/client/worktree11 86e69aa [branch11]
C:/Program Files/Git/test_git/client/worktree12 86e69aa [branch12]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
* f462e77 - 2026-07-07 23:16 (5 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
* 86e69aa - 2026-07-07 23:16 (7 seconds ago) 1 - Han Jiang (refs/remotes/server/master, refs/remotes/server/branch1, refs/remotes/server/HEAD, refs/heads/branch12, refs/heads/branch11)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree11' branch --list --all --verbose --verbose
* branch11 86e69aa [server/branch1] 1
+ branch12 86e69aa (C:/Program Files/Git/test_git/client/worktree12) 1
+ master f462e77 (C:/Program Files/Git/test_git/client/repo) 2
remotes/server/HEAD -> server/master
remotes/server/branch1 86e69aa 1
remotes/server/master 86e69aa 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree11' worktree list --verbose
C:/Program Files/Git/test_git/client/repo f462e77 [master]
C:/Program Files/Git/test_git/client/worktree11 86e69aa [branch11]
C:/Program Files/Git/test_git/client/worktree12 86e69aa [branch12]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree11' lg --all
* f462e77 - 2026-07-07 23:16 (7 seconds ago) 2 - Han Jiang (refs/heads/master)
* 86e69aa - 2026-07-07 23:16 (9 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch11, refs/remotes/server/master, refs/remotes/server/branch1, refs/remotes/server/HEAD, refs/heads/branch12)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree12' branch --list --all --verbose --verbose
+ branch11 86e69aa (C:/Program Files/Git/test_git/client/worktree11) [server/branch1] 1
* branch12 86e69aa 1
+ master f462e77 (C:/Program Files/Git/test_git/client/repo) 2
remotes/server/HEAD -> server/master
remotes/server/branch1 86e69aa 1
remotes/server/master 86e69aa 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree12' worktree list --verbose
C:/Program Files/Git/test_git/client/repo f462e77 [master]
C:/Program Files/Git/test_git/client/worktree11 86e69aa [branch11]
C:/Program Files/Git/test_git/client/worktree12 86e69aa [branch12]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree12' lg --all
* f462e77 - 2026-07-07 23:16 (8 seconds ago) 2 - Han Jiang (refs/heads/master)
* 86e69aa - 2026-07-07 23:16 (10 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch12, refs/remotes/server/master, refs/remotes/server/branch1, refs/remotes/server/HEAD, refs/heads/branch11)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
-B
create new branch or reset existent local branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 6fd8c07] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' commit --message="$((++number))" --allow-empty
[master (root-commit) d87d753] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch branch11
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch branch12
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server 'file://'"$(realpath './server/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
branch11 d87d753 2
branch12 d87d753 2
* master d87d753 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 34.00 KiB/s, done.
From file:///test_git/server/repo
* [new branch] branch1 -> server/branch1
* [new branch] master -> server/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
branch11 d87d753 2
branch12 d87d753 2
* master d87d753 2
remotes/server/HEAD -> server/master
remotes/server/branch1 6fd8c07 1
remotes/server/master 6fd8c07 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list --verbose
C:/Program Files/Git/test_git/client/repo d87d753 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
* d87d753 - 2026-07-07 23:16 (4 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch12, refs/heads/branch11)
* 6fd8c07 - 2026-07-07 23:16 (6 seconds ago) 1 - Han Jiang (refs/remotes/server/master, refs/remotes/server/branch1, refs/remotes/server/HEAD)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add -B branch11 '../worktree11' remotes/server/branch1
Preparing worktree (resetting branch 'branch11'; was at d87d753)
branch 'branch11' set up to track 'server/branch1'.
HEAD is now at 6fd8c07 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add -B branch12 --no-track '../worktree12' remotes/server/branch1
Preparing worktree (resetting branch 'branch12'; was at d87d753)
HEAD is now at 6fd8c07 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
+ branch11 6fd8c07 (C:/Program Files/Git/test_git/client/worktree11) [server/branch1] 1
+ branch12 6fd8c07 (C:/Program Files/Git/test_git/client/worktree12) 1
* master d87d753 2
remotes/server/HEAD -> server/master
remotes/server/branch1 6fd8c07 1
remotes/server/master 6fd8c07 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list --verbose
C:/Program Files/Git/test_git/client/repo d87d753 [master]
C:/Program Files/Git/test_git/client/worktree11 6fd8c07 [branch11]
C:/Program Files/Git/test_git/client/worktree12 6fd8c07 [branch12]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
* d87d753 - 2026-07-07 23:16 (6 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
* 6fd8c07 - 2026-07-07 23:16 (8 seconds ago) 1 - Han Jiang (refs/remotes/server/master, refs/remotes/server/branch1, refs/remotes/server/HEAD, refs/heads/branch12, refs/heads/branch11)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree11' branch --list --all --verbose --verbose
* branch11 6fd8c07 [server/branch1] 1
+ branch12 6fd8c07 (C:/Program Files/Git/test_git/client/worktree12) 1
+ master d87d753 (C:/Program Files/Git/test_git/client/repo) 2
remotes/server/HEAD -> server/master
remotes/server/branch1 6fd8c07 1
remotes/server/master 6fd8c07 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree11' worktree list --verbose
C:/Program Files/Git/test_git/client/repo d87d753 [master]
C:/Program Files/Git/test_git/client/worktree11 6fd8c07 [branch11]
C:/Program Files/Git/test_git/client/worktree12 6fd8c07 [branch12]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree11' lg --all
* d87d753 - 2026-07-07 23:16 (7 seconds ago) 2 - Han Jiang (refs/heads/master)
* 6fd8c07 - 2026-07-07 23:16 (9 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch11, refs/remotes/server/master, refs/remotes/server/branch1, refs/remotes/server/HEAD, refs/heads/branch12)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree12' branch --list --all --verbose --verbose
+ branch11 6fd8c07 (C:/Program Files/Git/test_git/client/worktree11) [server/branch1] 1
* branch12 6fd8c07 1
+ master d87d753 (C:/Program Files/Git/test_git/client/repo) 2
remotes/server/HEAD -> server/master
remotes/server/branch1 6fd8c07 1
remotes/server/master 6fd8c07 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree12' worktree list --verbose
C:/Program Files/Git/test_git/client/repo d87d753 [master]
C:/Program Files/Git/test_git/client/worktree11 6fd8c07 [branch11]
C:/Program Files/Git/test_git/client/worktree12 6fd8c07 [branch12]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree12' lg --all
* d87d753 - 2026-07-07 23:16 (9 seconds ago) 2 - Han Jiang (refs/heads/master)
* 6fd8c07 - 2026-07-07 23:16 (11 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch12, refs/remotes/server/master, refs/remotes/server/branch1, refs/remotes/server/HEAD, refs/heads/branch11)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
(not -b/-B/--detach)
--no-track reverses --track in git worktree add --track -b <branch> <path> <remote-tracking branch>
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server1/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server1/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) badf741] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' branch branch2; git -C './server1/repo.git' branch branch3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server2' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server2/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server2/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) cdc406a] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server2/repo.git' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server1 'file://'"$(realpath './server1/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server2 'file://'"$(realpath './server2/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
Fetching server1
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 27.00 KiB/s, done.
From file:///test_git/server1/repo
* [new branch] branch2 -> server1/branch2
* [new branch] branch3 -> server1/branch3
* [new branch] master -> server1/master
Fetching server2
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 34.00 KiB/s, done.
From file:///test_git/server2/repo
* [new branch] branch2 -> server2/branch2
* [new branch] master -> server2/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 badf741 1
remotes/server1/branch3 badf741 1
remotes/server1/master badf741 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 cdc406a 2
remotes/server2/master cdc406a 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
* cdc406a - 2026-07-07 23:16 (4 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* badf741 - 2026-07-07 23:16 (6 seconds ago) 1 - Han Jiang (refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add '../worktree1' branch1
fatal: invalid reference: branch1
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --no-track '../worktree2' branch2
fatal: invalid reference: branch2
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' -c checkout.defaultRemote='server1' worktree add --no-track '../worktree2' branch2
Preparing worktree (new branch 'branch2')
HEAD is now at badf741 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --no-track '../worktree3' branch3
Preparing worktree (new branch 'branch3')
HEAD is now at badf741 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
+ branch2 badf741 (C:/Program Files/Git/test_git/client/worktree2) 1
+ branch3 badf741 (C:/Program Files/Git/test_git/client/worktree3) 1
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 badf741 1
remotes/server1/branch3 badf741 1
remotes/server1/master badf741 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 cdc406a 2
remotes/server2/master cdc406a 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
C:/Program Files/Git/test_git/client/worktree2 badf741 [branch2]
C:/Program Files/Git/test_git/client/worktree3 badf741 [branch3]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
* cdc406a - 2026-07-07 23:16 (8 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* badf741 - 2026-07-07 23:16 (10 seconds ago) 1 - Han Jiang (refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD, refs/heads/branch3, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree2' branch --list --all --verbose --verbose
* branch2 badf741 1
+ branch3 badf741 (C:/Program Files/Git/test_git/client/worktree3) 1
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 badf741 1
remotes/server1/branch3 badf741 1
remotes/server1/master badf741 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 cdc406a 2
remotes/server2/master cdc406a 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree2' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
C:/Program Files/Git/test_git/client/worktree2 badf741 [branch2]
C:/Program Files/Git/test_git/client/worktree3 badf741 [branch3]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree2' lg --all
* cdc406a - 2026-07-07 23:16 (9 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* badf741 - 2026-07-07 23:16 (11 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch2, refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD, refs/heads/branch3)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree3' branch --list --all --verbose --verbose
+ branch2 badf741 (C:/Program Files/Git/test_git/client/worktree2) 1
* branch3 badf741 1
remotes/server1/HEAD -> server1/master
remotes/server1/branch2 badf741 1
remotes/server1/branch3 badf741 1
remotes/server1/master badf741 1
remotes/server2/HEAD -> server2/master
remotes/server2/branch2 cdc406a 2
remotes/server2/master cdc406a 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree3' worktree list --verbose
C:/Program Files/Git/test_git/client/repo 0000000 [master]
C:/Program Files/Git/test_git/client/worktree2 badf741 [branch2]
C:/Program Files/Git/test_git/client/worktree3 badf741 [branch3]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/worktree3' lg --all
* cdc406a - 2026-07-07 23:16 (10 seconds ago) 2 - Han Jiang (refs/remotes/server2/master, refs/remotes/server2/branch2, refs/remotes/server2/HEAD)
* badf741 - 2026-07-07 23:16 (12 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch3, refs/remotes/server1/master, refs/remotes/server1/branch3, refs/remotes/server1/branch2, refs/remotes/server1/HEAD, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 8064943] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 8064943 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 8064943 - 2026-07-07 23:17 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at 8064943 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 8064943 [master]
C:/Program Files/Git/test_git/worktree1 8064943 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 8064943 - 2026-07-07 23:17 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 8064943 [master]
C:/Program Files/Git/test_git/worktree1 8064943 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 8064943 - 2026-07-07 23:17 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree move '../repo' '../repository'
fatal: '../repo' is a main working tree
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree move '../worktree1' '../worktree2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 8064943 [master]
C:/Program Files/Git/test_git/worktree2 8064943 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 8064943 - 2026-07-07 23:17 (7 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' worktree list --verbose
C:/Program Files/Git/test_git/repo 8064943 [master]
C:/Program Files/Git/test_git/worktree2 8064943 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' lg --all
* 8064943 - 2026-07-07 23:17 (8 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴COMMIT_EDITMSG -/0o100/regular file rw-r--r--/0o644
│ │ ├╴config -/0o100/regular file rw-r--r--/0o644
│ │ ├╴description -/0o100/regular file rw-r--r--/0o644
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴index -/0o100/regular file rw-r--r--/0o644
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ │ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ │ ├╴branch1 -/0o100/regular file rw-r--r--/0o644
│ │ │ │ │ ├╴master -/0o100/regular file rw-r--r--/0o644
│ │ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴4b/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴825dc642cb6eb9a060e54bf8d69288fbee4904 -/0o100/regular file r--r--r--/0o444
│ │ │ ├╴80/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴64943a1b44423ef20e98202e0de10c01f30d4a -/0o100/regular file r--r--r--/0o444
│ │ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴branch1 -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴master -/0o100/regular file rw-r--r--/0o644
│ │ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴worktrees/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴index -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree2/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git -/0o100/regular file rw-r--r--/0o644
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees' './worktree2'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree2/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 8064943a1b44423ef20e98202e0de10c01f30d4a Han Jiang <jhcarl0814@gmail.com> 1783423022 +1200\n
│ │ │ 2 8064943a1b44423ef20e98202e0de10c01f30d4a 8064943a1b44423ef20e98202e0de10c01f30d4a Han Jiang <jhcarl0814@gmail.com> 1783423022 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 8064943a1b44423ef20e98202e0de10c01f30d4a\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
./worktree2/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 62bad4f] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 62bad4f [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 62bad4f - 2026-07-07 23:17 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --lock '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at 62bad4f 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 62bad4f [master]
C:/Program Files/Git/test_git/worktree1 62bad4f [branch1]
locked: added with --lock
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 62bad4f - 2026-07-07 23:17 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 62bad4f [master]
C:/Program Files/Git/test_git/worktree1 62bad4f [branch1]
locked: added with --lock
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 62bad4f - 2026-07-07 23:17 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree move '../worktree1' '../worktree2'
fatal: cannot move a locked working tree, lock reason: added with --lock
use 'move -f -f' to override or unlock first
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree move --force '../worktree1' '../worktree2'
fatal: cannot move a locked working tree, lock reason: added with --lock
use 'move -f -f' to override or unlock first
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree move --force --force '../worktree1' '../worktree2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 62bad4f [master]
C:/Program Files/Git/test_git/worktree2 62bad4f [branch1]
locked: added with --lock
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 62bad4f - 2026-07-07 23:17 (7 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' worktree list --verbose
C:/Program Files/Git/test_git/repo 62bad4f [master]
C:/Program Files/Git/test_git/worktree2 62bad4f [branch1]
locked: added with --lock
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' lg --all
* 62bad4f - 2026-07-07 23:17 (9 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) e54664a] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1; git -C './repo' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo e54664a [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* e54664a - 2026-07-07 23:17 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at e54664a 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree2' branch2
Preparing worktree (checking out 'branch2')
HEAD is now at e54664a 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo e54664a [master]
C:/Program Files/Git/test_git/worktree1 e54664a [branch1]
C:/Program Files/Git/test_git/worktree2 e54664a [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* e54664a - 2026-07-07 23:17 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo e54664a [master]
C:/Program Files/Git/test_git/worktree1 e54664a [branch1]
C:/Program Files/Git/test_git/worktree2 e54664a [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* e54664a - 2026-07-07 23:17 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree2
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' worktree list --verbose
C:/Program Files/Git/test_git/repo e54664a [master]
C:/Program Files/Git/test_git/worktree1 e54664a [branch1]
C:/Program Files/Git/test_git/worktree2 e54664a [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' lg --all
* e54664a - 2026-07-07 23:17 (7 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch2, refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ rm --force --recursive -- './worktree2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree move '../worktree1' '../worktree2'
fatal: '../worktree2' is a missing but already registered worktree;
use 'move -f' to override, or 'prune' or 'remove' to clear
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree move --force '../worktree1' '../worktree2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo e54664a [master]
C:/Program Files/Git/test_git/worktree2 e54664a [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* e54664a - 2026-07-07 23:17 (9 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' worktree list --verbose
C:/Program Files/Git/test_git/repo e54664a [master]
C:/Program Files/Git/test_git/worktree2 e54664a [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' lg --all
* e54664a - 2026-07-07 23:17 (11 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) b67ea63] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1; git -C './repo' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo b67ea63 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* b67ea63 - 2026-07-07 23:18 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at b67ea63 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --lock '../worktree2' branch2
Preparing worktree (checking out 'branch2')
HEAD is now at b67ea63 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo b67ea63 [master]
C:/Program Files/Git/test_git/worktree1 b67ea63 [branch1]
C:/Program Files/Git/test_git/worktree2 b67ea63 [branch2]
locked: added with --lock
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* b67ea63 - 2026-07-07 23:18 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo b67ea63 [master]
C:/Program Files/Git/test_git/worktree1 b67ea63 [branch1]
C:/Program Files/Git/test_git/worktree2 b67ea63 [branch2]
locked: added with --lock
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* b67ea63 - 2026-07-07 23:18 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree2
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' worktree list --verbose
C:/Program Files/Git/test_git/repo b67ea63 [master]
C:/Program Files/Git/test_git/worktree1 b67ea63 [branch1]
C:/Program Files/Git/test_git/worktree2 b67ea63 [branch2]
locked: added with --lock
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' lg --all
* b67ea63 - 2026-07-07 23:18 (7 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch2, refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ rm --force --recursive -- './worktree2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree move '../worktree1' '../worktree2'
fatal: '../worktree2' is a missing but locked worktree;
use 'move -f -f' to override, or 'unlock' and 'prune' or 'remove' to clear
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree move --force '../worktree1' '../worktree2'
fatal: '../worktree2' is a missing but locked worktree;
use 'move -f -f' to override, or 'unlock' and 'prune' or 'remove' to clear
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree move --force --force '../worktree1' '../worktree2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo b67ea63 [master]
C:/Program Files/Git/test_git/worktree2 b67ea63 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* b67ea63 - 2026-07-07 23:18 (10 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' worktree list --verbose
C:/Program Files/Git/test_git/repo b67ea63 [master]
C:/Program Files/Git/test_git/worktree2 b67ea63 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' lg --all
* b67ea63 - 2026-07-07 23:18 (11 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) a83a1a0] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo a83a1a0 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* a83a1a0 - 2026-07-07 23:18 (2 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at a83a1a0 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo a83a1a0 [master]
C:/Program Files/Git/test_git/worktree1 a83a1a0 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* a83a1a0 - 2026-07-07 23:18 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo a83a1a0 [master]
C:/Program Files/Git/test_git/worktree1 a83a1a0 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* a83a1a0 - 2026-07-07 23:18 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴COMMIT_EDITMSG -/0o100/regular file rw-r--r--/0o644
│ │ ├╴config -/0o100/regular file rw-r--r--/0o644
│ │ ├╴description -/0o100/regular file rw-r--r--/0o644
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴index -/0o100/regular file rw-r--r--/0o644
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ │ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ │ ├╴branch1 -/0o100/regular file rw-r--r--/0o644
│ │ │ │ │ ├╴master -/0o100/regular file rw-r--r--/0o644
│ │ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴4b/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴825dc642cb6eb9a060e54bf8d69288fbee4904 -/0o100/regular file r--r--r--/0o444
│ │ │ ├╴a8/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴3a1a0de250e474009de05c599717801b9005fa -/0o100/regular file r--r--r--/0o444
│ │ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴branch1 -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴master -/0o100/regular file rw-r--r--/0o644
│ │ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴worktrees/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴index -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git -/0o100/regular file rw-r--r--/0o644
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree remove '../repo'
fatal: '../repo' is a main working tree
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree remove '../worktree1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo a83a1a0 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* a83a1a0 - 2026-07-07 23:18 (21 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴COMMIT_EDITMSG -/0o100/regular file rw-r--r--/0o644
│ │ ├╴config -/0o100/regular file rw-r--r--/0o644
│ │ ├╴description -/0o100/regular file rw-r--r--/0o644
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴index -/0o100/regular file rw-r--r--/0o644
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ │ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ │ ├╴branch1 -/0o100/regular file rw-r--r--/0o644
│ │ │ │ │ ├╴master -/0o100/regular file rw-r--r--/0o644
│ │ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴4b/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴825dc642cb6eb9a060e54bf8d69288fbee4904 -/0o100/regular file r--r--r--/0o444
│ │ │ ├╴a8/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴3a1a0de250e474009de05c599717801b9005fa -/0o100/regular file r--r--r--/0o444
│ │ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴branch1 -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴master -/0o100/regular file rw-r--r--/0o644
│ │ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) cd87823] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo cd87823 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* cd87823 - 2026-07-07 23:18 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at cd87823 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo cd87823 [master]
C:/Program Files/Git/test_git/worktree1 cd87823 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* cd87823 - 2026-07-07 23:18 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo cd87823 [master]
C:/Program Files/Git/test_git/worktree1 cd87823 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* cd87823 - 2026-07-07 23:18 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ touch -- './worktree1/file'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree remove '../worktree1'
fatal: '../worktree1' contains modified or untracked files, use --force to delete it
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree remove --force '../worktree1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo cd87823 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* cd87823 - 2026-07-07 23:18 (6 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 9169712] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 9169712 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 9169712 - 2026-07-07 23:19 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add --lock '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at 9169712 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 9169712 [master]
C:/Program Files/Git/test_git/worktree1 9169712 [branch1]
locked: added with --lock
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 9169712 - 2026-07-07 23:19 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/worktree1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 9169712 [master]
C:/Program Files/Git/test_git/worktree1 9169712 [branch1]
locked: added with --lock
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 9169712 - 2026-07-07 23:19 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree remove '../worktree1'
fatal: cannot remove a locked working tree, lock reason: added with --lock
use 'remove -f -f' to override or unlock first
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree remove --force '../worktree1'
fatal: cannot remove a locked working tree, lock reason: added with --lock
use 'remove -f -f' to override or unlock first
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree remove --force --force '../worktree1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 9169712 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 9169712 - 2026-07-07 23:19 (7 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) c5820fc] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo c5820fc [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* c5820fc - 2026-07-07 23:19 (2 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at c5820fc 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo c5820fc [master]
C:/Program Files/Git/test_git/worktree1 c5820fc [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* c5820fc - 2026-07-07 23:19 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo c5820fc [master]
C:/Program Files/Git/test_git/worktree1 c5820fc [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* c5820fc - 2026-07-07 23:19 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴COMMIT_EDITMSG -/0o100/regular file rw-r--r--/0o644
│ │ ├╴config -/0o100/regular file rw-r--r--/0o644
│ │ ├╴description -/0o100/regular file rw-r--r--/0o644
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴index -/0o100/regular file rw-r--r--/0o644
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ │ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ │ ├╴branch1 -/0o100/regular file rw-r--r--/0o644
│ │ │ │ │ ├╴master -/0o100/regular file rw-r--r--/0o644
│ │ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴4b/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴825dc642cb6eb9a060e54bf8d69288fbee4904 -/0o100/regular file r--r--r--/0o444
│ │ │ ├╴c5/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴820fc995adf5d8ad46e956a9f31a3334659f10 -/0o100/regular file r--r--r--/0o444
│ │ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴branch1 -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴master -/0o100/regular file rw-r--r--/0o644
│ │ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴worktrees/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴index -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git -/0o100/regular file rw-r--r--/0o644
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ rm --force --recursive -- './worktree1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo c5820fc [master]
C:/Program Files/Git/test_git/worktree1 c5820fc [branch1]
prunable: gitdir file points to non-existent location
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree lock '../worktree1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo c5820fc [master]
C:/Program Files/Git/test_git/worktree1 c5820fc [branch1] locked
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree prune --dry-run
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo c5820fc [master]
C:/Program Files/Git/test_git/worktree1 c5820fc [branch1] locked
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree prune --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo c5820fc [master]
C:/Program Files/Git/test_git/worktree1 c5820fc [branch1] locked
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree unlock '../worktree1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo c5820fc [master]
C:/Program Files/Git/test_git/worktree1 c5820fc [branch1]
prunable: gitdir file points to non-existent location
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree prune --dry-run
Removing worktrees/worktree1: gitdir file points to non-existent location
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo c5820fc [master]
C:/Program Files/Git/test_git/worktree1 c5820fc [branch1]
prunable: gitdir file points to non-existent location
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree prune --verbose
Removing worktrees/worktree1: gitdir file points to non-existent location
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo c5820fc [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴COMMIT_EDITMSG -/0o100/regular file rw-r--r--/0o644
│ │ ├╴config -/0o100/regular file rw-r--r--/0o644
│ │ ├╴description -/0o100/regular file rw-r--r--/0o644
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴index -/0o100/regular file rw-r--r--/0o644
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ │ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ │ ├╴branch1 -/0o100/regular file rw-r--r--/0o644
│ │ │ │ │ ├╴master -/0o100/regular file rw-r--r--/0o644
│ │ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴4b/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴825dc642cb6eb9a060e54bf8d69288fbee4904 -/0o100/regular file r--r--r--/0o444
│ │ │ ├╴c5/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴820fc995adf5d8ad46e956a9f31a3334659f10 -/0o100/regular file r--r--r--/0o444
│ │ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ │ ├╴branch1 -/0o100/regular file rw-r--r--/0o644
│ │ │ │ ├╴master -/0o100/regular file rw-r--r--/0o644
│ │ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 97b7876] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 97b7876 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 97b7876 - 2026-07-07 23:19 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at 97b7876 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 97b7876 [master]
C:/Program Files/Git/test_git/worktree1 97b7876 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 97b7876 - 2026-07-07 23:19 (2 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 97b7876 [master]
C:/Program Files/Git/test_git/worktree1 97b7876 [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 97b7876 - 2026-07-07 23:19 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 97b78768c496fb432a2f827c94b4f8d0afcc38c1 Han Jiang <jhcarl0814@gmail.com> 1783423194 +1200\n
│ │ │ 2 97b78768c496fb432a2f827c94b4f8d0afcc38c1 97b78768c496fb432a2f827c94b4f8d0afcc38c1 Han Jiang <jhcarl0814@gmail.com> 1783423194 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 97b78768c496fb432a2f827c94b4f8d0afcc38c1\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree lock '../worktree1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴locked -/0o100/regular empty file rw-r--r--/0o644
│ │ 1
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 97b78768c496fb432a2f827c94b4f8d0afcc38c1 Han Jiang <jhcarl0814@gmail.com> 1783423194 +1200\n
│ │ │ 2 97b78768c496fb432a2f827c94b4f8d0afcc38c1 97b78768c496fb432a2f827c94b4f8d0afcc38c1 Han Jiang <jhcarl0814@gmail.com> 1783423194 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 97b78768c496fb432a2f827c94b4f8d0afcc38c1\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree unlock '../worktree1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 97b78768c496fb432a2f827c94b4f8d0afcc38c1 Han Jiang <jhcarl0814@gmail.com> 1783423194 +1200\n
│ │ │ 2 97b78768c496fb432a2f827c94b4f8d0afcc38c1 97b78768c496fb432a2f827c94b4f8d0afcc38c1 Han Jiang <jhcarl0814@gmail.com> 1783423194 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 97b78768c496fb432a2f827c94b4f8d0afcc38c1\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree lock --reason='lock reason' '../worktree1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴locked -/0o100/regular file rw-r--r--/0o644
│ │ 1 lock reason\n
│ │ 2
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 97b78768c496fb432a2f827c94b4f8d0afcc38c1 Han Jiang <jhcarl0814@gmail.com> 1783423194 +1200\n
│ │ │ 2 97b78768c496fb432a2f827c94b4f8d0afcc38c1 97b78768c496fb432a2f827c94b4f8d0afcc38c1 Han Jiang <jhcarl0814@gmail.com> 1783423194 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 97b78768c496fb432a2f827c94b4f8d0afcc38c1\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree unlock '../worktree1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 97b78768c496fb432a2f827c94b4f8d0afcc38c1 Han Jiang <jhcarl0814@gmail.com> 1783423194 +1200\n
│ │ │ 2 97b78768c496fb432a2f827c94b4f8d0afcc38c1 97b78768c496fb432a2f827c94b4f8d0afcc38c1 Han Jiang <jhcarl0814@gmail.com> 1783423194 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 97b78768c496fb432a2f827c94b4f8d0afcc38c1\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 47e0763] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1; git -C './repo' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 47e0763 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 47e0763 - 2026-07-07 23:20 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at 47e0763 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree2' branch2
Preparing worktree (checking out 'branch2')
HEAD is now at 47e0763 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 47e0763 [master]
C:/Program Files/Git/test_git/worktree1 47e0763 [branch1]
C:/Program Files/Git/test_git/worktree2 47e0763 [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 47e0763 - 2026-07-07 23:20 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 47e0763 [master]
C:/Program Files/Git/test_git/worktree1 47e0763 [branch1]
C:/Program Files/Git/test_git/worktree2 47e0763 [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 47e0763 - 2026-07-07 23:20 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' worktree list --verbose
C:/Program Files/Git/test_git/repo 47e0763 [master]
C:/Program Files/Git/test_git/worktree1 47e0763 [branch1]
C:/Program Files/Git/test_git/worktree2 47e0763 [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' lg --all
* 47e0763 - 2026-07-07 23:20 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch2, refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees' './worktree1' './worktree2'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 47e076384c31f9cdafe68307638fc230b0ccb3b7 Han Jiang <jhcarl0814@gmail.com> 1783423230 +1200\n
│ │ │ 2 47e076384c31f9cdafe68307638fc230b0ccb3b7 47e076384c31f9cdafe68307638fc230b0ccb3b7 Han Jiang <jhcarl0814@gmail.com> 1783423230 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 47e076384c31f9cdafe68307638fc230b0ccb3b7\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree2/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree2/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch2\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 47e076384c31f9cdafe68307638fc230b0ccb3b7 Han Jiang <jhcarl0814@gmail.com> 1783423230 +1200\n
│ │ │ 2 47e076384c31f9cdafe68307638fc230b0ccb3b7 47e076384c31f9cdafe68307638fc230b0ccb3b7 Han Jiang <jhcarl0814@gmail.com> 1783423230 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 47e076384c31f9cdafe68307638fc230b0ccb3b7\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
./worktree1/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1\n
│ 2
./worktree2/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree2\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mv './worktree1' './worktree1_'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mv './worktree2' './worktree2_'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1_' worktree repair
repair: gitdir incorrect: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/gitdir
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1_/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 47e076384c31f9cdafe68307638fc230b0ccb3b7 Han Jiang <jhcarl0814@gmail.com> 1783423230 +1200\n
│ │ │ 2 47e076384c31f9cdafe68307638fc230b0ccb3b7 47e076384c31f9cdafe68307638fc230b0ccb3b7 Han Jiang <jhcarl0814@gmail.com> 1783423230 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 47e076384c31f9cdafe68307638fc230b0ccb3b7\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree2/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree2/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch2\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 47e076384c31f9cdafe68307638fc230b0ccb3b7 Han Jiang <jhcarl0814@gmail.com> 1783423230 +1200\n
│ │ │ 2 47e076384c31f9cdafe68307638fc230b0ccb3b7 47e076384c31f9cdafe68307638fc230b0ccb3b7 Han Jiang <jhcarl0814@gmail.com> 1783423230 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 47e076384c31f9cdafe68307638fc230b0ccb3b7\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 75656fe] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1; git -C './repo' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 75656fe [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 75656fe - 2026-07-07 23:20 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at 75656fe 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree2' branch2
Preparing worktree (checking out 'branch2')
HEAD is now at 75656fe 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 75656fe [master]
C:/Program Files/Git/test_git/worktree1 75656fe [branch1]
C:/Program Files/Git/test_git/worktree2 75656fe [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 75656fe - 2026-07-07 23:20 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 75656fe [master]
C:/Program Files/Git/test_git/worktree1 75656fe [branch1]
C:/Program Files/Git/test_git/worktree2 75656fe [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 75656fe - 2026-07-07 23:20 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' worktree list --verbose
C:/Program Files/Git/test_git/repo 75656fe [master]
C:/Program Files/Git/test_git/worktree1 75656fe [branch1]
C:/Program Files/Git/test_git/worktree2 75656fe [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' lg --all
* 75656fe - 2026-07-07 23:20 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch2, refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees' './worktree1' './worktree2'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d Han Jiang <jhcarl0814@gmail.com> 1783423261 +1200\n
│ │ │ 2 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d Han Jiang <jhcarl0814@gmail.com> 1783423261 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree2/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree2/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch2\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d Han Jiang <jhcarl0814@gmail.com> 1783423261 +1200\n
│ │ │ 2 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d Han Jiang <jhcarl0814@gmail.com> 1783423261 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
./worktree1/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1\n
│ 2
./worktree2/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree2\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mv './worktree1' './worktree1_'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mv './worktree2' './worktree2_'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1_' worktree repair '.'
repair: gitdir incorrect: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/gitdir
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1_/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d Han Jiang <jhcarl0814@gmail.com> 1783423261 +1200\n
│ │ │ 2 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d Han Jiang <jhcarl0814@gmail.com> 1783423261 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree2/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree2/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch2\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d Han Jiang <jhcarl0814@gmail.com> 1783423261 +1200\n
│ │ │ 2 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d Han Jiang <jhcarl0814@gmail.com> 1783423261 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 75656fe0e90a4d4f75fcc2e9c7eacb29abccea6d\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) a997a1c] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1; git -C './repo' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo a997a1c [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* a997a1c - 2026-07-07 23:21 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at a997a1c 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree2' branch2
Preparing worktree (checking out 'branch2')
HEAD is now at a997a1c 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo a997a1c [master]
C:/Program Files/Git/test_git/worktree1 a997a1c [branch1]
C:/Program Files/Git/test_git/worktree2 a997a1c [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* a997a1c - 2026-07-07 23:21 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo a997a1c [master]
C:/Program Files/Git/test_git/worktree1 a997a1c [branch1]
C:/Program Files/Git/test_git/worktree2 a997a1c [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* a997a1c - 2026-07-07 23:21 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' worktree list --verbose
C:/Program Files/Git/test_git/repo a997a1c [master]
C:/Program Files/Git/test_git/worktree1 a997a1c [branch1]
C:/Program Files/Git/test_git/worktree2 a997a1c [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' lg --all
* a997a1c - 2026-07-07 23:21 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch2, refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees' './worktree1' './worktree2'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 a997a1c3f4c224834e578853bdc1495e6117a3af Han Jiang <jhcarl0814@gmail.com> 1783423292 +1200\n
│ │ │ 2 a997a1c3f4c224834e578853bdc1495e6117a3af a997a1c3f4c224834e578853bdc1495e6117a3af Han Jiang <jhcarl0814@gmail.com> 1783423292 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 a997a1c3f4c224834e578853bdc1495e6117a3af\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree2/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree2/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch2\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 a997a1c3f4c224834e578853bdc1495e6117a3af Han Jiang <jhcarl0814@gmail.com> 1783423292 +1200\n
│ │ │ 2 a997a1c3f4c224834e578853bdc1495e6117a3af a997a1c3f4c224834e578853bdc1495e6117a3af Han Jiang <jhcarl0814@gmail.com> 1783423292 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 a997a1c3f4c224834e578853bdc1495e6117a3af\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
./worktree1/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1\n
│ 2
./worktree2/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree2\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mv './worktree1' './worktree1_'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mv './worktree2' './worktree2_'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1_' worktree repair '../worktree2_'
repair: gitdir incorrect: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree2/gitdir
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 a997a1c3f4c224834e578853bdc1495e6117a3af Han Jiang <jhcarl0814@gmail.com> 1783423292 +1200\n
│ │ │ 2 a997a1c3f4c224834e578853bdc1495e6117a3af a997a1c3f4c224834e578853bdc1495e6117a3af Han Jiang <jhcarl0814@gmail.com> 1783423292 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 a997a1c3f4c224834e578853bdc1495e6117a3af\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree2/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree2_/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch2\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 a997a1c3f4c224834e578853bdc1495e6117a3af Han Jiang <jhcarl0814@gmail.com> 1783423292 +1200\n
│ │ │ 2 a997a1c3f4c224834e578853bdc1495e6117a3af a997a1c3f4c224834e578853bdc1495e6117a3af Han Jiang <jhcarl0814@gmail.com> 1783423292 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 a997a1c3f4c224834e578853bdc1495e6117a3af\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) a11e4ad] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1; git -C './repo' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo a11e4ad [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* a11e4ad - 2026-07-07 23:22 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at a11e4ad 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree2' branch2
Preparing worktree (checking out 'branch2')
HEAD is now at a11e4ad 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo a11e4ad [master]
C:/Program Files/Git/test_git/worktree1 a11e4ad [branch1]
C:/Program Files/Git/test_git/worktree2 a11e4ad [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* a11e4ad - 2026-07-07 23:22 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo a11e4ad [master]
C:/Program Files/Git/test_git/worktree1 a11e4ad [branch1]
C:/Program Files/Git/test_git/worktree2 a11e4ad [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* a11e4ad - 2026-07-07 23:22 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' worktree list --verbose
C:/Program Files/Git/test_git/repo a11e4ad [master]
C:/Program Files/Git/test_git/worktree1 a11e4ad [branch1]
C:/Program Files/Git/test_git/worktree2 a11e4ad [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' lg --all
* a11e4ad - 2026-07-07 23:22 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch2, refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees' './worktree1' './worktree2'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 a11e4ad764886a4f142234eef93749e0cfbcb424 Han Jiang <jhcarl0814@gmail.com> 1783423323 +1200\n
│ │ │ 2 a11e4ad764886a4f142234eef93749e0cfbcb424 a11e4ad764886a4f142234eef93749e0cfbcb424 Han Jiang <jhcarl0814@gmail.com> 1783423323 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 a11e4ad764886a4f142234eef93749e0cfbcb424\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree2/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree2/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch2\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 a11e4ad764886a4f142234eef93749e0cfbcb424 Han Jiang <jhcarl0814@gmail.com> 1783423324 +1200\n
│ │ │ 2 a11e4ad764886a4f142234eef93749e0cfbcb424 a11e4ad764886a4f142234eef93749e0cfbcb424 Han Jiang <jhcarl0814@gmail.com> 1783423324 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 a11e4ad764886a4f142234eef93749e0cfbcb424\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
./worktree1/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1\n
│ 2
./worktree2/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree2\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mv './worktree1' './worktree1_'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mv './worktree2' './worktree2_'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1_' worktree repair '.' '../worktree2_'
repair: gitdir incorrect: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/gitdir
repair: gitdir incorrect: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree2/gitdir
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1_/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 a11e4ad764886a4f142234eef93749e0cfbcb424 Han Jiang <jhcarl0814@gmail.com> 1783423323 +1200\n
│ │ │ 2 a11e4ad764886a4f142234eef93749e0cfbcb424 a11e4ad764886a4f142234eef93749e0cfbcb424 Han Jiang <jhcarl0814@gmail.com> 1783423323 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 a11e4ad764886a4f142234eef93749e0cfbcb424\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree2/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree2_/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch2\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 a11e4ad764886a4f142234eef93749e0cfbcb424 Han Jiang <jhcarl0814@gmail.com> 1783423324 +1200\n
│ │ │ 2 a11e4ad764886a4f142234eef93749e0cfbcb424 a11e4ad764886a4f142234eef93749e0cfbcb424 Han Jiang <jhcarl0814@gmail.com> 1783423324 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 a11e4ad764886a4f142234eef93749e0cfbcb424\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 73be68e] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1; git -C './repo' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 73be68e [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 73be68e - 2026-07-07 23:22 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at 73be68e 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree2' branch2
Preparing worktree (checking out 'branch2')
HEAD is now at 73be68e 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 73be68e [master]
C:/Program Files/Git/test_git/worktree1 73be68e [branch1]
C:/Program Files/Git/test_git/worktree2 73be68e [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 73be68e - 2026-07-07 23:22 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 73be68e [master]
C:/Program Files/Git/test_git/worktree1 73be68e [branch1]
C:/Program Files/Git/test_git/worktree2 73be68e [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 73be68e - 2026-07-07 23:22 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' worktree list --verbose
C:/Program Files/Git/test_git/repo 73be68e [master]
C:/Program Files/Git/test_git/worktree1 73be68e [branch1]
C:/Program Files/Git/test_git/worktree2 73be68e [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' lg --all
* 73be68e - 2026-07-07 23:22 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch2, refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees' './worktree1' './worktree2'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 73be68e3820c98e5466614f350927236532da05c Han Jiang <jhcarl0814@gmail.com> 1783423354 +1200\n
│ │ │ 2 73be68e3820c98e5466614f350927236532da05c 73be68e3820c98e5466614f350927236532da05c Han Jiang <jhcarl0814@gmail.com> 1783423354 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 73be68e3820c98e5466614f350927236532da05c\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree2/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree2/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch2\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 73be68e3820c98e5466614f350927236532da05c Han Jiang <jhcarl0814@gmail.com> 1783423355 +1200\n
│ │ │ 2 73be68e3820c98e5466614f350927236532da05c 73be68e3820c98e5466614f350927236532da05c Han Jiang <jhcarl0814@gmail.com> 1783423355 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 73be68e3820c98e5466614f350927236532da05c\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
./worktree1/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1\n
│ 2
./worktree2/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree2\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mv './worktree1' './worktree1_'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mv './worktree2' './worktree2_'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree repair '../worktree1_' '../worktree2_'
repair: gitdir incorrect: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1/gitdir
repair: gitdir incorrect: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree2/gitdir
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1_/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 73be68e3820c98e5466614f350927236532da05c Han Jiang <jhcarl0814@gmail.com> 1783423354 +1200\n
│ │ │ 2 73be68e3820c98e5466614f350927236532da05c 73be68e3820c98e5466614f350927236532da05c Han Jiang <jhcarl0814@gmail.com> 1783423354 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 73be68e3820c98e5466614f350927236532da05c\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree2/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree2_/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch2\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 73be68e3820c98e5466614f350927236532da05c Han Jiang <jhcarl0814@gmail.com> 1783423355 +1200\n
│ │ │ 2 73be68e3820c98e5466614f350927236532da05c 73be68e3820c98e5466614f350927236532da05c Han Jiang <jhcarl0814@gmail.com> 1783423355 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 73be68e3820c98e5466614f350927236532da05c\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 1cfa9a4] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1; git -C './repo' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 1cfa9a4 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 1cfa9a4 - 2026-07-07 23:23 (2 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at 1cfa9a4 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree2' branch2
Preparing worktree (checking out 'branch2')
HEAD is now at 1cfa9a4 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo 1cfa9a4 [master]
C:/Program Files/Git/test_git/worktree1 1cfa9a4 [branch1]
C:/Program Files/Git/test_git/worktree2 1cfa9a4 [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 1cfa9a4 - 2026-07-07 23:23 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo 1cfa9a4 [master]
C:/Program Files/Git/test_git/worktree1 1cfa9a4 [branch1]
C:/Program Files/Git/test_git/worktree2 1cfa9a4 [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* 1cfa9a4 - 2026-07-07 23:23 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' worktree list --verbose
C:/Program Files/Git/test_git/repo 1cfa9a4 [master]
C:/Program Files/Git/test_git/worktree1 1cfa9a4 [branch1]
C:/Program Files/Git/test_git/worktree2 1cfa9a4 [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' lg --all
* 1cfa9a4 - 2026-07-07 23:23 (6 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch2, refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees' './worktree1' './worktree2'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 1cfa9a420b0e42f626854172b8de139ccf9170c4 Han Jiang <jhcarl0814@gmail.com> 1783423385 +1200\n
│ │ │ 2 1cfa9a420b0e42f626854172b8de139ccf9170c4 1cfa9a420b0e42f626854172b8de139ccf9170c4 Han Jiang <jhcarl0814@gmail.com> 1783423386 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 1cfa9a420b0e42f626854172b8de139ccf9170c4\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree2/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree2/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch2\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 1cfa9a420b0e42f626854172b8de139ccf9170c4 Han Jiang <jhcarl0814@gmail.com> 1783423386 +1200\n
│ │ │ 2 1cfa9a420b0e42f626854172b8de139ccf9170c4 1cfa9a420b0e42f626854172b8de139ccf9170c4 Han Jiang <jhcarl0814@gmail.com> 1783423386 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 1cfa9a420b0e42f626854172b8de139ccf9170c4\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
./worktree1/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1\n
│ 2
./worktree2/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree2\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mv './repo' './repo_'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree repair '../repo_'
fatal: not a git repository: (NULL)
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo_' worktree repair
repair: .git file broken: C:/Program Files/Git/test_git/worktree1
repair: .git file broken: C:/Program Files/Git/test_git/worktree2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './worktree1' './worktree2'
./worktree1/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo_/.git/worktrees/worktree1\n
│ 2
./worktree2/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo_/.git/worktrees/worktree2\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) cb86e85] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1; git -C './repo' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo cb86e85 [master]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* cb86e85 - 2026-07-07 23:23 (1 second ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at cb86e85 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree add '../worktree2' branch2
Preparing worktree (checking out 'branch2')
HEAD is now at cb86e85 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' worktree list --verbose
C:/Program Files/Git/test_git/repo cb86e85 [master]
C:/Program Files/Git/test_git/worktree1 cb86e85 [branch1]
C:/Program Files/Git/test_git/worktree2 cb86e85 [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* cb86e85 - 2026-07-07 23:23 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' worktree list --verbose
C:/Program Files/Git/test_git/repo cb86e85 [master]
C:/Program Files/Git/test_git/worktree1 cb86e85 [branch1]
C:/Program Files/Git/test_git/worktree2 cb86e85 [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1' lg --all
* cb86e85 - 2026-07-07 23:23 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master, refs/heads/branch2)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' worktree list --verbose
C:/Program Files/Git/test_git/repo cb86e85 [master]
C:/Program Files/Git/test_git/worktree1 cb86e85 [branch1]
C:/Program Files/Git/test_git/worktree2 cb86e85 [branch2]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree2' lg --all
* cb86e85 - 2026-07-07 23:23 (5 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch2, refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git/worktrees' './worktree1' './worktree2'
./repo/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 cb86e8519acf052f2e4b89f7bcc50384d8db250f Han Jiang <jhcarl0814@gmail.com> 1783423410 +1200\n
│ │ │ 2 cb86e8519acf052f2e4b89f7bcc50384d8db250f cb86e8519acf052f2e4b89f7bcc50384d8db250f Han Jiang <jhcarl0814@gmail.com> 1783423410 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 cb86e8519acf052f2e4b89f7bcc50384d8db250f\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree2/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree2/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch2\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 cb86e8519acf052f2e4b89f7bcc50384d8db250f Han Jiang <jhcarl0814@gmail.com> 1783423411 +1200\n
│ │ │ 2 cb86e8519acf052f2e4b89f7bcc50384d8db250f cb86e8519acf052f2e4b89f7bcc50384d8db250f Han Jiang <jhcarl0814@gmail.com> 1783423411 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 cb86e8519acf052f2e4b89f7bcc50384d8db250f\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
./worktree1/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree1\n
│ 2
./worktree2/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo/.git/worktrees/worktree2\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mv './repo' './repo_'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mv './worktree1' './worktree1_'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mv './worktree2' './worktree2_'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './worktree1_' worktree repair '../worktree2_' '../repo_'
fatal: not a git repository: (NULL)
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo_' worktree repair '../worktree1_' '../worktree2_'
repair: gitdir incorrect: C:/Program Files/Git/test_git/repo_/.git/worktrees/worktree1/gitdir
repair: gitdir incorrect: C:/Program Files/Git/test_git/repo_/.git/worktrees/worktree2/gitdir
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo_/.git/worktrees' './worktree1_' './worktree2_'
./repo_/.git/worktrees/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree1_/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch1\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 cb86e8519acf052f2e4b89f7bcc50384d8db250f Han Jiang <jhcarl0814@gmail.com> 1783423410 +1200\n
│ │ │ 2 cb86e8519acf052f2e4b89f7bcc50384d8db250f cb86e8519acf052f2e4b89f7bcc50384d8db250f Han Jiang <jhcarl0814@gmail.com> 1783423410 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 cb86e8519acf052f2e4b89f7bcc50384d8db250f\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
├╴worktree2/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴commondir -/0o100/regular file rw-r--r--/0o644
│ │ 1 ../..\n
│ │ 2
│ ├╴gitdir -/0o100/regular file rw-r--r--/0o644
│ │ 1 C:/Program Files/Git/test_git/worktree2_/.git\n
│ │ 2
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 ref: refs/heads/branch2\n
│ │ 2
│ ├╴index -/0o100/regular file rw-r--r--/0o644
│ ├╴logs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 0000000000000000000000000000000000000000 cb86e8519acf052f2e4b89f7bcc50384d8db250f Han Jiang <jhcarl0814@gmail.com> 1783423411 +1200\n
│ │ │ 2 cb86e8519acf052f2e4b89f7bcc50384d8db250f cb86e8519acf052f2e4b89f7bcc50384d8db250f Han Jiang <jhcarl0814@gmail.com> 1783423411 +1200\treset: moving to HEAD\n
│ │ │ 3
│ ├╴ORIG_HEAD -/0o100/regular file rw-r--r--/0o644
│ │ 1 cb86e8519acf052f2e4b89f7bcc50384d8db250f\n
│ │ 2
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
./worktree1_/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo_/.git/worktrees/worktree1\n
│ 2
./worktree2_/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo_/.git/worktrees/worktree2\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ branch_default_path="$(git -C './server/repo.git' symbolic-ref HEAD)"; echo "$branch_default_path"
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 055823c] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag --annotate --message='' tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master 5246c6b] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
fatal: HEAD not found below refs/heads!
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD' 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD'
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' update-ref 'refs/heads2/branch' tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' show-ref 'refs/heads2/branch'
055823c96cff9629ba12bca7f2b9165021219c1b refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[refs/heads2/branch f8eb346] 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD "$branch_default_path"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cp --no-target-directory -- './server/repo.git/HEAD' './server/repo.git/HEAD2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD2
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --all --clear-decorations
* f8eb346 - 2026-07-07 23:24 (2 seconds ago) 3 - Han Jiang (refs/heads2/branch, refs/heads2/HEAD)
| * 5246c6b - 2026-07-07 23:24 (6 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
|/
* 055823c - 2026-07-07 23:24 (7 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --clear-decorations HEAD2
* 5246c6b - 2026-07-07 23:24 (6 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
* 055823c - 2026-07-07 23:24 (7 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client' clone '../server/repo.git' './repo'
Cloning into './repo'...
done.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref
5246c6b6f6f76caaf7eb04808ad6d23c1aa438c7 refs/heads/master
5246c6b6f6f76caaf7eb04808ad6d23c1aa438c7 refs/remotes/origin/HEAD
5246c6b6f6f76caaf7eb04808ad6d23c1aa438c7 refs/remotes/origin/master
055823c96cff9629ba12bca7f2b9165021219c1b refs/tags/tag
0d7a1b6f9a621eeb679e8190599f44c3a0535b0f refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch origin '+refs/heads2/*:refs/remotes/origin/heads2/*'
From C:/Program Files/Git/test_git/client/../server/repo
* [new ref] refs/heads2/HEAD -> origin/heads2/HEAD
* [new ref] refs/heads2/branch -> origin/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cp --no-target-directory -- './client/repo/.git/HEAD' './client/repo/.git/HEAD2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' symbolic-ref HEAD2
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref
5246c6b6f6f76caaf7eb04808ad6d23c1aa438c7 refs/heads/master
5246c6b6f6f76caaf7eb04808ad6d23c1aa438c7 refs/remotes/origin/HEAD
f8eb346471197faf02758d55c0bae1f420be326a refs/remotes/origin/heads2/HEAD
f8eb346471197faf02758d55c0bae1f420be326a refs/remotes/origin/heads2/branch
5246c6b6f6f76caaf7eb04808ad6d23c1aa438c7 refs/remotes/origin/master
055823c96cff9629ba12bca7f2b9165021219c1b refs/tags/tag
0d7a1b6f9a621eeb679e8190599f44c3a0535b0f refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref HEAD
5246c6b6f6f76caaf7eb04808ad6d23c1aa438c7 refs/remotes/origin/HEAD
f8eb346471197faf02758d55c0bae1f420be326a refs/remotes/origin/heads2/HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref HEAD2
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ branch_default_path="$(git -C './server/repo.git' symbolic-ref HEAD)"; echo "$branch_default_path"
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 2e1ef6a] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag --annotate --message='' tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master 690fb46] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
fatal: HEAD not found below refs/heads!
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD' 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD'
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' update-ref 'refs/heads2/branch' tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' show-ref 'refs/heads2/branch'
2e1ef6a0689523adf1bbdbf3d1e1a89151381153 refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[refs/heads2/branch ac70661] 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD "$branch_default_path"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cp --no-target-directory -- './server/repo.git/HEAD' './server/repo.git/HEAD2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD2
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --all --clear-decorations
* ac70661 - 2026-07-07 23:24 (2 seconds ago) 3 - Han Jiang (refs/heads2/branch, refs/heads2/HEAD)
| * 690fb46 - 2026-07-07 23:24 (5 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
|/
* 2e1ef6a - 2026-07-07 23:24 (7 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --clear-decorations HEAD2
* 690fb46 - 2026-07-07 23:24 (6 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
* 2e1ef6a - 2026-07-07 23:24 (8 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client' clone '../server/repo.git' './repo'
Cloning into './repo'...
done.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref
690fb465e287d3cab8de8bf61c48ab59ef991ce0 refs/heads/master
690fb465e287d3cab8de8bf61c48ab59ef991ce0 refs/remotes/origin/HEAD
690fb465e287d3cab8de8bf61c48ab59ef991ce0 refs/remotes/origin/master
2e1ef6a0689523adf1bbdbf3d1e1a89151381153 refs/tags/tag
505adaa2559dbc2635c25d855792b6866e56bfa9 refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch origin '+refs/heads2/*:refs/remotes/origin/heads2/*'
From C:/Program Files/Git/test_git/client/../server/repo
* [new ref] refs/heads2/HEAD -> origin/heads2/HEAD
* [new ref] refs/heads2/branch -> origin/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cp --no-target-directory -- './client/repo/.git/HEAD' './client/repo/.git/HEAD2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref
690fb465e287d3cab8de8bf61c48ab59ef991ce0 refs/heads/master
690fb465e287d3cab8de8bf61c48ab59ef991ce0 refs/remotes/origin/HEAD
ac706611e7426a36b1b7de42ca06978e0ec17e2c refs/remotes/origin/heads2/HEAD
ac706611e7426a36b1b7de42ca06978e0ec17e2c refs/remotes/origin/heads2/branch
690fb465e287d3cab8de8bf61c48ab59ef991ce0 refs/remotes/origin/master
2e1ef6a0689523adf1bbdbf3d1e1a89151381153 refs/tags/tag
505adaa2559dbc2635c25d855792b6866e56bfa9 refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --branches
690fb465e287d3cab8de8bf61c48ab59ef991ce0 refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --tags
2e1ef6a0689523adf1bbdbf3d1e1a89151381153 refs/tags/tag
505adaa2559dbc2635c25d855792b6866e56bfa9 refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --branches --tags
690fb465e287d3cab8de8bf61c48ab59ef991ce0 refs/heads/master
2e1ef6a0689523adf1bbdbf3d1e1a89151381153 refs/tags/tag
505adaa2559dbc2635c25d855792b6866e56bfa9 refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ branch_default_path="$(git -C './server/repo.git' symbolic-ref HEAD)"; echo "$branch_default_path"
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 4024717] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag --annotate --message='' tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master 5a283d0] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
fatal: HEAD not found below refs/heads!
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD' 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD'
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' update-ref 'refs/heads2/branch' tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' show-ref 'refs/heads2/branch'
40247170a1eb60b8ffcb82418e294eb60a1bf36a refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[refs/heads2/branch a9cdd91] 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD "$branch_default_path"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cp --no-target-directory -- './server/repo.git/HEAD' './server/repo.git/HEAD2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD2
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --all --clear-decorations
* a9cdd91 - 2026-07-07 23:24 (2 seconds ago) 3 - Han Jiang (refs/heads2/branch, refs/heads2/HEAD)
| * 5a283d0 - 2026-07-07 23:24 (6 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
|/
* 4024717 - 2026-07-07 23:24 (7 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --clear-decorations HEAD2
* 5a283d0 - 2026-07-07 23:24 (7 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
* 4024717 - 2026-07-07 23:24 (8 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client' clone '../server/repo.git' './repo'
Cloning into './repo'...
done.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref
5a283d092fa1fc62a5e38954a4a2567833675041 refs/heads/master
5a283d092fa1fc62a5e38954a4a2567833675041 refs/remotes/origin/HEAD
5a283d092fa1fc62a5e38954a4a2567833675041 refs/remotes/origin/master
40247170a1eb60b8ffcb82418e294eb60a1bf36a refs/tags/tag
74f8bc794b89a2479b4770502651332e891766c8 refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch origin '+refs/heads2/*:refs/remotes/origin/heads2/*'
From C:/Program Files/Git/test_git/client/../server/repo
* [new ref] refs/heads2/HEAD -> origin/heads2/HEAD
* [new ref] refs/heads2/branch -> origin/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref
5a283d092fa1fc62a5e38954a4a2567833675041 refs/heads/master
5a283d092fa1fc62a5e38954a4a2567833675041 refs/remotes/origin/HEAD
a9cdd91fb426ac9bd8b68d612c05f7586fbdad65 refs/remotes/origin/heads2/HEAD
a9cdd91fb426ac9bd8b68d612c05f7586fbdad65 refs/remotes/origin/heads2/branch
5a283d092fa1fc62a5e38954a4a2567833675041 refs/remotes/origin/master
40247170a1eb60b8ffcb82418e294eb60a1bf36a refs/tags/tag
74f8bc794b89a2479b4770502651332e891766c8 refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --dereference
5a283d092fa1fc62a5e38954a4a2567833675041 refs/heads/master
5a283d092fa1fc62a5e38954a4a2567833675041 refs/remotes/origin/HEAD
a9cdd91fb426ac9bd8b68d612c05f7586fbdad65 refs/remotes/origin/heads2/HEAD
a9cdd91fb426ac9bd8b68d612c05f7586fbdad65 refs/remotes/origin/heads2/branch
5a283d092fa1fc62a5e38954a4a2567833675041 refs/remotes/origin/master
40247170a1eb60b8ffcb82418e294eb60a1bf36a refs/tags/tag
74f8bc794b89a2479b4770502651332e891766c8 refs/tags/tag_annotated
40247170a1eb60b8ffcb82418e294eb60a1bf36a refs/tags/tag_annotated^{}
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --tags
40247170a1eb60b8ffcb82418e294eb60a1bf36a refs/tags/tag
74f8bc794b89a2479b4770502651332e891766c8 refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --tags --dereference
40247170a1eb60b8ffcb82418e294eb60a1bf36a refs/tags/tag
74f8bc794b89a2479b4770502651332e891766c8 refs/tags/tag_annotated
40247170a1eb60b8ffcb82418e294eb60a1bf36a refs/tags/tag_annotated^{}
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --branches --tags
5a283d092fa1fc62a5e38954a4a2567833675041 refs/heads/master
40247170a1eb60b8ffcb82418e294eb60a1bf36a refs/tags/tag
74f8bc794b89a2479b4770502651332e891766c8 refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --branches --tags --dereference
5a283d092fa1fc62a5e38954a4a2567833675041 refs/heads/master
40247170a1eb60b8ffcb82418e294eb60a1bf36a refs/tags/tag
74f8bc794b89a2479b4770502651332e891766c8 refs/tags/tag_annotated
40247170a1eb60b8ffcb82418e294eb60a1bf36a refs/tags/tag_annotated^{}
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ branch_default_path="$(git -C './server/repo.git' symbolic-ref HEAD)"; echo "$branch_default_path"
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 07d283a] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag --annotate --message='' tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master 9f50387] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
fatal: HEAD not found below refs/heads!
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD' 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD'
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' update-ref 'refs/heads2/branch' tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' show-ref 'refs/heads2/branch'
07d283abb9eb820325be0dac520f7d605d481441 refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[refs/heads2/branch b426589] 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD "$branch_default_path"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cp --no-target-directory -- './server/repo.git/HEAD' './server/repo.git/HEAD2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD2
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --all --clear-decorations
* b426589 - 2026-07-07 23:24 (3 seconds ago) 3 - Han Jiang (refs/heads2/branch, refs/heads2/HEAD)
| * 9f50387 - 2026-07-07 23:24 (6 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
|/
* 07d283a - 2026-07-07 23:24 (8 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --clear-decorations HEAD2
* 9f50387 - 2026-07-07 23:24 (6 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
* 07d283a - 2026-07-07 23:24 (8 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client' clone '../server/repo.git' './repo'
Cloning into './repo'...
done.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref
9f503871fe40b98d99c67615c978bc4d77dfc990 refs/heads/master
9f503871fe40b98d99c67615c978bc4d77dfc990 refs/remotes/origin/HEAD
9f503871fe40b98d99c67615c978bc4d77dfc990 refs/remotes/origin/master
07d283abb9eb820325be0dac520f7d605d481441 refs/tags/tag
1aeb097b7ab927672579cfb81e5eb6e4bb22a21f refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch origin '+refs/heads2/*:refs/remotes/origin/heads2/*'
From C:/Program Files/Git/test_git/client/../server/repo
* [new ref] refs/heads2/HEAD -> origin/heads2/HEAD
* [new ref] refs/heads2/branch -> origin/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cp --no-target-directory -- './client/repo/.git/HEAD' './client/repo/.git/HEAD2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref
9f503871fe40b98d99c67615c978bc4d77dfc990 refs/heads/master
9f503871fe40b98d99c67615c978bc4d77dfc990 refs/remotes/origin/HEAD
b4265892c69b12b7de5dcf264a920ad6a130995c refs/remotes/origin/heads2/HEAD
b4265892c69b12b7de5dcf264a920ad6a130995c refs/remotes/origin/heads2/branch
9f503871fe40b98d99c67615c978bc4d77dfc990 refs/remotes/origin/master
07d283abb9eb820325be0dac520f7d605d481441 refs/tags/tag
1aeb097b7ab927672579cfb81e5eb6e4bb22a21f refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --head
9f503871fe40b98d99c67615c978bc4d77dfc990 HEAD
9f503871fe40b98d99c67615c978bc4d77dfc990 refs/heads/master
9f503871fe40b98d99c67615c978bc4d77dfc990 refs/remotes/origin/HEAD
b4265892c69b12b7de5dcf264a920ad6a130995c refs/remotes/origin/heads2/HEAD
b4265892c69b12b7de5dcf264a920ad6a130995c refs/remotes/origin/heads2/branch
9f503871fe40b98d99c67615c978bc4d77dfc990 refs/remotes/origin/master
07d283abb9eb820325be0dac520f7d605d481441 refs/tags/tag
1aeb097b7ab927672579cfb81e5eb6e4bb22a21f refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ branch_default_path="$(git -C './server/repo.git' symbolic-ref HEAD)"; echo "$branch_default_path"
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 845ec14] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag --annotate --message='' tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master 37d89ac] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
fatal: HEAD not found below refs/heads!
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD' 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD'
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' update-ref 'refs/heads2/branch' tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' show-ref 'refs/heads2/branch'
845ec14d9a2fff8d3f4982e44a064913d5f001bd refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[refs/heads2/branch 0474ed8] 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD "$branch_default_path"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cp --no-target-directory -- './server/repo.git/HEAD' './server/repo.git/HEAD2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD2
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --all --clear-decorations
* 0474ed8 - 2026-07-07 23:25 (2 seconds ago) 3 - Han Jiang (refs/heads2/branch, refs/heads2/HEAD)
| * 37d89ac - 2026-07-07 23:25 (5 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
|/
* 845ec14 - 2026-07-07 23:25 (7 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --clear-decorations HEAD2
* 37d89ac - 2026-07-07 23:25 (6 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
* 845ec14 - 2026-07-07 23:25 (8 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client' clone '../server/repo.git' './repo'
Cloning into './repo'...
done.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref
37d89ac2ce5110440124f2e7fed4e803d6c1b439 refs/heads/master
37d89ac2ce5110440124f2e7fed4e803d6c1b439 refs/remotes/origin/HEAD
37d89ac2ce5110440124f2e7fed4e803d6c1b439 refs/remotes/origin/master
845ec14d9a2fff8d3f4982e44a064913d5f001bd refs/tags/tag
f237c575b6c19e7fbcc2f70740fe2ec93381f3f7 refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch origin '+refs/heads2/*:refs/remotes/origin/heads2/*'
From C:/Program Files/Git/test_git/client/../server/repo
* [new ref] refs/heads2/HEAD -> origin/heads2/HEAD
* [new ref] refs/heads2/branch -> origin/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cp --no-target-directory -- './client/repo/.git/HEAD' './client/repo/.git/HEAD2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref
37d89ac2ce5110440124f2e7fed4e803d6c1b439 refs/heads/master
37d89ac2ce5110440124f2e7fed4e803d6c1b439 refs/remotes/origin/HEAD
0474ed8c66041be9710fc4eba360f06b923f7bf5 refs/remotes/origin/heads2/HEAD
0474ed8c66041be9710fc4eba360f06b923f7bf5 refs/remotes/origin/heads2/branch
37d89ac2ce5110440124f2e7fed4e803d6c1b439 refs/remotes/origin/master
845ec14d9a2fff8d3f4982e44a064913d5f001bd refs/tags/tag
f237c575b6c19e7fbcc2f70740fe2ec93381f3f7 refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --verify HEAD
37d89ac2ce5110440124f2e7fed4e803d6c1b439 HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --verify --quiet HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --exists HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --verify HEAD2
fatal: 'HEAD2' - not a valid ref
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --verify --quiet HEAD2
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --exists HEAD2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --exists HEAD3
error: reference does not exist
jhcarl0814@jhcarl0814 MINGW64 $?=2 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --verify tag
fatal: 'tag' - not a valid ref
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --exists tag
error: reference does not exist
jhcarl0814@jhcarl0814 MINGW64 $?=2 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --verify 'tags/tag'
fatal: 'tags/tag' - not a valid ref
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --exists 'tags/tag'
error: reference does not exist
jhcarl0814@jhcarl0814 MINGW64 $?=2 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --verify 'refs/tags/tag'
845ec14d9a2fff8d3f4982e44a064913d5f001bd refs/tags/tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --exists 'refs/tags/tag'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ branch_default_path="$(git -C './server/repo.git' symbolic-ref HEAD)"; echo "$branch_default_path"
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) cdbf27f] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag --annotate --message='' tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master 05c2632] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
fatal: HEAD not found below refs/heads!
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD' 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD'
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' update-ref 'refs/heads2/branch' tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' show-ref 'refs/heads2/branch'
cdbf27fc42fdcd5d5ff8bdfe5832ba374c97e03c refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[refs/heads2/branch 6b0d12b] 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD "$branch_default_path"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cp --no-target-directory -- './server/repo.git/HEAD' './server/repo.git/HEAD2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD2
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --all --clear-decorations
* 6b0d12b - 2026-07-07 23:25 (2 seconds ago) 3 - Han Jiang (refs/heads2/branch, refs/heads2/HEAD)
| * 05c2632 - 2026-07-07 23:25 (6 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
|/
* cdbf27f - 2026-07-07 23:25 (7 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --clear-decorations HEAD2
* 05c2632 - 2026-07-07 23:25 (7 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
* cdbf27f - 2026-07-07 23:25 (8 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client' clone '../server/repo.git' './repo'
Cloning into './repo'...
done.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref
05c2632309d5b4f2ffdaa604d81c45a160ead5d4 refs/heads/master
05c2632309d5b4f2ffdaa604d81c45a160ead5d4 refs/remotes/origin/HEAD
05c2632309d5b4f2ffdaa604d81c45a160ead5d4 refs/remotes/origin/master
cdbf27fc42fdcd5d5ff8bdfe5832ba374c97e03c refs/tags/tag
d46f776c60813495ff01ad372fa01da8479d6d2d refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch origin '+refs/heads2/*:refs/remotes/origin/heads2/*'
From C:/Program Files/Git/test_git/client/../server/repo
* [new ref] refs/heads2/HEAD -> origin/heads2/HEAD
* [new ref] refs/heads2/branch -> origin/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cp --no-target-directory -- './client/repo/.git/HEAD' './client/repo/.git/HEAD2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref
05c2632309d5b4f2ffdaa604d81c45a160ead5d4 refs/heads/master
05c2632309d5b4f2ffdaa604d81c45a160ead5d4 refs/remotes/origin/HEAD
6b0d12b6b734548a5f60a9125ac2066bf0f45855 refs/remotes/origin/heads2/HEAD
6b0d12b6b734548a5f60a9125ac2066bf0f45855 refs/remotes/origin/heads2/branch
05c2632309d5b4f2ffdaa604d81c45a160ead5d4 refs/remotes/origin/master
cdbf27fc42fdcd5d5ff8bdfe5832ba374c97e03c refs/tags/tag
d46f776c60813495ff01ad372fa01da8479d6d2d refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ branch_default_path="$(git -C './client/repo' symbolic-ref HEAD)"; echo "$branch_default_path"
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --exclude-existing <<EOF
> HEAD
> $branch_default_path
> a
> b/c
> d/e/f
> refs/tags/tag
> refs/tags/tag_annotated
> refs/tags/tag_annotated^{}
> EOF
warning: ref 'HEAD' ignored
warning: ref 'a' ignored
b/c
d/e/f
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --exclude-existing='a' <<EOF
> HEAD
> $branch_default_path
> ab
> ab/cd
> ab/cd/ef
> ab/cd/gh
> refs/tags/tag
> refs/tags/tag_annotated
> refs/tags/tag_annotated^{}
> EOF
warning: ref 'ab' ignored
ab/cd
ab/cd/ef
ab/cd/gh
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' show-ref --exclude-existing='b' <<EOF
> HEAD
> $branch_default_path
> ab
> ab/cd
> ab/cd/ef
> ab/cd/gh
> refs/tags/tag
> refs/tags/tag_annotated
> refs/tags/tag_annotated^{}
> EOF
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server1/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ branch_default_path="$(git -C './server1/repo.git' symbolic-ref HEAD)"; echo "$branch_default_path"
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server1/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 34b235f] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' tag tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' tag --annotate --message='' tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server1/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master 6cb47d0] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' symbolic-ref HEAD 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' symbolic-ref HEAD
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' branch --show-current
fatal: HEAD not found below refs/heads!
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' symbolic-ref 'refs/heads2/HEAD' 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' symbolic-ref 'refs/heads2/HEAD'
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' update-ref 'refs/heads2/branch' tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' show-ref 'refs/heads2/branch'
34b235faca967e3e593335f55e989842d5b740b5 refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server1/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[refs/heads2/branch 90e3b45] 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' symbolic-ref HEAD "$branch_default_path"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' symbolic-ref HEAD
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cp --no-target-directory -- './server1/repo.git/HEAD' './server1/repo.git/HEAD2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' symbolic-ref HEAD2
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' lg --all --clear-decorations
* 90e3b45 - 2026-07-07 23:25 (2 seconds ago) 3 - Han Jiang (refs/heads2/branch, refs/heads2/HEAD)
| * 6cb47d0 - 2026-07-07 23:25 (5 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
|/
* 34b235f - 2026-07-07 23:25 (7 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1/repo.git' lg --clear-decorations HEAD2
* 6cb47d0 - 2026-07-07 23:25 (6 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
* 34b235f - 2026-07-07 23:25 (8 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server2' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server2/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cp --no-target-directory -- './server2/repo.git/HEAD' './server2/repo.git/HEAD2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server2/repo.git' lg --all --clear-decorations
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client' init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server1 '../../server1/repo.git'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server2 'file://'"$(realpath './server2/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' ls-remote
fatal: No remote configured to list refs from.
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ branch_default_name="$(git -C './client/repo' branch --show-current)"; echo "$branch_default_name"
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' -c 'branch.'"$branch_default_name"'.remote=server1' ls-remote
From ../../server1/repo.git
6cb47d064c15db32fea20b0112e0fc6390c2cb1c HEAD
6cb47d064c15db32fea20b0112e0fc6390c2cb1c refs/heads/master
90e3b459fd2885031f21e0512721a97e7c07e94d refs/heads2/HEAD
90e3b459fd2885031f21e0512721a97e7c07e94d refs/heads2/branch
34b235faca967e3e593335f55e989842d5b740b5 refs/tags/tag
6ea605bb042797c85ea1c0dbd80c1ce6aed70dc2 refs/tags/tag_annotated
34b235faca967e3e593335f55e989842d5b740b5 refs/tags/tag_annotated^{}
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' -c 'branch.'"$branch_default_name"'.remote=server2' ls-remote
From file:///test_git/server2/repo.git
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' ls-remote server1
6cb47d064c15db32fea20b0112e0fc6390c2cb1c HEAD
6cb47d064c15db32fea20b0112e0fc6390c2cb1c refs/heads/master
90e3b459fd2885031f21e0512721a97e7c07e94d refs/heads2/HEAD
90e3b459fd2885031f21e0512721a97e7c07e94d refs/heads2/branch
34b235faca967e3e593335f55e989842d5b740b5 refs/tags/tag
6ea605bb042797c85ea1c0dbd80c1ce6aed70dc2 refs/tags/tag_annotated
34b235faca967e3e593335f55e989842d5b740b5 refs/tags/tag_annotated^{}
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' ls-remote server2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' ls-remote '.'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
Fetching server1
remote: Enumerating objects: 4, done.
remote: Counting objects: 100% (4/4), done.
remote: Compressing objects: 100% (3/3), done.
remote: Total 4 (delta 1), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (4/4), 334 bytes | 19.00 KiB/s, done.
From ../../server1/repo
* [new branch] master -> server1/master
* [new tag] tag -> tag
* [new tag] tag_annotated -> tag_annotated
Fetching server2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' ls-remote '.'
6cb47d064c15db32fea20b0112e0fc6390c2cb1c refs/remotes/server1/HEAD
6cb47d064c15db32fea20b0112e0fc6390c2cb1c refs/remotes/server1/master
34b235faca967e3e593335f55e989842d5b740b5 refs/tags/tag
6ea605bb042797c85ea1c0dbd80c1ce6aed70dc2 refs/tags/tag_annotated
34b235faca967e3e593335f55e989842d5b740b5 refs/tags/tag_annotated^{}
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' checkout "$branch_default_name"
branch 'master' set up to track 'server1/master'.
Already on 'master'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' ls-remote '.'
6cb47d064c15db32fea20b0112e0fc6390c2cb1c HEAD
6cb47d064c15db32fea20b0112e0fc6390c2cb1c refs/heads/master
6cb47d064c15db32fea20b0112e0fc6390c2cb1c refs/remotes/server1/HEAD
6cb47d064c15db32fea20b0112e0fc6390c2cb1c refs/remotes/server1/master
34b235faca967e3e593335f55e989842d5b740b5 refs/tags/tag
6ea605bb042797c85ea1c0dbd80c1ce6aed70dc2 refs/tags/tag_annotated
34b235faca967e3e593335f55e989842d5b740b5 refs/tags/tag_annotated^{}
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ branch_default_path="$(git -C './server/repo.git' symbolic-ref HEAD)"; echo "$branch_default_path"
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 8dcb962] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag --annotate --message='' tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master d376e2f] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
fatal: HEAD not found below refs/heads!
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD' 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD'
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' update-ref 'refs/heads2/branch' tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' show-ref 'refs/heads2/branch'
8dcb962e08d9dfa78631d301756a71617c3a4730 refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[refs/heads2/branch e517734] 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD "$branch_default_path"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cp --no-target-directory -- './server/repo.git/HEAD' './server/repo.git/HEAD2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD2
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --all --clear-decorations
* e517734 - 2026-07-07 23:26 (2 seconds ago) 3 - Han Jiang (refs/heads2/branch, refs/heads2/HEAD)
| * d376e2f - 2026-07-07 23:26 (6 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
|/
* 8dcb962 - 2026-07-07 23:26 (7 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --clear-decorations HEAD2
* d376e2f - 2026-07-07 23:26 (7 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
* 8dcb962 - 2026-07-07 23:26 (8 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git ls-remote './server/repo.git'
d376e2f836a9aa4a633ffa67475594c24920c451 HEAD
d376e2f836a9aa4a633ffa67475594c24920c451 refs/heads/master
e517734d5dd056b2836f4bcb94cc6ee3dbc2eadf refs/heads2/HEAD
e517734d5dd056b2836f4bcb94cc6ee3dbc2eadf refs/heads2/branch
8dcb962e08d9dfa78631d301756a71617c3a4730 refs/tags/tag
a65b0dea0e238a49a2fde0039353ef6e5513af4e refs/tags/tag_annotated
8dcb962e08d9dfa78631d301756a71617c3a4730 refs/tags/tag_annotated^{}
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git ls-remote './server/repo.git' HEAD
d376e2f836a9aa4a633ffa67475594c24920c451 HEAD
e517734d5dd056b2836f4bcb94cc6ee3dbc2eadf refs/heads2/HEAD
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git ls-remote './server/repo.git' HEAD2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ branch_default_path="$(git -C './server/repo.git' symbolic-ref HEAD)"; echo "$branch_default_path"
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) eae6592] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' tag --annotate --message='' tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master d1e617c] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
fatal: HEAD not found below refs/heads!
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD' 'refs/heads2/branch'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref 'refs/heads2/HEAD'
refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' update-ref 'refs/heads2/branch' tag
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' show-ref 'refs/heads2/branch'
eae6592f544bbe628a87afb9d3ea84572262d764 refs/heads2/branch
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[refs/heads2/branch 1268534] 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD "$branch_default_path"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ cp --no-target-directory -- './server/repo.git/HEAD' './server/repo.git/HEAD2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' symbolic-ref HEAD2
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --all --clear-decorations
* 1268534 - 2026-07-07 23:26 (3 seconds ago) 3 - Han Jiang (refs/heads2/branch, refs/heads2/HEAD)
| * d1e617c - 2026-07-07 23:26 (6 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
|/
* eae6592 - 2026-07-07 23:26 (7 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' lg --clear-decorations HEAD2
* d1e617c - 2026-07-07 23:26 (6 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master)
* eae6592 - 2026-07-07 23:26 (7 seconds ago) 1 - Han Jiang (tag: refs/tags/tag_annotated, tag: refs/tags/tag)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git ls-remote './server/repo.git'
d1e617c3bd43d8cf3b635d7635b9e59def90688e HEAD
d1e617c3bd43d8cf3b635d7635b9e59def90688e refs/heads/master
12685343ca50d09cb8546d1a8a7fd8ca0e03a4a3 refs/heads2/HEAD
12685343ca50d09cb8546d1a8a7fd8ca0e03a4a3 refs/heads2/branch
eae6592f544bbe628a87afb9d3ea84572262d764 refs/tags/tag
495eba9cd64b42de89a52710cdc8f2b68f502f8d refs/tags/tag_annotated
eae6592f544bbe628a87afb9d3ea84572262d764 refs/tags/tag_annotated^{}
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git ls-remote --refs './server/repo.git'
d1e617c3bd43d8cf3b635d7635b9e59def90688e refs/heads/master
12685343ca50d09cb8546d1a8a7fd8ca0e03a4a3 refs/heads2/HEAD
12685343ca50d09cb8546d1a8a7fd8ca0e03a4a3 refs/heads2/branch
eae6592f544bbe628a87afb9d3ea84572262d764 refs/tags/tag
495eba9cd64b42de89a52710cdc8f2b68f502f8d refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git ls-remote --symref './server/repo.git'
ref: refs/heads/master HEAD
d1e617c3bd43d8cf3b635d7635b9e59def90688e HEAD
d1e617c3bd43d8cf3b635d7635b9e59def90688e refs/heads/master
ref: refs/heads2/branch refs/heads2/HEAD
12685343ca50d09cb8546d1a8a7fd8ca0e03a4a3 refs/heads2/HEAD
12685343ca50d09cb8546d1a8a7fd8ca0e03a4a3 refs/heads2/branch
eae6592f544bbe628a87afb9d3ea84572262d764 refs/tags/tag
495eba9cd64b42de89a52710cdc8f2b68f502f8d refs/tags/tag_annotated
eae6592f544bbe628a87afb9d3ea84572262d764 refs/tags/tag_annotated^{}
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git ls-remote --symref --refs './server/repo.git'
d1e617c3bd43d8cf3b635d7635b9e59def90688e refs/heads/master
ref: refs/heads2/branch refs/heads2/HEAD
12685343ca50d09cb8546d1a8a7fd8ca0e03a4a3 refs/heads2/HEAD
12685343ca50d09cb8546d1a8a7fd8ca0e03a4a3 refs/heads2/branch
eae6592f544bbe628a87afb9d3ea84572262d764 refs/tags/tag
495eba9cd64b42de89a52710cdc8f2b68f502f8d refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git ls-remote --branches './server/repo.git'
d1e617c3bd43d8cf3b635d7635b9e59def90688e refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git ls-remote --tags './server/repo.git'
eae6592f544bbe628a87afb9d3ea84572262d764 refs/tags/tag
495eba9cd64b42de89a52710cdc8f2b68f502f8d refs/tags/tag_annotated
eae6592f544bbe628a87afb9d3ea84572262d764 refs/tags/tag_annotated^{}
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git ls-remote --tags --refs './server/repo.git'
eae6592f544bbe628a87afb9d3ea84572262d764 refs/tags/tag
495eba9cd64b42de89a52710cdc8f2b68f502f8d refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git ls-remote --branches --tags './server/repo.git'
d1e617c3bd43d8cf3b635d7635b9e59def90688e refs/heads/master
eae6592f544bbe628a87afb9d3ea84572262d764 refs/tags/tag
495eba9cd64b42de89a52710cdc8f2b68f502f8d refs/tags/tag_annotated
eae6592f544bbe628a87afb9d3ea84572262d764 refs/tags/tag_annotated^{}
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git ls-remote --branches --tags --refs './server/repo.git'
d1e617c3bd43d8cf3b635d7635b9e59def90688e refs/heads/master
eae6592f544bbe628a87afb9d3ea84572262d764 refs/tags/tag
495eba9cd64b42de89a52710cdc8f2b68f502f8d refs/tags/tag_annotated
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git ls-remote --get-url './server/repo.git'
./server/repo.git
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c 'url.scheme://authority/path/.insteadOf=./' ls-remote --get-url './server/repo.git'
scheme://authority/path/server/repo.git
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git ls-remote --get-url 'file://'"$(realpath './server/repo.git')"
realpath: ./server/repo.git: No such file or directory
file://
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c 'url.scheme://authority/path/.insteadOf=file:///' ls-remote --get-url 'file://'"$(realpath './server/repo.git')"
realpath: ./server/repo.git: No such file or directory
file://
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git ls-remote --get-url 'file://'"$(realpath '.')"'/server/repo.git'
file:///test_git/server/repo.git
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -c 'url.scheme://authority/path/.insteadOf=file:///' ls-remote --get-url 'file://'"$(realpath '.')"'/server/repo.git'
scheme://authority/path/test_git/server/repo.git
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) f74d551] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all
* master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose
* master f74d551 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose
* master f74d551 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) a54263f] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server 'file://'"$(realpath './server/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --verbose --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --remotes --verbose --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 139 bytes | 23.00 KiB/s, done.
From file:///test_git/server/repo
* [new branch] branch1 -> server/branch1
* [new branch] master -> server/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --verbose --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --remotes --verbose --verbose
server/HEAD -> server/master
server/branch1 a54263f 1
server/master a54263f 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
remotes/server/HEAD -> server/master
remotes/server/branch1 a54263f 1
remotes/server/master a54263f 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' checkout branch1
branch 'branch1' set up to track 'server/branch1'.
Switched to a new branch 'branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --verbose --verbose
* branch1 a54263f [server/branch1] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --remotes --verbose --verbose
server/HEAD -> server/master
server/branch1 a54263f 1
server/master a54263f 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
* branch1 a54263f [server/branch1] 1
remotes/server/HEAD -> server/master
remotes/server/branch1 a54263f 1
remotes/server/master a54263f 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty; git -C './repo' checkout -b branch1
[master (root-commit) 84856f5] 1
Switched to a new branch 'branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' checkout -b branch2; git -C './repo' commit --message="$((++number))" --allow-empty
Switched to a new branch 'branch2'
[branch2 36de5ea] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' checkout -b branch3 branch1; git -C './repo' commit --message="$((++number))" --allow-empty
Switched to a new branch 'branch3'
[branch3 120fc17] 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' checkout -b branch4 branch2; git -C './repo' merge --message="$((++number))" branch3
Switched to a new branch 'branch4'
Merge made by the 'ort' strategy.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 049c008 - 2026-07-07 23:27 (0 seconds ago) 4 - Han Jiang (HEAD -> refs/heads/branch4)
|\
| * 120fc17 - 2026-07-07 23:27 (1 second ago) 3 - Han Jiang (refs/heads/branch3)
* | 36de5ea - 2026-07-07 23:27 (2 seconds ago) 2 - Han Jiang (refs/heads/branch2)
|/
* 84856f5 - 2026-07-07 23:27 (2 seconds ago) 1 - Han Jiang (refs/heads/master, refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose --contains=branch2
branch2 36de5ea 2
* branch4 049c008 4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose --contains=branch3
branch3 120fc17 3
* branch4 049c008 4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose --contains=branch2 --contains=branch3
branch2 36de5ea 2
branch3 120fc17 3
* branch4 049c008 4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose --no-contains=branch2
branch1 84856f5 1
branch3 120fc17 3
master 84856f5 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose --no-contains=branch3
branch1 84856f5 1
branch2 36de5ea 2
master 84856f5 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose --no-contains=branch2 --no-contains=branch3
branch1 84856f5 1
master 84856f5 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose --merged=branch2
branch1 84856f5 1
branch2 36de5ea 2
master 84856f5 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose --merged=branch3
branch1 84856f5 1
branch3 120fc17 3
master 84856f5 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose --merged=branch2 --merged=branch3
branch1 84856f5 1
branch2 36de5ea 2
branch3 120fc17 3
master 84856f5 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose --no-merged=branch2
branch3 120fc17 3
* branch4 049c008 4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose --no-merged=branch3
branch2 36de5ea 2
* branch4 049c008 4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose --no-merged=branch2 --no-merged=branch3
* branch4 049c008 4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 024de72] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server 'file://'"$(realpath './server/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 15.00 KiB/s, done.
From file:///test_git/server/repo
* [new branch] branch1 -> server/branch1
* [new branch] master -> server/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' checkout branch1
branch 'branch1' set up to track 'server/branch1'.
Switched to a new branch 'branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
* branch1 024de72 [server/branch1] 1
remotes/server/HEAD -> server/master
remotes/server/branch1 024de72 1
remotes/server/master 024de72 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose 'refs/heads/branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose 'heads/branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose 'refs/remotes/server/branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose 'remotes/server/branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose 'server/branch1'
remotes/server/branch1 024de72 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose branch1
* branch1 024de72 [server/branch1] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose '*branch1'
* branch1 024de72 [server/branch1] 1
remotes/server/branch1 024de72 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose '*r*n*'
* branch1 024de72 [server/branch1] 1
remotes/server/branch1 024de72 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) f8d9a28] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server 'file://'"$(realpath './server/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 23.00 KiB/s, done.
From file:///test_git/server/repo
* [new branch] branch1 -> server/branch1
* [new branch] master -> server/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all
remotes/server/HEAD -> server/master
remotes/server/branch1
remotes/server/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose
remotes/server/HEAD -> server/master
remotes/server/branch1 f8d9a28 1
remotes/server/master f8d9a28 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
remotes/server/HEAD -> server/master
remotes/server/branch1 f8d9a28 1
remotes/server/master f8d9a28 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' checkout branch1
branch 'branch1' set up to track 'server/branch1'.
Switched to a new branch 'branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all
* branch1
remotes/server/HEAD -> server/master
remotes/server/branch1
remotes/server/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose
* branch1 f8d9a28 1
remotes/server/HEAD -> server/master
remotes/server/branch1 f8d9a28 1
remotes/server/master f8d9a28 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
* branch1 f8d9a28 [server/branch1] 1
remotes/server/HEAD -> server/master
remotes/server/branch1 f8d9a28 1
remotes/server/master f8d9a28 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 7d52e0c] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose
* master 7d52e0c 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --abbrev
* master 7d52e0c 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --no-abbrev
* master 7d52e0cc387baad7e32220c0983507e758f6e22c 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose
* master 7d52e0c 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose --abbrev
* master 7d52e0c 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose --no-abbrev
* master 7d52e0cc387baad7e32220c0983507e758f6e22c 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) edc4cb1] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master 1e1a060] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server 'file://'"$(realpath './server/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
remote: Enumerating objects: 3, done.
remote: Counting objects: 100% (3/3), done.
remote: Compressing objects: 100% (2/2), done.
remote: Total 3 (delta 1), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (3/3), 189 bytes | 14.00 KiB/s, done.
From file:///test_git/server/repo
* [new branch] branch1 -> server/branch1
* [new branch] master -> server/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' checkout branch1
branch 'branch1' set up to track 'server/branch1'.
Switched to a new branch 'branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' reset HEAD~1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' commit --message="$((++number))" --allow-empty
[branch1 17dc90b] 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' lg --all
* 17dc90b - 2026-07-07 23:27 (1 second ago) 3 - Han Jiang (HEAD -> refs/heads/branch1)
| * 1e1a060 - 2026-07-07 23:27 (5 seconds ago) 2 - Han Jiang (refs/remotes/server/master, refs/remotes/server/branch1, refs/remotes/server/HEAD, refs/heads/branch2)
|/
* edc4cb1 - 2026-07-07 23:27 (5 seconds ago) 1 - Han Jiang
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --format='%(HEAD) %(refname) %(objectname)%(if)%(upstream)%(then) (fetch from %(upstream:remotename) with %(upstream:remoteref):%(upstream) %(upstream:track))%(end)%(if)%(push)%(then) (push to %(if)%(push:remotename)%(then)%(push:remotename)%(else)%(upstream:remotename)%(end) with %(if)%(push:remoteref)%(then)%(push:remoteref):%(refname)%(else)push.default%(end) %(push:track))%(end)%(if)%(worktreepath)%(then) worktreepath="%(worktreepath)"%(end)'
* refs/heads/branch1 17dc90b14e009d1670aa3b0f5db7da2083bf5465 (fetch from server with refs/heads/branch1:refs/remotes/server/branch1 [ahead 1, behind 1]) (push to server with push.default [ahead 1, behind 1]) worktreepath="C:/Program Files/Git/test_git/client/repo"
refs/heads/branch2 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
refs/remotes/server/HEAD 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
refs/remotes/server/branch1 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
refs/remotes/server/master 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config remote.server.url=file:///test_git/server/repo.git
local file:.git/config remote.server.fetch=+refs/heads/*:refs/remotes/server/*
local file:.git/config branch.branch1.remote=server
local file:.git/config branch.branch1.merge=refs/heads/branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config set --local 'remote.server.push' 'refs/heads/branch1:refs/heads/branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config remote.server.url=file:///test_git/server/repo.git
local file:.git/config remote.server.fetch=+refs/heads/*:refs/remotes/server/*
local file:.git/config remote.server.push=refs/heads/branch1:refs/heads/branch1
local file:.git/config branch.branch1.remote=server
local file:.git/config branch.branch1.merge=refs/heads/branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --format='%(HEAD) %(refname) %(objectname)%(if)%(upstream)%(then) (fetch from %(upstream:remotename) with %(upstream:remoteref):%(upstream) %(upstream:track))%(end)%(if)%(push)%(then) (push to %(if)%(push:remotename)%(then)%(push:remotename)%(else)%(upstream:remotename)%(end) with %(if)%(push:remoteref)%(then)%(push:remoteref):%(refname)%(else)push.default%(end) %(push:track))%(end)%(if)%(worktreepath)%(then) worktreepath="%(worktreepath)"%(end)'
* refs/heads/branch1 17dc90b14e009d1670aa3b0f5db7da2083bf5465 (fetch from server with refs/heads/branch1:refs/remotes/server/branch1 [ahead 1, behind 1]) (push to server with refs/heads/branch1:refs/heads/branch1 [ahead 1, behind 1]) worktreepath="C:/Program Files/Git/test_git/client/repo"
refs/heads/branch2 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
refs/remotes/server/HEAD 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
refs/remotes/server/branch1 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
refs/remotes/server/master 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add '../worktree1' branch1
Preparing worktree (checking out 'branch1')
fatal: 'branch1' is already used by worktree at 'C:/Program Files/Git/test_git/client/repo'
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --force '../worktree1' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at 17dc90b 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list
C:/Program Files/Git/test_git/client/repo 17dc90b [branch1]
C:/Program Files/Git/test_git/client/worktree1 17dc90b [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --format='%(HEAD) %(refname) %(objectname)%(if)%(upstream)%(then) (fetch from %(upstream:remotename) with %(upstream:remoteref):%(upstream) %(upstream:track))%(end)%(if)%(push)%(then) (push to %(if)%(push:remotename)%(then)%(push:remotename)%(else)%(upstream:remotename)%(end) with %(if)%(push:remoteref)%(then)%(push:remoteref):%(refname)%(else)push.default%(end) %(push:track))%(end)%(if)%(worktreepath)%(then) worktreepath="%(worktreepath)"%(end)'
* refs/heads/branch1 17dc90b14e009d1670aa3b0f5db7da2083bf5465 (fetch from server with refs/heads/branch1:refs/remotes/server/branch1 [ahead 1, behind 1]) (push to server with refs/heads/branch1:refs/heads/branch1 [ahead 1, behind 1]) worktreepath="C:/Program Files/Git/test_git/client/worktree1"
refs/heads/branch2 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
refs/remotes/server/HEAD 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
refs/remotes/server/branch1 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
refs/remotes/server/master 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree add --force '../worktree2' branch1
Preparing worktree (checking out 'branch1')
HEAD is now at 17dc90b 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' worktree list
C:/Program Files/Git/test_git/client/repo 17dc90b [branch1]
C:/Program Files/Git/test_git/client/worktree1 17dc90b [branch1]
C:/Program Files/Git/test_git/client/worktree2 17dc90b [branch1]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --format='%(HEAD) %(refname) %(objectname)%(if)%(upstream)%(then) (fetch from %(upstream:remotename) with %(upstream:remoteref):%(upstream) %(upstream:track))%(end)%(if)%(push)%(then) (push to %(if)%(push:remotename)%(then)%(push:remotename)%(else)%(upstream:remotename)%(end) with %(if)%(push:remoteref)%(then)%(push:remoteref):%(refname)%(else)push.default%(end) %(push:track))%(end)%(if)%(worktreepath)%(then) worktreepath="%(worktreepath)"%(end)'
* refs/heads/branch1 17dc90b14e009d1670aa3b0f5db7da2083bf5465 (fetch from server with refs/heads/branch1:refs/remotes/server/branch1 [ahead 1, behind 1]) (push to server with refs/heads/branch1:refs/heads/branch1 [ahead 1, behind 1]) worktreepath="C:/Program Files/Git/test_git/client/worktree2"
refs/heads/branch2 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
refs/remotes/server/HEAD 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
refs/remotes/server/branch1 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
refs/remotes/server/master 1e1a060c92af3a807b29f4cb51c95d83b7e99a33
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 40440ac] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server 'file://'"$(realpath './server/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 17.00 KiB/s, done.
From file:///test_git/server/repo
* [new branch] branch1 -> server/branch1
* [new branch] master -> server/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' checkout branch1
branch 'branch1' set up to track 'server/branch1'.
Switched to a new branch 'branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
* branch1 40440ac [server/branch1] 1
remotes/server/HEAD -> server/master
remotes/server/branch1 40440ac 1
remotes/server/master 40440ac 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch branch21 branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --no-track branch22 branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --track=direct branch23 branch1
branch 'branch23' set up to track 'branch1'.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --track=inherit branch24 branch1
branch 'branch24' set up to track 'server/branch1'.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' -c 'branch.autoSetupMerge=false' branch branch31 branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' -c 'branch.autoSetupMerge=false' branch --track=direct branch311 branch1
branch 'branch311' set up to track 'branch1'.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' -c 'branch.autoSetupMerge=false' branch --track=inherit branch312 branch1
branch 'branch312' set up to track 'server/branch1'.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' -c 'branch.autoSetupMerge=always' branch branch32 branch1
branch 'branch32' set up to track 'branch1'.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' -c 'branch.autoSetupMerge=always' branch --no-track branch321 branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' -c 'branch.autoSetupMerge=inherit' branch branch33 branch1
branch 'branch33' set up to track 'server/branch1'.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' -c 'branch.autoSetupMerge=inherit' branch --no-track branch331 branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
* branch1 40440ac [server/branch1] 1
branch21 40440ac 1
branch22 40440ac 1
branch23 40440ac [branch1] 1
branch24 40440ac [server/branch1] 1
branch31 40440ac 1
branch311 40440ac [branch1] 1
branch312 40440ac [server/branch1] 1
branch32 40440ac [branch1] 1
branch321 40440ac 1
branch33 40440ac [server/branch1] 1
branch331 40440ac 1
remotes/server/HEAD -> server/master
remotes/server/branch1 40440ac 1
remotes/server/master 40440ac 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 60b040e] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --no-create-reflog branch11
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --create-reflog branch12
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'core.logAllRefUpdates=false' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'core.logAllRefUpdates=false' branch --create-reflog branch21
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'core.logAllRefUpdates=true' branch branch3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'core.logAllRefUpdates=true' branch --no-create-reflog branch31
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose
branch1 60b040e 1
branch11 60b040e 1
branch12 60b040e 1
branch2 60b040e 1
branch21 60b040e 1
branch3 60b040e 1
branch31 60b040e 1
* master 60b040e 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' reflog list
HEAD
refs/heads/branch1
refs/heads/branch11
refs/heads/branch12
refs/heads/branch21
refs/heads/branch3
refs/heads/branch31
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 029861c] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master e32df8c] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* e32df8c - 2026-07-07 23:28 (1 second ago) 2 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2)
* 029861c - 2026-07-07 23:28 (2 seconds ago) 1 - Han Jiang (refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --move branch2 branch1
fatal: a branch named 'branch1' already exists
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --move --force branch2 branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* e32df8c - 2026-07-07 23:28 (2 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch1)
* 029861c - 2026-07-07 23:28 (3 seconds ago) 1 - Han Jiang
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) cf1a0fc] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master a5d5a78] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' checkout branch1
Switched to branch 'branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* a5d5a78 - 2026-07-07 23:28 (2 seconds ago) 2 - Han Jiang (refs/heads/master, refs/heads/branch2)
* cf1a0fc - 2026-07-07 23:28 (3 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --move branch2 branch1
fatal: a branch named 'branch1' already exists
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --move --force branch2 branch1
fatal: cannot force update the branch 'branch1' used by worktree at 'C:/Program Files/Git/test_git/repo'
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) e0ef2c0] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master c6f13b7] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* c6f13b7 - 2026-07-07 23:28 (1 second ago) 2 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2)
* e0ef2c0 - 2026-07-07 23:28 (2 seconds ago) 1 - Han Jiang (refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --copy branch2 branch1
fatal: a branch named 'branch1' already exists
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --copy --force branch2 branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* c6f13b7 - 2026-07-07 23:28 (2 seconds ago) 2 - Han Jiang (HEAD -> refs/heads/master, refs/heads/branch2, refs/heads/branch1)
* e0ef2c0 - 2026-07-07 23:28 (3 seconds ago) 1 - Han Jiang
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 574679a] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master 79542d5] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' checkout branch1
Switched to branch 'branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 79542d5 - 2026-07-07 23:28 (1 second ago) 2 - Han Jiang (refs/heads/master, refs/heads/branch2)
* 574679a - 2026-07-07 23:28 (2 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --copy branch2 branch1
fatal: a branch named 'branch1' already exists
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --copy --force branch2 branch1
fatal: cannot force update the branch 'branch1' used by worktree at 'C:/Program Files/Git/test_git/repo'
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) df1b465] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master 9ddcd7f] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' reset --hard HEAD~1
HEAD is now at df1b465 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose
branch1 9ddcd7f 2
* master df1b465 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 9ddcd7f - 2026-07-07 23:28 (2 seconds ago) 2 - Han Jiang (refs/heads/branch1)
* df1b465 - 2026-07-07 23:28 (2 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --delete branch1
error: the branch 'branch1' is not fully merged
hint: If you are sure you want to delete it, run 'git branch -D branch1'
hint: Disable this message with "git config set advice.forceDeleteBranch false"
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --delete --force branch1
Deleted branch branch1 (was 9ddcd7f).
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose
* master df1b465 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* df1b465 - 2026-07-07 23:28 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 9ea6e58] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' checkout -b branch1
Switched to a new branch 'branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --list --all --verbose --verbose
* branch1 9ea6e58 1
master 9ea6e58 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 9ea6e58 - 2026-07-07 23:28 (2 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/branch1, refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --delete branch1
error: cannot delete branch 'branch1' used by worktree at 'C:/Program Files/Git/test_git/repo'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' branch --delete --force branch1
error: cannot delete branch 'branch1' used by worktree at 'C:/Program Files/Git/test_git/repo'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) b7505b2] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ branch_default_path="$(git -C './client/repo' symbolic-ref HEAD)"; echo "$branch_default_path"
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server 'file://'"$(realpath './server/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 13.00 KiB/s, done.
From file:///test_git/server/repo
* [new branch] branch1 -> server/branch1
* [new branch] master -> server/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' checkout branch1
branch 'branch1' set up to track 'server/branch1'.
Switched to a new branch 'branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
* branch1 b7505b2 [server/branch1] 1
remotes/server/HEAD -> server/master
remotes/server/branch1 b7505b2 1
remotes/server/master b7505b2 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --delete branch1
error: cannot delete branch 'branch1' used by worktree at 'C:/Program Files/Git/test_git/client/repo'
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' symbolic-ref HEAD "$branch_default_path"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' symbolic-ref HEAD
refs/heads/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --delete branch1
warning: deleting branch 'branch1' that has been merged to
'refs/remotes/server/branch1', but not yet merged to HEAD
Deleted branch branch1 (was b7505b2).
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
remotes/server/HEAD -> server/master
remotes/server/branch1 b7505b2 1
remotes/server/master b7505b2 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 9e0baa6] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server 'file://'"$(realpath './server/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 139 bytes | 17.00 KiB/s, done.
From file:///test_git/server/repo
* [new branch] branch1 -> server/branch1
* [new branch] master -> server/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' checkout branch1
branch 'branch1' set up to track 'server/branch1'.
Switched to a new branch 'branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
* branch1 9e0baa6 [server/branch1] 1
remotes/server/HEAD -> server/master
remotes/server/branch1 9e0baa6 1
remotes/server/master 9e0baa6 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --delete server/branch1
error: branch 'server/branch1' not found.
Did you forget --remote?
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --delete --remotes branch1
error: remote-tracking branch 'branch1' not found
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --delete --remotes server/branch1
Deleted remote-tracking branch server/branch1 (was 9e0baa6).
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
* branch1 9e0baa6 [server/branch1: gone] 1
remotes/server/HEAD -> server/master
remotes/server/master 9e0baa6 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) bef4249] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server/repo.git' branch branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' init
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server 'file://'"$(realpath './server/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config remote.server.url=file:///test_git/server/repo.git
local file:.git/config remote.server.fetch=+refs/heads/*:refs/remotes/server/*
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 139 bytes | 17.00 KiB/s, done.
From file:///test_git/server/repo
* [new branch] branch1 -> server/branch1
* [new branch] master -> server/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config remote.server.url=file:///test_git/server/repo.git
local file:.git/config remote.server.fetch=+refs/heads/*:refs/remotes/server/*
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' checkout branch1
branch 'branch1' set up to track 'server/branch1'.
Switched to a new branch 'branch1'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config remote.server.url=file:///test_git/server/repo.git
local file:.git/config remote.server.fetch=+refs/heads/*:refs/remotes/server/*
local file:.git/config branch.branch1.remote=server
local file:.git/config branch.branch1.merge=refs/heads/branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --unset-upstream branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config remote.server.url=file:///test_git/server/repo.git
local file:.git/config remote.server.fetch=+refs/heads/*:refs/remotes/server/*
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --set-upstream-to='refs/heads/branch1' branch1
warning: not setting branch 'branch1' as its own upstream
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --set-upstream-to='heads/branch1' branch1
warning: not setting branch 'branch1' as its own upstream
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --set-upstream-to='branch1' branch1
warning: not setting branch 'branch1' as its own upstream
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config remote.server.url=file:///test_git/server/repo.git
local file:.git/config remote.server.fetch=+refs/heads/*:refs/remotes/server/*
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --set-upstream-to='refs/remotes/server/branch1' branch1
branch 'branch1' set up to track 'server/branch1'.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config remote.server.url=file:///test_git/server/repo.git
local file:.git/config remote.server.fetch=+refs/heads/*:refs/remotes/server/*
local file:.git/config branch.branch1.remote=server
local file:.git/config branch.branch1.merge=refs/heads/branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --set-upstream-to='remotes/server/branch1' branch1
branch 'branch1' set up to track 'server/branch1'.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config remote.server.url=file:///test_git/server/repo.git
local file:.git/config remote.server.fetch=+refs/heads/*:refs/remotes/server/*
local file:.git/config branch.branch1.remote=server
local file:.git/config branch.branch1.merge=refs/heads/branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --set-upstream-to='server/branch1' branch1
branch 'branch1' set up to track 'server/branch1'.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config remote.server.url=file:///test_git/server/repo.git
local file:.git/config remote.server.fetch=+refs/heads/*:refs/remotes/server/*
local file:.git/config branch.branch1.remote=server
local file:.git/config branch.branch1.merge=refs/heads/branch1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty; git -C './repo' tag tag1
[master (root-commit) 746f859] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty; git -C './repo' tag tag2
[master 26d4c59] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' reset --hard HEAD~1; git -C './repo' commit --message="$((++number))" --allow-empty; git -C './repo' tag tag3
HEAD is now at 746f859 1
[master 4b247f8] 3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' merge --message="$((++number))" tag2; git -C './repo' tag tag4
Merge made by the 'ort' strategy.
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 111f152 - 2026-07-07 23:29 (1 second ago) 4 - Han Jiang (HEAD -> refs/heads/master, tag: refs/tags/tag4)
|\
| * 26d4c59 - 2026-07-07 23:29 (2 seconds ago) 2 - Han Jiang (tag: refs/tags/tag2)
* | 4b247f8 - 2026-07-07 23:29 (1 second ago) 3 - Han Jiang (tag: refs/tags/tag3)
|/
* 746f859 - 2026-07-07 23:29 (3 seconds ago) 1 - Han Jiang (tag: refs/tags/tag1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list --contains=tag2
tag2
tag4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list --contains=tag3
tag3
tag4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list --contains=tag2 --contains=tag3
tag2
tag3
tag4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list --no-contains=tag2
tag1
tag3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list --no-contains=tag3
tag1
tag2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list --no-contains=tag2 --no-contains=tag3
tag1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list --merged=tag2
tag1
tag2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list --merged=tag3
tag1
tag3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list --merged=tag2 --merged=tag3
tag1
tag2
tag3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list --no-merged=tag2
tag3
tag4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list --no-merged=tag3
tag2
tag4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list --no-merged=tag2 --no-merged=tag3
tag4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message=$'1\n2\n3\n4' --allow-empty
[master (root-commit) 3a08609] 1 2 3 4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag tag1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --annotate --message=$'5\n6\n7\n8' tag2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list
tag1
tag2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list -n
tag1 1
tag2 5
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list -n99
tag1 1
2
3
4
tag2 5
6
7
8
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ export GNUPGHOME="$(realpath '.')"'/.gnupg'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mkdir --parents -- "$GNUPGHOME"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ touch -- "$GNUPGHOME"'/common.conf'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --list-public-keys --with-colons --with-keygrip
gpg: keybox '/test_git/.gnupg/pubring.kbx' created
gpg: /test_git/.gnupg/trustdb.gpg: trustdb created
tru::1:1783423799:0:3:1:5
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --list-secret-keys --with-colons
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --quick-generate-key --yes --pinentry-mode=loopback --passphrase='' 'Han Jiang <jhcarl0814@gmail.com>'
We need to generate a lot of random bytes. It is a good idea to perform
some other action (type on the keyboard, move the mouse, utilize the
disks) during the prime generation; this gives the random number
generator a better chance to gain enough entropy.
We need to generate a lot of random bytes. It is a good idea to perform
some other action (type on the keyboard, move the mouse, utilize the
disks) during the prime generation; this gives the random number
generator a better chance to gain enough entropy.
gpg: directory '/test_git/.gnupg/openpgp-revocs.d' created
gpg: revocation certificate stored as '/test_git/.gnupg/openpgp-revocs.d/A8D8CF57020463AE52999BE09BB4326643D4B2B0.rev'
public and secret key created and signed.
pub ed25519 2026-07-07 [SC] [expires: 2029-07-06]
A8D8CF57020463AE52999BE09BB4326643D4B2B0
uid Han Jiang <jhcarl0814@gmail.com>
sub cv25519 2026-07-07 [E]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --list-public-keys --with-colons --with-keygrip
gpg: checking the trustdb
gpg: marginals needed: 3 completes needed: 1 trust model: pgp
gpg: depth: 0 valid: 1 signed: 0 trust: 0-, 0q, 0n, 0m, 0f, 1u
gpg: next trustdb check due at 2029-07-06
tru:o:1:1783423799:1:3:1:5
pub:u:255:22:9BB4326643D4B2B0:1783423799:1878031799::u:::scESC:::::ed25519:::0:
fpr:::::::::A8D8CF57020463AE52999BE09BB4326643D4B2B0:
grp:::::::::67E846B8491327F3DF33E53ABA356D83F80BB9D7:
uid:u::::1783423799::E7C6FA1B44CE84FDE9CBEAB5ECDA7C3664640E65::Han Jiang <jhcarl0814@gmail.com>::::::::::0:
sub:u:255:18:B30A54761BF8780D:1783423799::::::e:::::cv25519::
fpr:::::::::E286970B5C78A4C9CBD4EC8BB30A54761BF8780D:
grp:::::::::60DADAFD499E94AB5F098E0A1B361F8F0F4FAB82:
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --list-secret-keys --with-colons
sec:u:255:22:9BB4326643D4B2B0:1783423799:1878031799::u:::scESC:::+::ed25519:::0:
fpr:::::::::A8D8CF57020463AE52999BE09BB4326643D4B2B0:
grp:::::::::67E846B8491327F3DF33E53ABA356D83F80BB9D7:
uid:u::::1783423799::E7C6FA1B44CE84FDE9CBEAB5ECDA7C3664640E65::Han Jiang <jhcarl0814@gmail.com>::::::::::0:
ssb:u:255:18:B30A54761BF8780D:1783423799::::::e:::+::cv25519::
fpr:::::::::E286970B5C78A4C9CBD4EC8BB30A54761BF8780D:
grp:::::::::60DADAFD499E94AB5F098E0A1B361F8F0F4FAB82:
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) aed5bca] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag tag1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --annotate --message="$((++number))" tag2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --sign --message="$((++number))" tag3
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* aed5bca - 2026-07-07 23:30 (2 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, tag: refs/tags/tag2, tag: refs/tags/tag1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' for-each-ref refs/tags
aed5bca97244f012622d3e74d8add6ccf05ef8dd commit refs/tags/tag1
483ac7f4ad338bfedede521f08223440c322d568 tag refs/tags/tag2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' show --tags
commit aed5bca97244f012622d3e74d8add6ccf05ef8dd (HEAD -> master, tag: tag2, tag: tag1)
Author: Han Jiang <jhcarl0814@gmail.com>
Date: Tue Jul 7 23:30:01 2026 +1200
1
tag tag2
Tagger: Han Jiang <jhcarl0814@gmail.com>
Date: Tue Jul 7 23:30:02 2026 +1200
2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --list --format='%(HEAD) %(refname) %(objectname) %(objecttype)%(if:equals=commit)%(objecttype)%(then) author="%(authorname) %(authoremail) %(authordate:iso8601-strict)" committer="%(committername) %(committeremail) %(committerdate:iso8601-strict)"%(else) tagger="%(taggername) %(taggeremail) %(taggerdate:iso8601-strict)" *author="%(*authorname) %(*authoremail) %(*authordate:iso8601-strict)" *committer="%(*committername) %(*committeremail) %(*committerdate:iso8601-strict)"%(if)%(contents:signature)%(then)'$'\n''%(contents:signature)%(end)%(end)'
refs/tags/tag1 aed5bca97244f012622d3e74d8add6ccf05ef8dd commit author="Han Jiang <jhcarl0814@gmail.com> 2026-07-07T23:30:01+12:00" committer="Han Jiang <jhcarl0814@gmail.com> 2026-07-07T23:30:01+12:00"
refs/tags/tag2 483ac7f4ad338bfedede521f08223440c322d568 tag tagger="Han Jiang <jhcarl0814@gmail.com> 2026-07-07T23:30:02+12:00" *author="Han Jiang <jhcarl0814@gmail.com> 2026-07-07T23:30:01+12:00" *committer="Han Jiang <jhcarl0814@gmail.com> 2026-07-07T23:30:01+12:00"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ export GNUPGHOME="$(realpath '.')"'/.gnupg'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mkdir --parents -- "$GNUPGHOME"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ touch -- "$GNUPGHOME"'/common.conf'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --list-public-keys --with-colons --with-keygrip
gpg: keybox '/test_git/.gnupg/pubring.kbx' created
gpg: /test_git/.gnupg/trustdb.gpg: trustdb created
tru::1:1783423810:0:3:1:5
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --list-secret-keys --with-colons
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --quick-generate-key --yes --pinentry-mode=loopback --passphrase='' 'Han Jiang <jhcarl0814@gmail.com>'
We need to generate a lot of random bytes. It is a good idea to perform
some other action (type on the keyboard, move the mouse, utilize the
disks) during the prime generation; this gives the random number
generator a better chance to gain enough entropy.
We need to generate a lot of random bytes. It is a good idea to perform
some other action (type on the keyboard, move the mouse, utilize the
disks) during the prime generation; this gives the random number
generator a better chance to gain enough entropy.
gpg: directory '/test_git/.gnupg/openpgp-revocs.d' created
gpg: revocation certificate stored as '/test_git/.gnupg/openpgp-revocs.d/FC66B0B83A20DB3FD1ED5A9B24E0D2816696F405.rev'
public and secret key created and signed.
pub ed25519 2026-07-07 [SC] [expires: 2029-07-06]
FC66B0B83A20DB3FD1ED5A9B24E0D2816696F405
uid Han Jiang <jhcarl0814@gmail.com>
sub cv25519 2026-07-07 [E]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --list-public-keys --with-colons --with-keygrip
gpg: checking the trustdb
gpg: marginals needed: 3 completes needed: 1 trust model: pgp
gpg: depth: 0 valid: 1 signed: 0 trust: 0-, 0q, 0n, 0m, 0f, 1u
gpg: next trustdb check due at 2029-07-06
tru:o:1:1783423810:1:3:1:5
pub:u:255:22:24E0D2816696F405:1783423810:1878031810::u:::scESC:::::ed25519:::0:
fpr:::::::::FC66B0B83A20DB3FD1ED5A9B24E0D2816696F405:
grp:::::::::39A138D10A1A5D71AF781DF9C566C6D5552A2F0B:
uid:u::::1783423810::E7C6FA1B44CE84FDE9CBEAB5ECDA7C3664640E65::Han Jiang <jhcarl0814@gmail.com>::::::::::0:
sub:u:255:18:3B58249E9085C785:1783423810::::::e:::::cv25519::
fpr:::::::::FE3F6FF4E20EED6CDACB034A3B58249E9085C785:
grp:::::::::096A2F2C84322B8BA31F2AD4ED1BB34FFC95940D:
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --list-secret-keys --with-colons
sec:u:255:22:24E0D2816696F405:1783423810:1878031810::u:::scESC:::+::ed25519:::0:
fpr:::::::::FC66B0B83A20DB3FD1ED5A9B24E0D2816696F405:
grp:::::::::39A138D10A1A5D71AF781DF9C566C6D5552A2F0B:
uid:u::::1783423810::E7C6FA1B44CE84FDE9CBEAB5ECDA7C3664640E65::Han Jiang <jhcarl0814@gmail.com>::::::::::0:
ssb:u:255:18:3B58249E9085C785:1783423810::::::e:::+::cv25519::
fpr:::::::::FE3F6FF4E20EED6CDACB034A3B58249E9085C785:
grp:::::::::096A2F2C84322B8BA31F2AD4ED1BB34FFC95940D:
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 71df990] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag tag11
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'tag.gpgSign=false' tag tag12
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'tag.gpgSign=true' tag --message="$((++number))" tag13
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'tag.gpgSign=true' tag --no-sign tag131
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --annotate --message="$((++number))" tag21
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'tag.gpgSign=false' tag --annotate --message="$((++number))" tag22
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'tag.gpgSign=true' tag --annotate --message="$((++number))" tag23
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'tag.gpgSign=true' tag --annotate --message="$((++number))" --no-sign tag231
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --sign --message="$((++number))" tag3
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --list-public-keys --with-colons --with-keygrip # https://www.gnupg.org/documentation/manuals/gnupg24/gpg.1.html # https://github.com/gpg/gnupg/blob/master/doc/DETAILS
tru::1:1783423811:1878031810:3:1:5
pub:u:255:22:24E0D2816696F405:1783423810:1878031810::u:::scESC:::::ed25519:::0:
fpr:::::::::FC66B0B83A20DB3FD1ED5A9B24E0D2816696F405:
grp:::::::::39A138D10A1A5D71AF781DF9C566C6D5552A2F0B:
uid:u::::1783423810::E7C6FA1B44CE84FDE9CBEAB5ECDA7C3664640E65::Han Jiang <jhcarl0814@gmail.com>::::::::::0:
sub:u:255:18:3B58249E9085C785:1783423810::::::e:::::cv25519::
fpr:::::::::FE3F6FF4E20EED6CDACB034A3B58249E9085C785:
grp:::::::::096A2F2C84322B8BA31F2AD4ED1BB34FFC95940D:
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --local-user=0x"$(gpg --list-public-keys --with-colons --with-keygrip | awk 'BEGIN { FS = ":"; } $1 == "fpr" { print($10); exit; }')" --message="$((++number))" tag41
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --local-user="$(gpg --list-public-keys --with-colons --with-keygrip | awk 'BEGIN { FS = ":"; } $1 == "fpr" { print($10); exit; }')" --message="$((++number))" tag411
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --local-user=0x"$(gpg --list-public-keys --with-colons --with-keygrip | awk 'BEGIN { FS = ":"; } $1 == "pub" { print($5); exit; }')" --message="$((++number))" tag42
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --local-user="$(gpg --list-public-keys --with-colons --with-keygrip | awk 'BEGIN { FS = ":"; } $1 == "pub" { print($5); exit; }')" --message="$((++number))" tag421
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --local-user=="$(gpg --list-public-keys --with-colons --with-keygrip | awk 'BEGIN { FS = ":"; } $1 == "uid" { print($10); exit; }')" --message="$((++number))" tag43
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --local-user="$(gpg --list-public-keys --with-colons --with-keygrip | awk 'BEGIN { FS = ":"; } $1 == "uid" { print($10); exit; }')" --message="$((++number))" tag431
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --local-user='=Han Jiang <jhcarl0814@gmail.com>' --message="$((++number))" tag44
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --local-user='Han Jiang <jhcarl0814@gmail.com>' --message="$((++number))" tag441
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --local-user='*Han Jiang' --message="$((++number))" tag45
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --local-user='Han Jiang' --message="$((++number))" tag451
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --local-user='<jhcarl0814@gmail.com>' --message="$((++number))" tag46
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --local-user='jhcarl0814@gmail.com' --message="$((++number))" tag461
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --local-user='&'"$(gpg --list-public-keys --with-colons --with-keygrip | awk 'BEGIN { FS = ":"; } $1 == "grp" { print($10); exit; }')" --message="$((++number))" tag47
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 71df990 - 2026-07-07 23:30 (12 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, tag: refs/tags/tag231, tag: refs/tags/tag22, tag: refs/tags/tag21, tag: refs/tags/tag131, tag: refs/tags/tag12, tag: refs/tags/tag11)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' for-each-ref refs/tags
71df9908da8130ae76761dc3c366d8e6ca51856d commit refs/tags/tag11
71df9908da8130ae76761dc3c366d8e6ca51856d commit refs/tags/tag12
71df9908da8130ae76761dc3c366d8e6ca51856d commit refs/tags/tag131
ce6bf9ea6346703230404ed459c2903ab5240667 tag refs/tags/tag21
16daeb5323cf4f3eeebe7300e73ead43fa657112 tag refs/tags/tag22
a789a75d9737a4038b9a11d4d609cd51c51eb958 tag refs/tags/tag231
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' show --tags
commit 71df9908da8130ae76761dc3c366d8e6ca51856d (HEAD -> master, tag: tag231, tag: tag22, tag: tag21, tag: tag131, tag: tag12, tag: tag11)
Author: Han Jiang <jhcarl0814@gmail.com>
Date: Tue Jul 7 23:30:12 2026 +1200
1
tag tag21
Tagger: Han Jiang <jhcarl0814@gmail.com>
Date: Tue Jul 7 23:30:14 2026 +1200
3
tag tag22
Tagger: Han Jiang <jhcarl0814@gmail.com>
Date: Tue Jul 7 23:30:15 2026 +1200
4
tag tag231
Tagger: Han Jiang <jhcarl0814@gmail.com>
Date: Tue Jul 7 23:30:16 2026 +1200
6
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) 30560d1] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag tag1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --create-reflog tag11
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --no-create-reflog tag12
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'core.logAllRefUpdates=false' tag tag2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'core.logAllRefUpdates=false' tag --create-reflog tag21
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'core.logAllRefUpdates=true' tag tag3
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'core.logAllRefUpdates=true' tag --no-create-reflog tag31
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'core.logAllRefUpdates=always' tag tag4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' -c 'core.logAllRefUpdates=always' tag --no-create-reflog tag41
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* 30560d1 - 2026-07-07 23:30 (4 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, tag: refs/tags/tag41, tag: refs/tags/tag4, tag: refs/tags/tag31, tag: refs/tags/tag3, tag: refs/tags/tag21, tag: refs/tags/tag2, tag: refs/tags/tag12, tag: refs/tags/tag11, tag: refs/tags/tag1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' for-each-ref refs/tags
30560d1db5b1aa69e87931214c16c038c5847bf0 commit refs/tags/tag1
30560d1db5b1aa69e87931214c16c038c5847bf0 commit refs/tags/tag11
30560d1db5b1aa69e87931214c16c038c5847bf0 commit refs/tags/tag12
30560d1db5b1aa69e87931214c16c038c5847bf0 commit refs/tags/tag2
30560d1db5b1aa69e87931214c16c038c5847bf0 commit refs/tags/tag21
30560d1db5b1aa69e87931214c16c038c5847bf0 commit refs/tags/tag3
30560d1db5b1aa69e87931214c16c038c5847bf0 commit refs/tags/tag31
30560d1db5b1aa69e87931214c16c038c5847bf0 commit refs/tags/tag4
30560d1db5b1aa69e87931214c16c038c5847bf0 commit refs/tags/tag41
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' show --tags
commit 30560d1db5b1aa69e87931214c16c038c5847bf0 (HEAD -> master, tag: tag41, tag: tag4, tag: tag31, tag: tag3, tag: tag21, tag: tag2, tag: tag12, tag: tag11, tag: tag1)
Author: Han Jiang <jhcarl0814@gmail.com>
Date: Tue Jul 7 23:30:29 2026 +1200
1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' reflog list
HEAD
refs/heads/master
refs/tags/tag11
refs/tags/tag21
refs/tags/tag4
refs/tags/tag41
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message=$'1\n2\n3\n4' --allow-empty
[master (root-commit) e3a960a] 1 2 3 4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag tag1; git -C './repo' tag tag2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* e3a960a - 2026-07-07 23:30 (1 second ago) 1 2 3 4 - Han Jiang (HEAD -> refs/heads/master, tag: refs/tags/tag2, tag: refs/tags/tag1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' for-each-ref refs/tags
e3a960ae1aea1dd25c3592a727fcb4e2caa0d729 commit refs/tags/tag1
e3a960ae1aea1dd25c3592a727fcb4e2caa0d729 commit refs/tags/tag2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' show --tags
commit e3a960ae1aea1dd25c3592a727fcb4e2caa0d729 (HEAD -> master, tag: tag2, tag: tag1)
Author: Han Jiang <jhcarl0814@gmail.com>
Date: Tue Jul 7 23:30:39 2026 +1200
1
2
3
4
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --delete 'tag*'
error: tag 'tag*' not found.
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --delete tag1 tag2
Deleted tag 'tag1' (was e3a960a)
Deleted tag 'tag2' (was e3a960a)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* e3a960a - 2026-07-07 23:30 (3 seconds ago) 1 2 3 4 - Han Jiang (HEAD -> refs/heads/master)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' for-each-ref refs/tags
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' show --tags
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ export GNUPGHOME="$(realpath '.')"'/.gnupg'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mkdir --parents -- "$GNUPGHOME"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ touch -- "$GNUPGHOME"'/common.conf'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --list-public-keys --with-colons --with-keygrip
gpg: keybox '/test_git/.gnupg/pubring.kbx' created
gpg: /test_git/.gnupg/trustdb.gpg: trustdb created
tru::1:1783423848:0:3:1:5
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --list-secret-keys --with-colons
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --quick-generate-key --yes --pinentry-mode=loopback --passphrase='' 'Han Jiang <jhcarl0814@gmail.com>'
We need to generate a lot of random bytes. It is a good idea to perform
some other action (type on the keyboard, move the mouse, utilize the
disks) during the prime generation; this gives the random number
generator a better chance to gain enough entropy.
We need to generate a lot of random bytes. It is a good idea to perform
some other action (type on the keyboard, move the mouse, utilize the
disks) during the prime generation; this gives the random number
generator a better chance to gain enough entropy.
gpg: directory '/test_git/.gnupg/openpgp-revocs.d' created
gpg: revocation certificate stored as '/test_git/.gnupg/openpgp-revocs.d/157A62A6E883245FE1E833CAE62BAA9C07242D7E.rev'
public and secret key created and signed.
pub ed25519 2026-07-07 [SC] [expires: 2029-07-06]
157A62A6E883245FE1E833CAE62BAA9C07242D7E
uid Han Jiang <jhcarl0814@gmail.com>
sub cv25519 2026-07-07 [E]
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --list-public-keys --with-colons --with-keygrip
gpg: checking the trustdb
gpg: marginals needed: 3 completes needed: 1 trust model: pgp
gpg: depth: 0 valid: 1 signed: 0 trust: 0-, 0q, 0n, 0m, 0f, 1u
gpg: next trustdb check due at 2029-07-06
tru:o:1:1783423848:1:3:1:5
pub:u:255:22:E62BAA9C07242D7E:1783423848:1878031848::u:::scESC:::::ed25519:::0:
fpr:::::::::157A62A6E883245FE1E833CAE62BAA9C07242D7E:
grp:::::::::D6EF2DF394D721C15BE8AE5F88F84C5B7645353F:
uid:u::::1783423848::E7C6FA1B44CE84FDE9CBEAB5ECDA7C3664640E65::Han Jiang <jhcarl0814@gmail.com>::::::::::0:
sub:u:255:18:AE852722B1595208:1783423848::::::e:::::cv25519::
fpr:::::::::E64CC41D9D95199E31CBEC9BAE852722B1595208:
grp:::::::::EE160D0C5A3C316000F0919EA557ABCE68A41AF3:
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ gpg --list-secret-keys --with-colons
sec:u:255:22:E62BAA9C07242D7E:1783423848:1878031848::u:::scESC:::+::ed25519:::0:
fpr:::::::::157A62A6E883245FE1E833CAE62BAA9C07242D7E:
grp:::::::::D6EF2DF394D721C15BE8AE5F88F84C5B7645353F:
uid:u::::1783423848::E7C6FA1B44CE84FDE9CBEAB5ECDA7C3664640E65::Han Jiang <jhcarl0814@gmail.com>::::::::::0:
ssb:u:255:18:AE852722B1595208:1783423848::::::e:::+::cv25519::
fpr:::::::::E64CC41D9D95199E31CBEC9BAE852722B1595208:
grp:::::::::EE160D0C5A3C316000F0919EA557ABCE68A41AF3:
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' commit --message="$((++number))" --allow-empty
[master (root-commit) af07f0e] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag tag1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --annotate --message="$((++number))" tag2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --sign --message="$((++number))" tag3
error: gpg failed to sign the data:
gpg: Fatal: can't create directory '/test_git/repo/C:/Program Files/Git/test_git/.gnupg': No such file or directory
error: unable to sign the tag
The tag message has been left in .git/TAG_EDITMSG
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' lg --all
* af07f0e - 2026-07-07 23:30 (2 seconds ago) 1 - Han Jiang (HEAD -> refs/heads/master, tag: refs/tags/tag2, tag: refs/tags/tag1)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' for-each-ref refs/tags
af07f0e254a3a2a2c0ba1c434283aad4a7296283 commit refs/tags/tag1
b1c2c9a13110604182c9f57336d033623b695ca3 tag refs/tags/tag2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' show --tags
commit af07f0e254a3a2a2c0ba1c434283aad4a7296283 (HEAD -> master, tag: tag2, tag: tag1)
Author: Han Jiang <jhcarl0814@gmail.com>
Date: Tue Jul 7 23:30:50 2026 +1200
1
tag tag2
Tagger: Han Jiang <jhcarl0814@gmail.com>
Date: Tue Jul 7 23:30:51 2026 +1200
2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --verify tag1
error: tag1: cannot verify a non-tag object of type commit.
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --verify tag2
object af07f0e254a3a2a2c0ba1c434283aad4a7296283
type commit
tag tag2
tagger Han Jiang <jhcarl0814@gmail.com> 1783423851 +1200
2
error: no signature found
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --verify tag3
error: tag 'tag3' not found.
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' tag --verify tag1 tag2 tag3
error: tag1: cannot verify a non-tag object of type commit.
object af07f0e254a3a2a2c0ba1c434283aad4a7296283
type commit
tag tag2
tagger Han Jiang <jhcarl0814@gmail.com> 1783423851 +1200
2
error: no signature found
error: tag 'tag3' not found.
jhcarl0814@jhcarl0814 MINGW64 $?=1 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo1'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo1/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo1' config list --local --show-origin --show-scope
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴config -/0o100/regular file rw-r--r--/0o644
│ │ ├╴description -/0o100/regular file rw-r--r--/0o644
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ │ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo2' init
fatal: cannot change to './repo2': No such file or directory
jhcarl0814@jhcarl0814 MINGW64 $?=128 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ mkdir --parents -- './repo2'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo2' init
Initialized empty Git repository in C:/Program Files/Git/test_git/repo2/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init '-repo3'
error: unknown switch `r'
usage: git init [-q | --quiet] [--bare] [--template=<template-directory>]
[--separate-git-dir <git-dir>] [--object-format=<format>]
[--ref-format=<format>]
[-b <branch-name> | --initial-branch=<branch-name>]
[--shared[=<permissions>]] [<directory>]
--[no-]template <template-directory>
directory from which templates will be used
--[no-]bare create a bare repository
--shared[=<permissions>]
specify that the git repository is to be shared amongst several users
-q, --[no-]quiet be quiet
--[no-]separate-git-dir <gitdir>
separate git dir from working tree
-b, --[no-]initial-branch <name>
override the name of the initial branch
--[no-]object-format <hash>
specify the hash algorithm to use
--[no-]ref-format <format>
specify the reference format to use
jhcarl0814@jhcarl0814 MINGW64 $?=129 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './-repo4'
Initialized empty Git repository in C:/Program Files/Git/test_git/-repo4/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init -- '-repo5'
Initialized empty Git repository in C:/Program Files/Git/test_git/-repo5/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init --end-of-options '-repo6'
Initialized empty Git repository in C:/Program Files/Git/test_git/-repo6/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './dir1/dir2/repo7'
Initialized empty Git repository in C:/Program Files/Git/test_git/dir1/dir2/repo7/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ which --all 'git' | sort | uniq | while IFS= read -r path_of_git; do
> echo "$path_of_git"
> tree "$(realpath "$(dirname "$path_of_git")"'/../share/git-core/templates')"
> done
/cmd/git
realpath: /cmd/../share/git-core/templates: No such file or directory
find: ‘’: No such file or directory
/mingw64/bin/git
/mingw64/share/git-core/templates/ d/0o040/directory rwxr-xr-x/0o755
├╴description -/0o100/regular file rw-r--r--/0o644
├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴exclude -/0o100/regular file rw-r--r--/0o644
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree "$(git -c 'a.b=%(prefix)/' config get --type=path 'a.b')"'share/git-core/templates'
C:/Program Files/Git/mingw64/share/git-core/templates/ d/0o040/directory rwxr-xr-x/0o755
├╴description -/0o100/regular file rw-r--r--/0o644
├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴exclude -/0o100/regular file rw-r--r--/0o644
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init --template="$(git -c 'a.b=%(prefix)/' config get --type=path 'a.b')"'share/git-core/templates' './repo1'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo1/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴config -/0o100/regular file rw-r--r--/0o644
│ │ ├╴description -/0o100/regular file rw-r--r--/0o644
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ │ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init --separate-git-dir='./repo1.git' './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo1.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git -/0o100/regular file rw-r--r--/0o644
├╴repo1.git/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴config -/0o100/regular file rw-r--r--/0o644
│ ├╴description -/0o100/regular file rw-r--r--/0o644
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo'
./repo/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo1.git\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo1.git
C:/Program Files/Git/test_git/repo1.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init --separate-git-dir='./repo2.git' './repo'
Reinitialized existing Git repository in C:/Program Files/Git/test_git/repo2.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git -/0o100/regular file rw-r--r--/0o644
├╴repo2.git/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴config -/0o100/regular file rw-r--r--/0o644
│ ├╴description -/0o100/regular file rw-r--r--/0o644
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo'
./repo/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo2.git\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo2.git
C:/Program Files/Git/test_git/repo2.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴config -/0o100/regular file rw-r--r--/0o644
│ │ ├╴description -/0o100/regular file rw-r--r--/0o644
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ │ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo/.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init --separate-git-dir='./repo.git' './repo'
Reinitialized existing Git repository in C:/Program Files/Git/test_git/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git -/0o100/regular file rw-r--r--/0o644
├╴repo.git/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴config -/0o100/regular file rw-r--r--/0o644
│ ├╴description -/0o100/regular file rw-r--r--/0o644
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo'
./repo/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo.git\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo.git
C:/Program Files/Git/test_git/repo.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo'
Reinitialized existing Git repository in C:/Program Files/Git/test_git/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git -/0o100/regular file rw-r--r--/0o644
├╴repo.git/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴config -/0o100/regular file rw-r--r--/0o644
│ ├╴description -/0o100/regular file rw-r--r--/0o644
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo'
./repo/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo.git\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo.git
C:/Program Files/Git/test_git/repo.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init --separate-git-dir='./repo/.git' './repo'
Reinitialized existing Git repository in C:/Program Files/Git/test_git/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git -/0o100/regular file rw-r--r--/0o644
├╴repo.git/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴config -/0o100/regular file rw-r--r--/0o644
│ ├╴description -/0o100/regular file rw-r--r--/0o644
│ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo'
./repo/ d/0o040/directory rwxr-xr-x/0o755
├╴.git -/0o100/regular file rw-r--r--/0o644
│ 1 gitdir: C:/Program Files/Git/test_git/repo.git\n
│ 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo.git
C:/Program Files/Git/test_git/repo.git
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init --separate-git-dir='./repo/.git2' './repo'
Reinitialized existing Git repository in C:/Program Files/Git/test_git/repo/.git2/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git -/0o100/regular file rw-r--r--/0o644
│ ├╴.git2/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴config -/0o100/regular file rw-r--r--/0o644
│ │ ├╴description -/0o100/regular file rw-r--r--/0o644
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ │ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo/.git'
./repo/.git -/0o100/regular file rw-r--r--/0o644
1 gitdir: C:/Program Files/Git/test_git/repo/.git2\n
2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo' rev-parse --path-format=absolute --absolute-git-dir --git-common-dir --show-toplevel
C:/Program Files/Git/test_git/repo/.git2
C:/Program Files/Git/test_git/repo/.git2
C:/Program Files/Git/test_git/repo
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init './repo1'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo1/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ tree '.'
./ d/0o040/directory rwxr-xr-x/0o755
├╴repo1/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴.git/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴config -/0o100/regular file rw-r--r--/0o644
│ │ ├╴description -/0o100/regular file rw-r--r--/0o644
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ ├╴hooks/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴applypatch-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴fsmonitor-watchman.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴post-update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-applypatch.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-merge-commit.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-push.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-rebase.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴pre-receive.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴prepare-commit-msg.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴push-to-checkout.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴sendemail-validate.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ │ ├╴update.sample -/0o100/regular file rwxr-xr-x/0o755
│ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴exclude -/0o100/regular file rw-r--r--/0o644
│ │ ├╴objects/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴info/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴pack/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴refs/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴heads/ d/0o040/directory rwxr-xr-x/0o755
│ │ │ ├╴tags/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo1/.git/HEAD'
./repo1/.git/HEAD -/0o100/regular file rw-r--r--/0o644
1 ref: refs/heads/master\n
2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo1' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init --initial-branch="$(git var GIT_DEFAULT_BRANCH)"'1' './repo1'
warning: re-init: ignored --initial-branch=master1
Reinitialized existing Git repository in C:/Program Files/Git/test_git/repo1/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo1' branch --show-current
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git init --initial-branch="$(git var GIT_DEFAULT_BRANCH)"'2' './repo2'
Initialized empty Git repository in C:/Program Files/Git/test_git/repo2/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './repo2/.git/HEAD'
./repo2/.git/HEAD -/0o100/regular file rw-r--r--/0o644
1 ref: refs/heads/master2\n
2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './repo2' branch --show-current
master2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client' init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-scope --show-origin
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server1 '../server1/repo.git'
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server2 'file://'"$(realpath './server2/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote --verbose
server1 ../server1/repo.git (fetch)
server1 ../server1/repo.git (push)
server2 file:///test_git/server2/repo.git (fetch)
server2 file:///test_git/server2/repo.git (push)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-scope --show-origin
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config remote.server1.url=../server1/repo.git
local file:.git/config remote.server1.fetch=+refs/heads/*:refs/remotes/server1/*
local file:.git/config remote.server2.url=file:///test_git/server2/repo.git
local file:.git/config remote.server2.fetch=+refs/heads/*:refs/remotes/server2/*
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote remove server1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote remove server2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-scope --show-origin
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server1' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server1/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server1/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 378bf41] 1
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './server2' init --bare './repo.git'
Initialized empty Git repository in C:/Program Files/Git/test_git/server2/repo.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ branch_default_name="$(git -C './server2/repo.git' branch --show-current)"; echo "$branch_default_name"
master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git --git-dir='./server2/repo.git' --work-tree='.' commit --message="$((++number))" --allow-empty
[master (root-commit) 990288d] 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client' init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-scope --show-origin
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './client/repo/.git/refs'
./client/repo/.git/refs/ d/0o040/directory rwxr-xr-x/0o755
├╴heads/ d/0o040/directory rwxr-xr-x/0o755
├╴tags/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server1 'file://'"$(realpath './server1/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add -m "$branch_default_name" server2 'file://'"$(realpath './server2/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote --verbose
server1 file:///test_git/server1/repo.git (fetch)
server1 file:///test_git/server1/repo.git (push)
server2 file:///test_git/server2/repo.git (fetch)
server2 file:///test_git/server2/repo.git (push)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-scope --show-origin
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config remote.server1.url=file:///test_git/server1/repo.git
local file:.git/config remote.server1.fetch=+refs/heads/*:refs/remotes/server1/*
local file:.git/config remote.server2.url=file:///test_git/server2/repo.git
local file:.git/config remote.server2.fetch=+refs/heads/*:refs/remotes/server2/*
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './client/repo/.git/refs'
./client/repo/.git/refs/ d/0o040/directory rwxr-xr-x/0o755
├╴heads/ d/0o040/directory rwxr-xr-x/0o755
├╴remotes/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴server2/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 ref: refs/remotes/server2/master\n
│ │ │ 2
├╴tags/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' fetch --all
Fetching server1
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 19.00 KiB/s, done.
From file:///test_git/server1/repo
* [new branch] master -> server1/master
Fetching server2
remote: Enumerating objects: 2, done.
remote: Counting objects: 100% (2/2), done.
remote: Total 2 (delta 0), reused 0 (delta 0), pack-reused 0 (from 0)
Unpacking objects: 100% (2/2), 138 bytes | 27.00 KiB/s, done.
From file:///test_git/server2/repo
* [new branch] master -> server2/master
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' branch --list --all --verbose --verbose
remotes/server1/HEAD -> server1/master
remotes/server1/master 378bf41 1
remotes/server2/HEAD -> server2/master
remotes/server2/master 990288d 2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ treex './client/repo/.git/refs'
./client/repo/.git/refs/ d/0o040/directory rwxr-xr-x/0o755
├╴heads/ d/0o040/directory rwxr-xr-x/0o755
├╴remotes/ d/0o040/directory rwxr-xr-x/0o755
│ ├╴server1/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 ref: refs/remotes/server1/master\n
│ │ │ 2
│ │ ├╴master -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 378bf4176b0c48fed8ee1f37ef58da4928158ae5\n
│ │ │ 2
│ ├╴server2/ d/0o040/directory rwxr-xr-x/0o755
│ │ ├╴HEAD -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 ref: refs/remotes/server2/master\n
│ │ │ 2
│ │ ├╴master -/0o100/regular file rw-r--r--/0o644
│ │ │ 1 990288dda06c65453703a31a466eae8875636be0\n
│ │ │ 2
├╴tags/ d/0o040/directory rwxr-xr-x/0o755
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client' init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-scope --show-origin
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server1 'file://'"$(realpath './server1/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add -t branch1 -t branch2 server2 'file://'"$(realpath './server2/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote --verbose
server1 file:///test_git/server1/repo.git (fetch)
server1 file:///test_git/server1/repo.git (push)
server2 file:///test_git/server2/repo.git (fetch)
server2 file:///test_git/server2/repo.git (push)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-scope --show-origin
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config remote.server1.url=file:///test_git/server1/repo.git
local file:.git/config remote.server1.fetch=+refs/heads/*:refs/remotes/server1/*
local file:.git/config remote.server2.url=file:///test_git/server2/repo.git
local file:.git/config remote.server2.fetch=+refs/heads/branch1:refs/remotes/server2/branch1
local file:.git/config remote.server2.fetch=+refs/heads/branch2:refs/remotes/server2/branch2
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client' init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-scope --show-origin
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server1 'file://'"$(realpath './server1/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add --tags server2 'file://'"$(realpath './server2/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add --no-tags server3 'file://'"$(realpath './server3/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote --verbose
server1 file:///test_git/server1/repo.git (fetch)
server1 file:///test_git/server1/repo.git (push)
server2 file:///test_git/server2/repo.git (fetch)
server2 file:///test_git/server2/repo.git (push)
server3 file:///test_git/server3/repo.git (fetch)
server3 file:///test_git/server3/repo.git (push)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-scope --show-origin
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config remote.server1.url=file:///test_git/server1/repo.git
local file:.git/config remote.server1.fetch=+refs/heads/*:refs/remotes/server1/*
local file:.git/config remote.server2.url=file:///test_git/server2/repo.git
local file:.git/config remote.server2.fetch=+refs/heads/*:refs/remotes/server2/*
local file:.git/config remote.server2.tagopt=--tags
local file:.git/config remote.server3.url=file:///test_git/server3/repo.git
local file:.git/config remote.server3.fetch=+refs/heads/*:refs/remotes/server3/*
local file:.git/config remote.server3.tagopt=--no-tags
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client' init './repo'
Initialized empty Git repository in C:/Program Files/Git/test_git/client/repo/.git/
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote --verbose
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-scope --show-origin
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add server1 'file://'"$(realpath './server1/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add --mirror=fetch server2 'file://'"$(realpath './server2/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote add --mirror=push server3 'file://'"$(realpath './server3/repo.git')"
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' remote --verbose
server1 file:///test_git/server1/repo.git (fetch)
server1 file:///test_git/server1/repo.git (push)
server2 file:///test_git/server2/repo.git (fetch)
server2 file:///test_git/server2/repo.git (push)
server3 file:///test_git/server3/repo.git (fetch)
server3 file:///test_git/server3/repo.git (push)
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ git -C './client/repo' config list --local --show-scope --show-origin
local file:.git/config core.repositoryformatversion=0
local file:.git/config core.filemode=false
local file:.git/config core.bare=false
local file:.git/config core.logallrefupdates=true
local file:.git/config core.ignorecase=true
local file:.git/config remote.server1.url=file:///test_git/server1/repo.git
local file:.git/config remote.server1.fetch=+refs/heads/*:refs/remotes/server1/*
local file:.git/config remote.server2.url=file:///test_git/server2/repo.git
local file:.git/config remote.server2.fetch=+refs/*:refs/*
local file:.git/config remote.server3.url=file:///test_git/server3/repo.git
local file:.git/config remote.server3.mirror=true
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=/test_git %cd%=C:\Program Files\Git\test_git
$ exit
jhcarl0814@jhcarl0814 MINGW64 $?=0 $!= $OLDPWD=/ $PWD=