From 58837c4f509aa68866aa82c46674c374a76a2408 Mon Sep 17 00:00:00 2001 From: Daniel Lundin Date: Sun, 12 May 2024 11:24:22 +0200 Subject: [PATCH] jj: set immutable heads --- .jjconfig.toml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.jjconfig.toml b/.jjconfig.toml index a7f9752..befcefa 100644 --- a/.jjconfig.toml +++ b/.jjconfig.toml @@ -13,3 +13,9 @@ la = ["log", "--ignore-working-copy", "-r", "all()"] b = ["branch", "list"] n = ["new", "main"] d = ["diff"] + +[revset-aliases] +# The `main.. &` bit is an optimization to scan for non-`mine()` commits only +# among commits that are not in `main`. +"immutable_heads()" = "main@origin | (main@origin.. & ~mine())" +