Re: Allowing "/" in the name of a git remote is a strange choice
- From
Lidong Yan <yldhome2d2@gmail.com>
- Date
- Jul 4, 2025, 08:17 UTC
- Message-ID
- <AC45E9DD-5E2B-4DD5-B2C4-9276C70D05A6@gmail.com>
- In-Reply-To
- <aGdi6GRbI6Txm25Q@pks.im>
Patrick Steinhardt <ps@pks.im> write:
Show 5 quoted lines
> > We cannot just blanket-disallow this now, true. But shouldn't Git be > able to detect this conflict, similar to how a user cannot have both > refs/heads/branch and refs/heads/branch/nested? >
I also find `git fetch` works fine, but check out remote branch detect this conflict
$ git branch --set-upstream-to=origin/chat/master chat/master
Gives
fatal: not tracking: ambiguous information for ref 'refs/remotes/origin/chat/master' hint: There are multiple remotes whose fetch refspecs map to the remote hint: tracking ref 'refs/remotes/origin/chat/master': hint: origin/chat hint: origin hint: hint: This is typically a configuration error. hint: hint: To support setting up tracking branches, ensure that hint: different remotes' fetch refspecs map into different hint: tracking namespaces