jj/cli
Martin von Zweigbergk c55e08023e workspace: don't lose sparsed-away paths when recovering workspace
When an operation is missing and we recover the workspace, we create a
new working-copy commit on top of the desired working-copy commit (per
the available head operation). We then reset the working copy to an
empty tree because it shouldn't really matter much which commit we
reset to. However, when the workspace is sparse, it does matter, as
the test case from the previous patch shows. This patch fixes it by
replacing the `reset_to_empty()` method by a new `recover(&Commit)`,
which effectively resets to the empty tree and then resets to the
commit. That way, any subsequent snapshotting will result keep the
paths from that tree for paths outside the sparse patterns.
2024-03-16 07:30:36 -07:00
..
examples workspace: don't lose sparsed-away paths when recovering workspace 2024-03-16 07:30:36 -07:00
src workspace: don't lose sparsed-away paths when recovering workspace 2024-03-16 07:30:36 -07:00
testing revset: ad-hoc optimization for range queries containing unwanted wanted heads 2024-02-22 23:26:29 +09:00
tests workspace: don't lose sparsed-away paths when recovering workspace 2024-03-16 07:30:36 -07:00
build.rs build: update rerun-if conditions to watch .git/HEAD in colocated repo 2023-08-06 12:16:11 +09:00
Cargo.toml templater: add similarity hint to no such method/keyword errors 2024-02-28 09:03:04 +09:00
LICENSE cargo: add LICENSE file to each crate we publish 2023-09-22 21:48:28 -07:00