Commit graph

3411 commits

Author SHA1 Message Date
Yuya Nishihara
8e54e3e70e local_working_copy: move comment about conflict file to the right place
I also removed "now" from "is now a normal file" because conflicts should be
materialized as a normal file. "is a normal file" is tested by caller.
2024-11-27 23:06:47 +09:00
Yuya Nishihara
f819dc9345 config: extract layer management from cli LayeredConfigs to jj-lib
Some checks are pending
binaries / Build binary artifacts (push) Waiting to run
nix / flake check (push) Waiting to run
build / build (, macos-13) (push) Waiting to run
build / build (, macos-14) (push) Waiting to run
build / build (, ubuntu-latest) (push) Waiting to run
build / build (, windows-latest) (push) Waiting to run
build / build (--all-features, ubuntu-latest) (push) Waiting to run
build / Build jj-lib without Git support (push) Waiting to run
build / Check protos (push) Waiting to run
build / Check formatting (push) Waiting to run
build / Check that MkDocs can build the docs (push) Waiting to run
build / Check that MkDocs can build the docs with latest Python and uv (push) Waiting to run
build / cargo-deny (advisories) (push) Waiting to run
build / cargo-deny (bans licenses sources) (push) Waiting to run
build / Clippy check (push) Waiting to run
Codespell / Codespell (push) Waiting to run
website / prerelease-docs-build-deploy (ubuntu-latest) (push) Waiting to run
Scorecards supply-chain security / Scorecards analysis (push) Waiting to run
Layers are now constructed per file, not per source type. This will allow us
to report precise position where bad configuration variable is set. Because
layers are now created per file, it makes sense to require existence of the
file, instead of ignoring missing files which would leave an empty layer in the
stack. The path existence is tested by ConfigEnv::existing_config_path(), so I
simply made the new load_file/dir() methods stricter. However, we still need
config::File::required(false) flag in order to accept /dev/null as an empty
TOML file.

The lib type is renamed to StackedConfig to avoid name conflicts. The cli
LayeredConfigs will probably be reorganized as an environment object that
builds a StackedConfig.
2024-11-25 12:09:21 +09:00
Yuya Nishihara
d75aaf3f8d config: move ConfigSource to jj-lib, make it Copy + Ord
I decided to add `path: Option<PathBuf>` as a separate field, not a parameter
of ConfigSource::Repo|User variants.
2024-11-25 12:09:21 +09:00
Martin von Zweigbergk
10c90a5099 merged_tree: propagate errors from conflict iterator
Some checks failed
binaries / Build binary artifacts (push) Has been cancelled
nix / flake check (push) Has been cancelled
build / build (, macos-13) (push) Has been cancelled
build / build (, macos-14) (push) Has been cancelled
build / build (, ubuntu-latest) (push) Has been cancelled
build / build (, windows-latest) (push) Has been cancelled
build / build (--all-features, ubuntu-latest) (push) Has been cancelled
build / Build jj-lib without Git support (push) Has been cancelled
build / Check protos (push) Has been cancelled
build / Check formatting (push) Has been cancelled
build / Check that MkDocs can build the docs (push) Has been cancelled
build / Check that MkDocs can build the docs with latest Python and uv (push) Has been cancelled
build / cargo-deny (advisories) (push) Has been cancelled
build / cargo-deny (bans licenses sources) (push) Has been cancelled
build / Clippy check (push) Has been cancelled
Codespell / Codespell (push) Has been cancelled
website / prerelease-docs-build-deploy (ubuntu-latest) (push) Has been cancelled
Scorecards supply-chain security / Scorecards analysis (push) Has been cancelled
2024-11-23 13:53:04 -08:00
Scott Taylor
26f5d6150c conflicts: add "git" conflict marker style
Adds a new "git" conflict marker style option. This option matches Git's
"diff3" conflict style, allowing these conflicts to be parsed by some
external tools that don't support JJ-style conflicts. If a conflict has
more than 2 sides, then it falls back to the similar "snapshot" conflict
marker style.

The conflict parsing code now supports parsing Git-style conflict
markers in addition to the normal JJ-style conflict markers, regardless
of the conflict marker style setting. This has the benefit of allowing
the user to switch the conflict marker style while they already have
conflicts checked out, and their old conflicts will still be parsed
correctly.

Example of "git" conflict markers:

```
<<<<<<< Side #1 (Conflict 1 of 1)
fn example(word: String) {
    println!("word is {word}");
||||||| Base
fn example(w: String) {
    println!("word is {w}");
=======
fn example(w: &str) {
    println!("word is {w}");
>>>>>>> Side #2 (Conflict 1 of 1 ends)
}
```
2024-11-23 08:28:47 -06:00
Scott Taylor
ec6220d51f merge: add as_slice() method
This was already possible using `merge.iter().as_slice()`, but I think
this is cleaner.
2024-11-23 08:28:47 -06:00
Scott Taylor
54c453ba8d conflicts: extract function for materializing hunk
This will make it easier to add a second code path for Git-style
conflicts in a later commit.
2024-11-23 08:28:47 -06:00
Scott Taylor
d2b06b9cf9 conflicts: add "snapshot" conflict marker style
Adds a new "snapshot" conflict marker style which returns a series of
snapshots, similar to Git's "diff3" conflict style. The "snapshot"
option uses a subset of the conflict hunk headers as the "diff" option
(it just doesn't use "%%%%%%%"), meaning that the two options are
trivially compatible with each other (i.e. a file materialized with
"snapshot" can be parsed with "diff" and vice versa).

Example of "snapshot" conflict markers:

```
<<<<<<< Conflict 1 of 1
+++++++ Contents of side #1
fn example(word: String) {
    println!("word is {word}");
------- Contents of base
fn example(w: String) {
    println!("word is {w}");
+++++++ Contents of side #2
fn example(w: &str) {
    println!("word is {w}");
>>>>>>> Conflict 1 of 1 ends
}
```
2024-11-23 08:28:47 -06:00
Scott Taylor
863cba309f conflicts: extract header output into separate functions
This will make it easier to add separate logic for "snapshot" style
conflict markers in the next commit.
2024-11-23 08:28:47 -06:00
Scott Taylor
3c182687e8 conflicts: replace "if let" with "let else"
This makes the code a bit easier to follow in my opinion.
2024-11-23 08:28:47 -06:00
Scott Taylor
e5cb9f94f6 conflicts: add "ui.conflict-marker-style" config
Adds a new "ui.conflict-marker-style" config option. The "diff" option
is the default jj-style conflict markers with a snapshot and a series of
diffs to apply to the snapshot. New conflict marker style options will
be added in later commits.

The majority of the changes in this commit are from passing the config
option down to the code that materializes the conflicts.

Example of "diff" conflict markers:

```
<<<<<<< Conflict 1 of 1
+++++++ Contents of side #1
fn example(word: String) {
    println!("word is {word}");
%%%%%%% Changes from base to side #2
-fn example(w: String) {
+fn example(w: &str) {
     println!("word is {w}");
>>>>>>> Conflict 1 of 1 ends
}
```
2024-11-23 08:28:47 -06:00
Martin von Zweigbergk
d409a318f4 local_working_copy: fix documentation of TreeState::snapshot()
Some checks are pending
binaries / Build binary artifacts (push) Waiting to run
nix / flake check (push) Waiting to run
build / build (, macos-13) (push) Waiting to run
build / build (, macos-14) (push) Waiting to run
build / build (, ubuntu-latest) (push) Waiting to run
build / build (, windows-latest) (push) Waiting to run
build / build (--all-features, ubuntu-latest) (push) Waiting to run
build / Build jj-lib without Git support (push) Waiting to run
build / Check protos (push) Waiting to run
build / Check formatting (push) Waiting to run
build / Check that MkDocs can build the docs (push) Waiting to run
build / Check that MkDocs can build the docs with latest Python and uv (push) Waiting to run
build / cargo-deny (advisories) (push) Waiting to run
build / cargo-deny (bans licenses sources) (push) Waiting to run
build / Clippy check (push) Waiting to run
Codespell / Codespell (push) Waiting to run
website / prerelease-docs-build-deploy (ubuntu-latest) (push) Waiting to run
Scorecards supply-chain security / Scorecards analysis (push) Waiting to run
Since commit e716fe7, the function no longer returns a tree id. That
commit updated the function documentation to match the new behavior,
but then the old documentation was restored in commit ef83f2b, perhaps
by a bad merge conflict resolution.
2024-11-22 23:06:06 -08:00
Yuya Nishihara
a5c96bcf70 settings: simply forward .get_<type>(key) to .get::<type>(key)
Some checks are pending
binaries / Build binary artifacts (push) Waiting to run
nix / flake check (push) Waiting to run
build / build (, macos-13) (push) Waiting to run
build / build (, macos-14) (push) Waiting to run
build / build (, ubuntu-latest) (push) Waiting to run
build / build (, windows-latest) (push) Waiting to run
build / build (--all-features, ubuntu-latest) (push) Waiting to run
build / Build jj-lib without Git support (push) Waiting to run
build / Check protos (push) Waiting to run
build / Check formatting (push) Waiting to run
build / Check that MkDocs can build the docs (push) Waiting to run
build / Check that MkDocs can build the docs with latest Python and uv (push) Waiting to run
build / cargo-deny (advisories) (push) Waiting to run
build / cargo-deny (bans licenses sources) (push) Waiting to run
build / Clippy check (push) Waiting to run
Codespell / Codespell (push) Waiting to run
website / prerelease-docs-build-deploy (ubuntu-latest) (push) Waiting to run
Scorecards supply-chain security / Scorecards analysis (push) Waiting to run
There's a subtle difference in error message, but the conversion function to be
called is the same. The error message now includes "for key <key>", which is
nice.
2024-11-23 10:20:27 +09:00
Yuya Nishihara
fc57139340 settings: add forwarding getters, replace most of .config() uses
.get_table() isn't implemented because it isn't cheap to build a HashMap,
and a table of an abstract Value type wouldn't be useful. Maybe we'll
instead provide an iterator of table keys.

.config() is renamed to .raw_config() to break existing callers.
2024-11-23 10:20:27 +09:00
Yuya Nishihara
f239b1e8f0 settings: pass around &UserSettings instead of &config::Config consistently
Ui::with_config() is unchanged because I'm not sure if UserSettings should be
constructed earlier. I assume UserSettings will hold an immutable copy of
LayerdConfigs object, whereas Ui has to be initialized before all config layers
get loaded.
2024-11-23 10:20:27 +09:00
Yuya Nishihara
6d26d53eab config: add type alias for config::ConfigError
We'll probably add our own ConfigError type later.
2024-11-23 10:20:27 +09:00
Yuya Nishihara
5ad0f3dcf6 config: extract ConfigNamePathBuf to jj-lib
I'm planning to rewrite config store layer by leveraging toml_edit instead of
the config crate. It will allow us to merge config overlays in a way that
deprecated keys are resolved within a layer prior to merging, for example.

This patch moves ConfigNamePathBuf to jj-lib where new config API will be
hosted. We'll probably extract LayeredConfigs to this module, but we'll first
need to split environment dependencies from it.
2024-11-23 10:20:27 +09:00
Scott Taylor
6e959fa12c conflicts: allow stripped trailing whitespace in diffs
Some editors strip trailing whitespace on save, which breaks any diffs
which have context lines, since the parsing function expects them to
start with a space. There's no visual difference between " \n" and "\n",
so it seems reasonable to accept both.
2024-11-22 18:00:05 -06:00
Scott Taylor
efacbcbd45 conflicts: demo failed parse of diff with empty line 2024-11-22 18:00:05 -06:00
Scott Taylor
9674852dc7 conflicts: allow CRLF line endings on conflict markers
Currently, conflict markers ending in CRLF line endings aren't allowed.
I don't see any reason why we should reject them, since some
editors/tools might produce CRLF automatically on Windows when saving
files, which would break the conflicts otherwise.
2024-11-22 18:00:05 -06:00
Scott Taylor
ee7f829d4c conflicts: demo failed parse of markers with CRLF 2024-11-22 18:00:05 -06:00
Yuya Nishihara
c6bb019d41 diff: optimize allocation of histogram entries for unique words
Some checks are pending
binaries / Build binary artifacts (push) Waiting to run
nix / flake check (push) Waiting to run
build / build (, macos-13) (push) Waiting to run
build / build (, macos-14) (push) Waiting to run
build / build (, ubuntu-latest) (push) Waiting to run
build / build (, windows-latest) (push) Waiting to run
build / build (--all-features, ubuntu-latest) (push) Waiting to run
build / Build jj-lib without Git support (push) Waiting to run
build / Check protos (push) Waiting to run
build / Check formatting (push) Waiting to run
build / Check that MkDocs can build the docs (push) Waiting to run
build / Check that MkDocs can build the docs with latest Python and uv (push) Waiting to run
build / cargo-deny (advisories) (push) Waiting to run
build / cargo-deny (bans licenses sources) (push) Waiting to run
build / Clippy check (push) Waiting to run
Codespell / Codespell (push) Waiting to run
website / prerelease-docs-build-deploy (ubuntu-latest) (push) Waiting to run
Scorecards supply-chain security / Scorecards analysis (push) Waiting to run
```
group                             new                     old
-----                             ---                     ---
bench_diff_git_git_read_tree_c    1.00     34.5±0.26µs    1.32     45.7±0.11µs
bench_diff_lines/modified/10k     1.00     28.2±0.10ms    1.19     33.5±0.69ms
bench_diff_lines/modified/1k      1.00      2.6±0.01ms    1.15      3.0±0.01ms
bench_diff_lines/reversed/10k     1.00     21.5±0.22ms    1.08     23.3±0.18ms
bench_diff_lines/reversed/1k      1.00   364.8±11.96µs    1.22    445.1±8.99µs
bench_diff_lines/unchanged/10k    1.00  1761.3±13.85µs    1.66      2.9±0.07ms
bench_diff_lines/unchanged/1k     1.00    163.6±1.25µs    1.47    240.7±2.72µs
```

```
% hyperfine --sort command --warmup 3 --runs 5 -L bin jj-0,jj-1 \
  'target/release-with-debug/{bin} --ignore-working-copy \
  file annotate lib/src/revset.rs'
Benchmark 1: target/release-with-debug/jj-0 ..
  Time (mean ± σ):      1.144 s ±  0.011 s    [User: 1.088 s, System: 0.053 s]
  Range (min … max):    1.131 s …  1.159 s    5 runs

Benchmark 2: target/release-with-debug/jj-1 ..
  Time (mean ± σ):      1.026 s ±  0.008 s    [User: 0.975 s, System: 0.048 s]
  Range (min … max):    1.015 s …  1.035 s    5 runs
```
2024-11-22 08:20:55 +09:00
Yuya Nishihara
656a614f29 signing: pass &UserSettings in to backends
If we add our own config storage implementation, .get_<type>() functions will
be moved to UserSettings object.
2024-11-22 08:20:45 +09:00
Yuya Nishihara
7a7962bb9f signing: propagate config errors 2024-11-22 08:20:45 +09:00
Yuya Nishihara
5e13a4a719 signing: remove unused SignInitError::Backend variant, simplify error handling
Since signing backends shouldn't do non-trivial work at the initialization
stage, the error type would never be categorized as an internal error.
2024-11-22 08:20:45 +09:00
Yuya Nishihara
7906b3f4a5 annotate: remove unneeded BString<->Vec round-trip
Some checks are pending
binaries / Build binary artifacts (push) Waiting to run
nix / flake check (push) Waiting to run
build / build (, macos-13) (push) Waiting to run
build / build (, macos-14) (push) Waiting to run
build / build (, ubuntu-latest) (push) Waiting to run
build / build (, windows-latest) (push) Waiting to run
build / build (--all-features, ubuntu-latest) (push) Waiting to run
build / Build jj-lib without Git support (push) Waiting to run
build / Check protos (push) Waiting to run
build / Check formatting (push) Waiting to run
build / Check that MkDocs can build the docs (push) Waiting to run
build / Check that MkDocs can build the docs with latest Python and uv (push) Waiting to run
build / cargo-deny (advisories) (push) Waiting to run
build / cargo-deny (bans licenses sources) (push) Waiting to run
build / Clippy check (push) Waiting to run
Codespell / Codespell (push) Waiting to run
website / prerelease-docs-build-deploy (ubuntu-latest) (push) Waiting to run
Scorecards supply-chain security / Scorecards analysis (push) Waiting to run
2024-11-21 10:50:37 +09:00
Yuya Nishihara
59a79fdcc0 conflicts: extract materialize_merge_result_to_bytes() helper
We have many callers of materialize_merge_result() who just want in-memory
buffer.
2024-11-21 10:50:37 +09:00
Yuya Nishihara
4cdead34b4 conflicts: make materialize_merge_result() accept reference type
Because the output of diff.hunks() is a list of [&BStr]s, a Merge object
reconstructed from a diff hunk will be Merge<&BStr>. I'm not pretty sure if
we'll implement conflict diffs in that way, but this change should be harmless
anyway.
2024-11-21 10:50:37 +09:00
Yuya Nishihara
2aa913b035 conflicts: extract inner block of materialize_merge_result()
I'm going to make materialize_merge_result() accept reference type. This patch
extracts large non-generic part to a separate function.
2024-11-21 10:50:37 +09:00
Yuya Nishihara
5cc0bd0950 rewrite: fix duplicated commits to be rebased onto destination
I believe this was an oversight. "jj duplicate" should duplicate commits (=
patches), not trees.

This patch adds a separate test file because test_rewrite.rs is pretty big, and
we'll probably want to migrate CLI tests to jj-lib.
2024-11-21 10:49:51 +09:00
Yuya Nishihara
1973c712a3 log: emit working-copy branch first if included in the revset
Some checks are pending
binaries / Build binary artifacts (push) Waiting to run
nix / flake check (push) Waiting to run
build / build (, macos-13) (push) Waiting to run
build / build (, macos-14) (push) Waiting to run
build / build (, ubuntu-latest) (push) Waiting to run
build / build (, windows-latest) (push) Waiting to run
build / build (--all-features, ubuntu-latest) (push) Waiting to run
build / Build jj-lib without Git support (push) Waiting to run
build / Check protos (push) Waiting to run
build / Check formatting (push) Waiting to run
build / Check that MkDocs can build the docs (push) Waiting to run
build / Check that MkDocs can build the docs with Poetry 1.8 (push) Waiting to run
build / cargo-deny (advisories) (push) Waiting to run
build / cargo-deny (bans licenses sources) (push) Waiting to run
build / Clippy check (push) Waiting to run
Codespell / Codespell (push) Waiting to run
website / prerelease-docs-build-deploy (ubuntu-latest) (push) Waiting to run
Scorecards supply-chain security / Scorecards analysis (push) Waiting to run
The working-copy revision is usually the latest commit, but it's not always
true. This patch ensures that the wc branch is emitted first so the graph node
order is less dependent on rewrites.
2024-11-20 10:50:16 +09:00
Yuya Nishihara
fb79f2024d tests: do Result wrapping/unwrapping by graph helper 2024-11-20 10:50:16 +09:00
Yuya Nishihara
05c7da3db0 diff: reuse precomputed hash values
This isn't always fast because it increases the chance of cache miss, but in
practice, it makes "jj file annotate" faster. It's still slower than
"git blame", though.

Maybe we should also change the hash function.

```
group                             new                     old
-----                             ---                     ---
bench_diff_git_git_read_tree_c    1.00     45.2±0.38µs    1.29     58.4±0.32µs
bench_diff_lines/modified/10k     1.00     32.7±0.24ms    1.05     34.4±0.17ms
bench_diff_lines/modified/1k      1.00      2.9±0.00ms    1.06      3.1±0.01ms
bench_diff_lines/reversed/10k     1.00     22.7±0.18ms    1.02     23.2±0.29ms
bench_diff_lines/reversed/1k      1.00    439.0±9.46µs    1.19    523.9±6.05µs
bench_diff_lines/unchanged/10k    1.00      2.9±0.06ms    1.20      3.5±0.02ms
bench_diff_lines/unchanged/1k     1.00    240.8±1.03µs    1.30    312.1±1.05µs
```

```
% hyperfine --sort command --warmup 3 --runs 10 -L bin jj-0,jj-1 \
  'target/release-with-debug/{bin} --ignore-working-copy file annotate lib/src/revset.rs'
Benchmark 1: target/release-with-debug/jj-0 ..
  Time (mean ± σ):      1.604 s ±  0.259 s    [User: 1.543 s, System: 0.057 s]
  Range (min … max):    1.348 s …  1.917 s    10 runs

Benchmark 2: target/release-with-debug/jj-1 ..
  Time (mean ± σ):      1.183 s ±  0.026 s    [User: 1.118 s, System: 0.062 s]
  Range (min … max):    1.155 s …  1.237 s    10 runs
```
2024-11-20 10:36:08 +09:00
Yuya Nishihara
2c653564fd diff: extract narrowed view type from DiffSource, add type-safe local index
I'm going to add a Vec of precomputed hashes, and the Vec will be owned by
DiffSource.
2024-11-20 10:36:08 +09:00
Yuya Nishihara
ed18b5bdc5 diff: cache hash values by Histogram
Since patience diff is recursive, it makes some sense to reuse precomputed
hash values. This patch migrates Histogram to remembering hashed values. The
precomputed values will be cached globally by DiffSource.

Technically, Histogram doesn't have to keep a separate copy of hash values, but
this appears to give better perf than slicing text and hash value from two Vecs.
2024-11-20 10:36:08 +09:00
Luke Randall
068fa0f37e revset: allow tags() to take a pattern for an argument
This makes it more consistent with `bookmarks()`.

Co-authored-by: Austin Seipp <aseipp@pobox.com>
2024-11-20 00:47:23 +00:00
Ilya Grigoriev
0c6c47101f nightly clippy fixes
Some checks are pending
binaries / Build binary artifacts (push) Waiting to run
nix / flake check (push) Waiting to run
build / build (, macos-13) (push) Waiting to run
build / build (, macos-14) (push) Waiting to run
build / build (, ubuntu-latest) (push) Waiting to run
build / build (, windows-latest) (push) Waiting to run
build / build (--all-features, ubuntu-latest) (push) Waiting to run
build / Build jj-lib without Git support (push) Waiting to run
build / Check protos (push) Waiting to run
build / Check formatting (push) Waiting to run
build / Check that MkDocs can build the docs (push) Waiting to run
build / Check that MkDocs can build the docs with Poetry 1.8 (push) Waiting to run
build / cargo-deny (advisories) (push) Waiting to run
build / cargo-deny (bans licenses sources) (push) Waiting to run
build / Clippy check (push) Waiting to run
Codespell / Codespell (push) Waiting to run
website / prerelease-docs-build-deploy (ubuntu-latest) (push) Waiting to run
Scorecards supply-chain security / Scorecards analysis (push) Waiting to run
2024-11-18 18:49:05 -08:00
Benjamin Tan
4db4f413a7 revset: add fork_point function
This can be used to find the fork point (best common ancestors) of a
revset with an arbitrary number of commits, which cannot be expressed
currently in the revset language.
2024-11-16 04:08:01 +08:00
Benjamin Tan
5138836cdc rewrite: add duplicate_commits{,onto_parents} functions 2024-11-15 19:42:13 +08:00
Benjamin Tan
0a7f6bd8aa rewrite: extract compute_commits_heads function
This will be shared between `move_commits` and the new
`duplicate_commits` function to be added.
2024-11-15 19:42:13 +08:00
dploch
0a5bc2bbed workspace: move recovery commit logic into lib for sharing
This is to facilitate automatic update-stale in extensions and in the CommandHelper layer.
2024-11-14 11:12:02 -05:00
dploch
afe25464fe working_copy: move freshness calculation into lib for sharing
This is to facilitate automatic update-stale in extensions and in the CommandHelper layer.
2024-11-14 11:12:02 -05:00
Yuya Nishihara
bfb7613d5d cargo: bump gix to 0.67.0 (includes minor behavior change)
- gix::object::tree::diff::change::Event::Rewrite is flattened
- diff options are extracted to separate type
  2b81e6c8bd
- signature text now includes a trailing newline
  4a6bbb1b79

The last change means that our SecureSig { sig } returned by GitBackend is now
terminated by '\n'. I think this is harmless since textual signature is usually
ends with '\n'.
2024-11-14 22:38:04 +09:00
Yuya Nishihara
eed32954b2 cargo: import fix_filter from gix::filter::plumbing
I don't think we need to declare these dependencies separately because both
are the optional dependencies enabled by the git feature.

We'll also need the gix's "attributes" feature at some point.
> attributes - Query attributes and excludes. Enables access to pathspecs,
> worktree checkouts, filter-pipelines and submodules.
https://docs.rs/gix/0.67.0/gix/index.html#feature-flags
2024-11-14 22:38:04 +09:00
Yuya Nishihara
168f07283a cargo: whitespace cleanup, sort dependencies 2024-11-14 22:38:04 +09:00
Yuya Nishihara
48521d66b4 stacked_table: add context to error type, propagate lock error 2024-11-14 22:37:54 +09:00
Yuya Nishihara
aaf7f33804 lock: propagate error from lock(), remove panic from unlock path 2024-11-14 22:37:54 +09:00
Yuya Nishihara
6ffd4d4f63 lock: compile and test fallback module on all platforms
This should help detect Windows issues early. Also fixed clippy warning.
2024-11-14 22:37:54 +09:00
Yuya Nishihara
1a2479cd2f lock: reorganize platform-specific implementations as sub modules
This will help rust-analyzer scan both fallback and unix impls.
2024-11-14 22:37:54 +09:00
Martin von Zweigbergk
dfc67e7051 simple_op_heads_store: propagate errors when trying to remove op head
Some checks are pending
binaries / Build binary artifacts (linux-aarch64-gnu, ubuntu-24.04, aarch64-unknown-linux-gnu) (push) Waiting to run
binaries / Build binary artifacts (linux-aarch64-musl, ubuntu-24.04, aarch64-unknown-linux-musl) (push) Waiting to run
binaries / Build binary artifacts (linux-x86_64-gnu, ubuntu-24.04, x86_64-unknown-linux-gnu) (push) Waiting to run
binaries / Build binary artifacts (linux-x86_64-musl, ubuntu-24.04, x86_64-unknown-linux-musl) (push) Waiting to run
binaries / Build binary artifacts (macos-aarch64, macos-14, aarch64-apple-darwin) (push) Waiting to run
binaries / Build binary artifacts (macos-x86_64, macos-13, x86_64-apple-darwin) (push) Waiting to run
binaries / Build binary artifacts (win-x86_64, windows-2022, x86_64-pc-windows-msvc) (push) Waiting to run
nix / flake check (macos-14) (push) Waiting to run
nix / flake check (ubuntu-latest) (push) Waiting to run
build / build (, macos-13) (push) Waiting to run
build / build (, macos-14) (push) Waiting to run
build / build (, ubuntu-latest) (push) Waiting to run
build / build (, windows-latest) (push) Waiting to run
build / build (--all-features, ubuntu-latest) (push) Waiting to run
build / Build jj-lib without Git support (push) Waiting to run
build / Check protos (push) Waiting to run
build / Check formatting (push) Waiting to run
build / Check that MkDocs can build the docs (push) Waiting to run
build / Check that MkDocs can build the docs with Poetry 1.8 (push) Waiting to run
build / cargo-deny (advisories) (push) Waiting to run
build / cargo-deny (bans licenses sources) (push) Waiting to run
build / Clippy check (push) Waiting to run
Codespell / Codespell (push) Waiting to run
website / prerelease-docs-build-deploy (ubuntu-latest) (push) Waiting to run
Scorecards supply-chain security / Scorecards analysis (push) Waiting to run
Any errors other than `NotFound` are unexpected.
2024-11-13 23:05:24 -08:00