Using git branch --set-upstream resulted in this message:
The --set-upstream flag is deprecated and will be removed. Consider
using --track or --set-upstream-to
Without thinking about it too much and assuming verb-object order, I then tried
git branch --track remotes/origin/X
This resulted in
Branch remotes/origin/X set up to track local branch X
Argh, not what I wanted. The remote was supposed to be tracked, not do the tracking. How can I undo this and set the remote branch not to track anything.