git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* FW: bug: fatal: this operation must be run in a work tree - after enabling worktreeConfig=true
       [not found] <AM6PR09MB2598893AEA5DB2D55DDFBF299A140@AM6PR09MB2598.eurprd09.prod.outlook.com>
@ 2020-02-15 21:11 ` Boaz_Nahum
  0 siblings, 0 replies; only message in thread
From: Boaz_Nahum @ 2020-02-15 21:11 UTC (permalink / raw)
  To: git


Hi
(English is not my language)

We started to work with sparse-checkout and we found two issues.

We work with bare repository, with a worktree 'arounds' it.

Two issues:

Issue 1) fatal: this operation must be run in a work tree

TO reproduce, In bare repository:
   git worktree add ../testwt pub/empty -no-checkout
Switch to worktree
  git sparse-checkout init

Result:

    fatal: this operation must be run in a work tree
any operation in any worktree now ends with:
    fatal: this operation must be run in a work tree

This is because  extensions.worktreeConfig=true
Workaround
1. core.bare=false in bare - not acceptable
2. Remove worktreeConfig=true  - not good idea if we want to work with sparse-checkout
3. core.bare=false  in worktree, but we need to apply it on any worktree

Please note that this happens even  if in time of creating worktree worktreeConfig=true

Issue 2) fatal: Unable to create 'F:/views/MonoCentral/worktrees/testwt3/info/sparse-checkout.lock': No such file or directory

To reproduce, same as above, but worktreeConfig=false before starting,
Result:
    fatal: Unable to create 'F:/views/MonoCentral/worktrees/testwt3/info/sparse-checkout.lock': No such file or directory

Workaround:
  Set extensions.worktreeConfig=true  before adding the worktree or running sparse-checkout



Thanks
Boaz


The content of this message is APPLIED MATERIALS CONFIDENTIAL. If you are not the intended recipient, please notify me, delete this email and do not use or distribute this email.

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2020-02-15 21:40 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <AM6PR09MB2598893AEA5DB2D55DDFBF299A140@AM6PR09MB2598.eurprd09.prod.outlook.com>
2020-02-15 21:11 ` FW: bug: fatal: this operation must be run in a work tree - after enabling worktreeConfig=true Boaz_Nahum

Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).