mirror of
https://github.com/nmasur/dotfiles
synced 2025-07-29 10:40:13 +00:00
41 lines
793 B
Nix
41 lines
793 B
Nix
{
|
|
config,
|
|
pkgs,
|
|
lib,
|
|
...
|
|
}:
|
|
|
|
let
|
|
cfg = config.nmasur.presets.programs.jujutsu;
|
|
in
|
|
|
|
{
|
|
|
|
options.nmasur.presets.programs.jujutsu.enable = lib.mkEnableOption "Jujutsu version control";
|
|
|
|
config = lib.mkIf cfg.enable {
|
|
programs.jujutsu = {
|
|
enable = true;
|
|
|
|
# https://github.com/martinvonz/jj/blob/main/docs/config.md
|
|
settings = {
|
|
user = {
|
|
name = config.programs.git.userName;
|
|
email = config.programs.git.userEmail;
|
|
};
|
|
ui.paginate = "never";
|
|
|
|
# Automatically snapshot when files change
|
|
fsmonitor.backend = "watchman";
|
|
fsmonitor.watchman.register-snapshot-trigger = true;
|
|
};
|
|
};
|
|
|
|
home.packages = [
|
|
# Required for the fsmonitor to auto-snapshot
|
|
pkgs.watchman
|
|
];
|
|
|
|
};
|
|
}
|