{ pkgs, inputs, config, ... }: let tomlFormat = pkgs.formats.toml {}; in { xdg.configFile."jj/config.toml".source = tomlFormat.generate "config.toml" { user = { name = config.my.git.name; email = config.my.git.email; }; ui = { diff-formatter = ":git"; pager = ":builtin"; }; aliases = { wk = ["log" "-r" "trunk()::@ | @::"]; gp = ["git" "push" "--allow-new"]; gf = ["git" "fetch"]; tracked = ["bookmark" "list" "-t" "-T" ''if(self.tracked(), if(self.name() != "main", self.name()++"\n"))'']; untracked = ["bookmark" "list" "-T" ''if(!self.tracked(), if(self.name() != "main", self.name()++"\n"))'']; e = ["edit"]; track = ["util" "exec" "--" "bash" "-c" "jj bookmark set $(jj log -r @ -T 'self.change_id()' --no-graph)"]; tug = ["bookmark" "move" "--from" "heads(::@- & bookmarks())" "--to" "@-"]; nm = ["new" "-r" "trunk()"]; }; templates = { log = "builtin_log_compact"; }; template-aliases = { "commit_timestamp(commit)" = "commit.author().timestamp()"; }; }; }