diff --git a/modules/home/default.nix b/modules/home/default.nix index 61259dc7c98b1faf4950be94f82fd5776f4de9a6..fc538513d7e2b2bfb7916c71e2a97e1aa8bcc633 100644 --- a/modules/home/default.nix +++ b/modules/home/default.nix @@ -140,12 +140,11 @@ in jujutsu = { settings = { user = { - name = config.programs.git.settings.user.name; - email = config.programs.git.settings.user.email; + inherit (config.programs.git.settings.user) name email; }; - signing = lib.mkIf (config.programs.git.signing.key != null) { - inherit (config.programs.git.signing) key; - backend = "gpg"; + signing = lib.mkIf (config.programs.git.signing.format != null) { + backend = config.programs.git.signing.format; + key = "~/.ssh/id_ed25519.pub"; # signatures are slow, compute them on push instead of on change. behavior = "drop"; }; diff --git a/users/clover/home.nix b/users/clover/home.nix index f48f27fa9434e915d801a530c837dd988107dd7c..7e413bb4c3b2119ee41154823fb239c50d796f50 100644 --- a/users/clover/home.nix +++ b/users/clover/home.nix @@ -21,18 +21,15 @@ in nh autofmt gnupg + nodejs_24 ]; # packages to install for desktop environments (non-server) desktop = [ - lazygit - jjui ]; # packages to install on all servers server = [ ]; # packages to install on macOS desktops - darwin = [ - raycast - ]; + darwin = [ ]; # packages to install on linux desktops linux = [ ]; @@ -109,46 +106,21 @@ in command jj "$@" fi } - - function push() { - command jj git push "$@" --dry-run - printf "Press any key to continue... " - read -r - if bash -c 'cd $(jj workspace root); bun local-ci'; then - command jj git push "$@" - fi - } - - function pr() { - message=$(jj log -r '@' -T 'description' --no-graph) - if [[ -z "$message" ]] || [[ "$message" = "WIP:"* ]]; then - jj desc - message=$(jj log -r '@' -T 'description' --no-graph) - if [[ -z "$message" ]] || [[ "$message" = "WIP:"* ]]; then - exit - fi - fi - if [ -n "$1" ]; then - if [[ "clo"/* = "$1" ]]; then - branch="$1"; - else - branch="clo/$1" - fi - command jj git push --named "$branch"=@ - else - command jj git push -c @ - branch="$(jj log -r '@-' -T 'bookmarks.join("\n")' --no-graph | head -1)" - fi - open "$(git remote get-url origin | sed 's/git@github\.com:/https:\/\/github.com\//' | sed 's/\.git$//')/compare/master...$branch?quick_pull=1&labels=awaiting+code+review,awaiting+functionality+review&body=" - } ''; }; - # use a git-specific email git = { + # use a git-specific email settings.user.email = "git@paperclover.net"; - settings.gpg.format = "ssh"; - signing.signByDefault = true; + settings.gpg.ssh.allowedSignersFile = "${pkgs.writeText "allowed_signers" '' + git@paperclover.net ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIAVa1aq1LEj/VXHJYlR5HJpK65lS/9jOL/dAB9ZS1chd + ''}"; + # signing + signing = { + signByDefault = true; + key = "~/.ssh/id_ed25519"; + format = "ssh"; + }; }; jujutsu = { @@ -221,6 +193,15 @@ in revsets = { short-prefixes = "(trunk()..@)::"; }; + aliases = { + "ab" = [ "abandon" ]; + # "ai" = [ + # "util" + # "exec" + # "--" + # "~/jj-ai-sync.sh" + # ]; + }; }; }; @@ -228,15 +209,21 @@ in enable = true; enableDefaultConfig = false; extraConfig = '' + Include ~/.orbstack/ssh/config* + SetEnv TERM=xterm-256color ''; matchBlocks = rec { "*" = { }; zenith = { user = "clo"; - port = 222; + port = 22; + }; + "git.paperclover.net" = zenith; + "paperclover.net" = { + user = "clo"; + port = 22; }; - "nas.paperclover.net" = zenith; }; }; }; diff --git a/users/clover/paperback/home.nix b/users/clover/paperback/home.nix index 47d88a2034872f1efc7c06355eef2e3b004436b3..6686bc71ada574880cc557bb0207d2d8cef33c11 100644 --- a/users/clover/paperback/home.nix +++ b/users/clover/paperback/home.nix @@ -12,7 +12,6 @@ }; home.packages = with pkgs; [ deno - nodejs_22 rustup typescript pm2 diff --git a/users/clover/work/home.nix b/users/clover/work/home.nix index 63ec7800722bf7336ced60fcb9f0b40fd150051f..a6687ddcafbae66923c46d6cd449de1514f6eccc 100644 --- a/users/clover/work/home.nix +++ b/users/clover/work/home.nix @@ -19,7 +19,6 @@ })) doppler deno - nodejs_24 rustup typescript ssm-session-manager-plugin