Unexpected (bug-like) behavior in `git ls-remote` matching.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Setup as follows.

example repo: git@xxxxxxxxxx:owner/repo.git
example branches:
* ABC-1
* feature/ABC-1
* XBC-1
* EABC-1

These are all things that work as "expected".
```
$ git ls-remote --heads git@xxxxxxxxxx:owner/repo.git ABC-
$ git ls-remote --heads git@xxxxxxxxxx:owner/repo.git BC-1
$ git ls-remote --heads git@xxxxxxxxxx:owner/repo.git XBC-1
<ref>    refs/head/XBC-1
$ git ls-remote --heads git@xxxxxxxxxx:owner/repo.git *BC-1
<ref>    refs/head/ABC-1
<ref>    refs/head/EABC-1
<ref>    refs/head/XBC-1
<ref>    refs/head/feature/ABC-1
$ git ls-remote --heads git@xxxxxxxxxx:owner/repo.git "[^/]ABC-1"
<ref>    refs/head/EABC-1
```

What is totally unexpected.... is the most simple search for ABC-1...
```
$ git ls-remote --heads git@xxxxxxxxxx:owner/repo.git ABC-1
<ref>    refs/head/ABC-1
<ref>    refs/head/feature/ABC-1
```

It appears that the matching behavior trims at the last slash... which
isn't correct.

V/R,
William



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux