8712 Commits

Author SHA1 Message Date
dependabot[bot]
658d26b290 github: bump taiki-e/install-action in the github-dependencies group
Bumps the github-dependencies group with 1 update: [taiki-e/install-action](https://github.com/taiki-e/install-action).


Updates `taiki-e/install-action` from 2.48.1 to 2.48.9
- [Release notes](https://github.com/taiki-e/install-action/releases)
- [Changelog](https://github.com/taiki-e/install-action/blob/main/CHANGELOG.md)
- [Commits](510b3ecd79...995f97569c)

---
updated-dependencies:
- dependency-name: taiki-e/install-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: github-dependencies
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-02-11 20:16:06 +00:00
Martin von Zweigbergk
f291ac44db cli: add difftastic as diff tool
Difftastic is pretty popular tool. Let's add it as a diff tool so it's
easier to enable.
2025-02-11 18:00:01 +00:00
Martin von Zweigbergk
7b1820adba cli: sort tools in merge_tools.toml 2025-02-11 18:00:01 +00:00
Baltasar Dinis
39fe9aad3a cli/tests: remove allow(unused) from git helpers 2025-02-11 13:46:25 +00:00
Baltasar Dinis
5b174c9109 cli/tests: port test_git_import_export to gitoxide 2025-02-11 13:46:25 +00:00
Baltasar Dinis
4f6a2fcfc0 cli/tests: port test_commit_template to gitoxide 2025-02-11 13:46:25 +00:00
Baltasar Dinis
5076d0e6b1 cli/tests: port test_bookmark to gitoxide
cargo-insta was re-run.
This is due to centralizing git interaction code to use a particular
different signature, which changes the commit hashes
2025-02-11 13:46:25 +00:00
Baltasar Dinis
a8eb76f9c4 cli/tests: port test_operations to gitoxide
cargo-insta was re-run.
This is due to centralizing git interaction code to use a particular
different signature, which changes the commit hashes
2025-02-11 13:46:25 +00:00
Baltasar Dinis
d56d910db8 cli/tests: port test_undo to gitoxide 2025-02-11 13:46:25 +00:00
Baltasar Dinis
806e76613b cli/tests: port test_git_submodule to gitoxide 2025-02-11 13:46:25 +00:00
Baltasar Dinis
b80e73b7cf cli/tests: port test_tag_command to gitoxide 2025-02-11 13:46:25 +00:00
Baltasar Dinis
cd6141693b cli/tests: add gitoxide helpers 2025-02-11 13:46:25 +00:00
Baltasar Dinis
769dbd8f5f cli/tests: move test environment to its own file
The `mod.rs` was becoming crowded and this makes way for unrelated
additions to the test utilities module
2025-02-11 13:46:25 +00:00
Austin Seipp
61c3be6057 github: bump ci timeout to 20 minutes
The CI system is variously hitting the limits of the existing 15 minute
build mark; in particular, Windows seems to be consistently hitting ~14m
so the chance of a runner timing out gets high if the underlying load is
also high.

While I'm working on this, let's just (regrettably) increase the slack
on the timeout so that everyone else isn't disturbed.

Signed-off-by: Austin Seipp <aseipp@pobox.com>
2025-02-11 05:50:39 +00:00
Austin Seipp
404778c8ca github: rename 'build' workflow to 'ci'
'ci' is much more high-level and accurately explains what the jobs in
this test should be for. It's much more applicable than 'test' (testing
what? on what platforms?) or 'build' (does it only build? or test? or
run linters?)

Signed-off-by: Austin Seipp <aseipp@pobox.com>
2025-02-11 05:50:39 +00:00
Austin Seipp
8fe23d80ad github: split windows-specific setups into private composite action
Moves all the Windows junk out of the way, where it can be encapsulated.

Signed-off-by: Austin Seipp <aseipp@pobox.com>
2025-02-11 05:50:39 +00:00
Austin Seipp
768ec3b93d github: s/build-binaries/binaries/
Just a rename; now that `build` and `build-nix` are unified, this makes
it more clear this workflow is conceptually separate. NFC.

Signed-off-by: Austin Seipp <aseipp@pobox.com>
2025-02-11 05:50:39 +00:00
Austin Seipp
19bbecbe5e github: inline nix builds into main build workflow
There's no real reason to keep these separate and it makes the build UX
easier to navigate, too; as well as see what the actual "global" slowest
builds across all workflows easier to see.

Signed-off-by: Austin Seipp <aseipp@pobox.com>
2025-02-11 05:50:39 +00:00
Austin Seipp
48d91c33a0 github: reorganize and rename default build workflows
This makes the methods and the madness a little more consistent with
each other, so it's easier to read and categorize build reports in the
GHA UX.

No functional change, but requires updating rulesets upstream.

Signed-off-by: Austin Seipp <aseipp@pobox.com>
2025-02-11 05:50:39 +00:00
Austin Seipp
eea80e4c7a github: build x86_64-macos binaries on macos-14 runners
Signed-off-by: Austin Seipp <aseipp@pobox.com>
2025-02-11 05:50:39 +00:00
Austin Seipp
50160b4853 github: make build workflow more similar to release flow
Signed-off-by: Austin Seipp <aseipp@pobox.com>
2025-02-11 05:50:39 +00:00
Emily
77f54a267e git: enable subprocessing by default
Given the previously‐stated intention of making this default
for the 0.27 release, prepare for that decision ahead of time by
enabling subprocessing by default on trunk. This will help surface
any regressions and workflow incompatibilities and therefore give
us more information to decide whether to keep or revert this commit,
without inconveniencing any users who haven’t already opted in to
the bleeding edge.

Please feel free to revert without hesitation if any major issues
arise; this is not intended as a strong commitment to enable this
option for the next stable release if it turns out to not be ready. In
that case, it’s better that we learn that early on in the cycle,
rather than having to revert at the last minute or, worse, cutting
a stable release that we later find contains a serious regression.
2025-02-10 22:10:22 +00:00
dependabot[bot]
c187142090 github: bump taiki-e/install-action in the github-dependencies group
Bumps the github-dependencies group with 1 update: [taiki-e/install-action](https://github.com/taiki-e/install-action).


Updates `taiki-e/install-action` from 2.48.1 to 2.48.6
- [Release notes](https://github.com/taiki-e/install-action/releases)
- [Changelog](https://github.com/taiki-e/install-action/blob/main/CHANGELOG.md)
- [Commits](510b3ecd79...5bc300ae62)

---
updated-dependencies:
- dependency-name: taiki-e/install-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: github-dependencies
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-02-10 17:40:16 +00:00
Austin Seipp
02500e5248 meta: add initial GOVERNANCE.md
This is the result of a lot of back and forth, the weekly efforts of the
governance working group, consisting of:

- Martin von Zweigbergk (martinvonz)
- Waleed Khan (arxanas)
- Emily Shaffer (nasamuffin)
- Austin Seipp (thoughtpolice; yours truly)

Many thanks as well to emeritus member Khionu Sybiern, who helped kickstart this
whole process.

Signed-off-by: Austin Seipp <aseipp@pobox.com>
2025-02-10 17:39:34 +00:00
Martin von Zweigbergk
d135e04f7d docs: undo another mistaken "branch->bookmark" change 2025-02-10 17:24:32 +00:00
Martin von Zweigbergk
1e25101cea
cli: status: replace "is clean" by "has no changes"
"The working copy has no changes" seems much easier to understand for
new users. Thanks to @Wilfred for the suggestion.
2025-02-10 08:01:50 -08:00
Martin von Zweigbergk
65dc6750e0 docs: move Git command table to a separate page
The table can be easy to miss in its current location.
2025-02-10 15:29:32 +00:00
Martin von Zweigbergk
ac55f52292 docs: swap "git" and "jj" columns in command equivalence table
The table is probably mostly used by users switching from Git, so it
makes sense to have the `git` command on the left side.
2025-02-10 15:29:32 +00:00
Evan Mesterhazy
915fe8f11e cli split: Test how the working copy commit changes across multiple workspaces
When a commit is split, the second commit produced by the split becomes the
working copy commit for all workspaces whose working copy commit was the target
of the split.

This commit adds two tests for this behavior:

1. Split a commit which is the working copy commit for two workspaces.
2. Split a commit which is the working copy commit for only one of the two
   workspaces.

These tests check that the working copy commits for the workspaces are updated
correctly. Both parallel and non-parallel splits are tested.
2025-02-10 14:05:45 +00:00
Jacob Hayes
6aefb58ed8
sign: Support ~/ path expansion for allowed-signers
Fixes #5625
2025-02-10 16:50:39 +07:00
Evan Mesterhazy
aee05b9ea0 repo: Use thiserror #[from] with EditCommitError::RewriteRootCommit
See the discussion in #5623. This prevents future accidents if member variables
are added to RewriteRootCommit which need to be propagated to EditCommitError
during conversion.
2025-02-10 04:23:04 +00:00
Martin von Zweigbergk
ea10adfbd5 cli: delete unused variants of BuiltinToolError
Some variants became unused in bce8cb9.
2025-02-10 02:56:01 +00:00
Evan Mesterhazy
4422e8cea6 cli: Fix single-character string constant used as pattern clippy warning
For further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_char_pattern

Apparently this got moved to "pedantic" in 1.80, but I ran clippy 1.79 and saw
it. Seems harmless to fix though.

#cleanup
2025-02-09 13:23:41 -05:00
Martin von Zweigbergk
0cc1a17e78 faq: fix quoting of git.private-commits example
The example became incorrect when `jj config set` stopped promoting
values with apostrophes to strings in 3f115cb. Use a TOML literal
string to fix it.
2025-02-09 17:51:14 +00:00
Benjamin Tan
07c63ed182 cli: remove ui.allow-filesets configuration option
The "fileset" language has been enabled by default since v0.20.
2025-02-08 19:34:05 +00:00
Martin von Zweigbergk
9cab4d9a0b cli: describe how to set a config value with apostrophes
Apostrophes are not uncommon in e.g. `user.name`, so let's help the
user by providing examples.
2025-02-08 18:46:37 +00:00
Evan Mesterhazy
6d6f2c6dec repo: Change name for unused closure argument
The previous name violated the "snake case" convention for variable names. I
suspect the intention was to use `RewriteRootCommit` as a type declaration, not
the argument name. Since the argument isn't used, we can use an underscore as
the name and leave the type declaration.

#cleanup
2025-02-08 15:25:44 +00:00
Ilya Grigoriev
cc5b34809c docs: label prerelease docs with different title and header color
This makes the pre-release header bar into a steely blue-grey color and
changes its label, while the header for the stable docs (and past
release docs) remains indigo (blue). The goal is to make it easier to
tell prerelease docs and regular docs apart with a glance. I also
considered using a favicon with a different background, but perhaps
that's not as useful as changing the header color.

See https://github.com/jj-vcs/jj/pull/5614 for screenshots and
https://squidfunk.github.io/mkdocs-material/setup/changing-the-colors/#primary-color
for some more possibilities. "Deep purple" or "brown" are the closest
runners up to "blue grey" in my mind.

This can be tested with

```
MKDOCS_PRIMARY_COLOR="blue grey" MKDOCS_SITE_NAME="Jujutsu docs (prerelease)" uv run mkdocs serve
```

-----------

We could also want to make the historical versions more easily
distinguishable from the `latest` docs, but that would be more
difficult. We'd either need to rely on javascript or to rebuild the
*previous* version of the docs in addition to the new one on every
release.

See [mkdocs-material banner docs] for a javascript apporach (which would
still need some care in implementing, since we probably want the
prerelease version to either not have a banner or to have a different
banner).

[mkdocs-material banner docs]:
  https://squidfunk.github.io/mkdocs-material/setup/setting-up-versioning/?h=version#version-warning
2025-02-07 20:44:59 +00:00
Ilya Grigoriev
f543d24244 mkdocs: get rid of SITE_URL_FOR_MKDOCS
The bug that made it somewhat useful is hopefully fixed now. I
documented the issue in case it reappears.
2025-02-07 20:44:59 +00:00
Ilya Grigoriev
1d95bd6b55 docs and readme: add the new jj logo
It's half-sized (432x432 instead of 864x864) for size and
compressed with `pngquant` (difference not visible with
my eyes).
2025-02-07 20:40:23 +00:00
Ilya Grigoriev
2da0b73c22 favicon: make corners round, make birds a little larger
Also compressed with `pngquant` (I cannot notice the difference
before and after)

Followup to b3099b7
2025-02-07 20:40:12 +00:00
dependabot[bot]
b8598228a3 cargo: bump once_cell in the cargo-dependencies group
Bumps the cargo-dependencies group with 1 update: [once_cell](https://github.com/matklad/once_cell).


Updates `once_cell` from 1.20.2 to 1.20.3
- [Changelog](https://github.com/matklad/once_cell/blob/master/CHANGELOG.md)
- [Commits](https://github.com/matklad/once_cell/compare/v1.20.2...v1.20.3)

---
updated-dependencies:
- dependency-name: once_cell
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: cargo-dependencies
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-02-07 18:40:23 +00:00
dependabot[bot]
a17f28d10b
github: bump github/codeql-action in the github-dependencies group
Bumps the github-dependencies group with 1 update: [github/codeql-action](https://github.com/github/codeql-action).


Updates `github/codeql-action` from 3.28.8 to 3.28.9
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](dd746615b3...9e8d0789d4)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: github-dependencies
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-02-07 15:50:08 +00:00
avmikhailov
a16555f9af index: Return Result from heads
there are many ways to implement `heads` for your custom backend:
one involves calling `self.evaluate_revset` with a proper revset. 
However, it can return an error, but `heads` does not allow it.

In our implementation of the index backend we do exactly the above 
and we ended up with several unwraps which we are trying to avoid 
as it could potentially crash our prod jobs.

P.S. The same logic applies to many methods in this trait, but I am doing one at a time.
2025-02-07 13:45:47 +01:00
Jonathan Frere
42161257ca cli: op undo: show a warning when undoing an undo operation
One common issue that users run into with `jj undo` is that they expect
it to behave like an "undo stack", in which every consecutive `jj undo`
execution moves the current state further back in history. This is
(currently) an incorrect intuition - running multiple `jj undo` commands
back-to-back will only result in the previous non-undo change being
reverted, then un-reverted, then reverted, and so on.

This change adds a hint when the user runs `jj undo` multiple times
consecutively, suggesting that they may be looking for `jj op restore`,
which allows them to revert the whole state of the repository back to
a previous snapshot.
2025-02-07 08:27:16 +01:00
Ilya Grigoriev
6c2ad68330 SECURITY.md: insert an explicit URL
The previous "on this page" statement is wrong more often than not.
Unfortunately there is no "Report a vulnerability" button on
https://github.com/jj-vcs/jj/security/policy, and looking for such a
button from https://github.com/jj-vcs/jj?tab=security-ov-file leads to
confusion.

This is not the end of the world, but I don't see much security downside
to clarifying it (that is, I don't think *not* having a link protects
against phishing in any real way).
2025-02-07 05:09:28 +00:00
Ilya Grigoriev
4ba316d9f7 cli reference: fix jj git push link formatting
Currently, the rendering in
https://jj-vcs.github.io/jj/prerelease/cli-reference/#jj-git-push is
incorrect.

Fixup to 5b5a9e7
2025-02-06 17:35:20 -08:00
Baltasar Dinis
0c446c9069 git: skip running pre-push hooks when subprocessing to match git2 behaviour 2025-02-06 22:43:06 +00:00
Josh Steadmon
975e1e1e24 templater: add optional ellipsis arg to truncate template functions
If an ellipsis arg is given to the truncate_* template functions, append (or
prepend) the ellipsis when the template content is truncated to fit the maximum
width.

Fixes #5085.
2025-02-06 11:34:33 -08:00
Austin Seipp
8144ffcaf8 github: migrate to GHA aarch64 runners
We no longer need to do cross compilation, and these instances seem
pretty fast. Enable them everywhere across the board.

Signed-off-by: Austin Seipp <aseipp@pobox.com>
2025-02-06 08:30:20 -06:00