Skip to content

index::State::to_tree()#2560

Draft
Sebastian Thiel (Byron) wants to merge 3 commits intomainfrom
write-tree
Draft

index::State::to_tree()#2560
Sebastian Thiel (Byron) wants to merge 3 commits intomainfrom
write-tree

Conversation

@Byron
Copy link
Copy Markdown
Member

@Byron Sebastian Thiel (Byron) commented Apr 30, 2026

Allow writing back a tree in the hopes that it will be faster than what git2 offers.
The reason that's slow is also that we don't currently maintain the tree-cache when editing the index,
but instead remove it.

However, this is also something that could be added.

Related to gitbutlerapp/gitbutler#13566 .

Tasks

  • refackiew
  • per-path tree cache invalidation

@Byron Sebastian Thiel (Byron) force-pushed the write-tree branch 2 times, most recently from 179a475 to 08a7604 Compare April 30, 2026 02:34
Sebastian Thiel (Byron) and others added 3 commits May 1, 2026 07:27
The PR CI lint job failed with clippy::semicolon-if-nothing-returned in gix-status/tests/status/index_as_worktree.rs after the keep-tree-cache call was expanded into a block closure. Add the requested semicolon so the closure has an explicit unit statement.

The fast-test matrix also failed after tests regenerated gix-index/tests/fixtures/generated-archives/v2_deeper_tree.tar and git diff reported the archive had changed. The archive still carried an older fixture identity, so regenerate it from the current v2_deeper_tree fixture script identity to prevent CI from rewriting it.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants