New checkout --track behaviour?
- From
- Francesco Occhipinti <francesco.occhipinti@tracsis.com>
- Date
- Dec 12, 2024, 10:29 UTC
- Message-ID
- <DB9PR08MB71949D21F5F0E81911F0D50F903F2@DB9PR08MB7194.eurprd08.prod.outlook.com>
- In-Reply-To
- <DB9PR08MB7194822B81F17420B2D3C149903F2@DB9PR08MB7194.eurprd08.prod.outlook.com>
Hello,
Did the interface change in recent git versions? I am pretty sure i used to git checkout -tb new_branch, now getting error: option `--track' expects "direct" or "inherit".
User `geirha` on libera#git helped me troubleshooting. They noticed that:
- git help checkout differs in its description of --track between 2.34.1 (ubuntu 22.04) and 2.43.0 (ubuntu 24.04), so looks like it did change recently
- according to the commit message at https://github.com/git/git/commit/6327f0efed36c64d98a140110171362b7cb75a52, -t is supposed to be equivalent to --track=direct, so likely a bug rather than intentional change
I did read all options in `man git config` looking for something related. Found only branch.autoSetupMerge, but neither setting it to `always` nor `inherit` helped
Cheers, fran