From 39b11d2092cd0c5e8cd4db4195b62d477fa1172e Mon Sep 17 00:00:00 2001 From: jolheiser Date: Thu, 13 Jul 2023 15:35:19 -0500 Subject: [PATCH] chore: firefox bookmark dir, better exa override, and git insteadOf Signed-off-by: jolheiser --- apps/exa.nix | 4 ++-- apps/firefox.nix | 27 ++++++++++++++++----------- apps/git.nix | 13 +++++++++++++ apps/nushell.nix | 2 +- 4 files changed, 32 insertions(+), 14 deletions(-) diff --git a/apps/exa.nix b/apps/exa.nix index d2e3c54..9e13318 100644 --- a/apps/exa.nix +++ b/apps/exa.nix @@ -1,4 +1,4 @@ -{ +{lib, ...}: { programs.exa = { enable = true; # These don't affect nushell currently @@ -8,7 +8,7 @@ programs.nushell.shellAliases = { exa = "exa --git --icons"; ls = "exa"; - ll = "exa -l"; + ll = lib.mkForce "exa -l"; la = "exa -a"; lt = "exa --tree"; lla = "exa -la"; diff --git a/apps/firefox.nix b/apps/firefox.nix index c8c6543..0ce6189 100644 --- a/apps/firefox.nix +++ b/apps/firefox.nix @@ -26,20 +26,25 @@ }; bookmarks = [ { - name = "Gitea"; + name = "Toolbar"; toolbar = true; bookmarks = [ { - name = "gitea"; - tags = ["gitea"]; - keyword = "gitea"; - url = "https://github.com/go-gitea/gitea"; - } - { - name = "jojodev"; - tags = ["gitea"]; - keyword = "jojodev"; - url = "https://git.jojodev.com"; + name = "Gitea"; + bookmarks = [ + { + name = "gitea"; + tags = ["gitea"]; + keyword = "gitea"; + url = "https://github.com/go-gitea/gitea"; + } + { + name = "jojodev"; + tags = ["gitea"]; + keyword = "jojodev"; + url = "https://git.jojodev.com"; + } + ]; } ]; } diff --git a/apps/git.nix b/apps/git.nix index 9b221ed..76a6f3c 100644 --- a/apps/git.nix +++ b/apps/git.nix @@ -1,5 +1,9 @@ {config, ...}: let key = "0xB853ADA5DA7BBF7A"; + insteadOf = prefix: domain: { + "https://${domain}/".insteadOf = "${prefix}:"; + "git@${domain}:".insteadOf = "ssh:${prefix}:"; + }; in { programs.git = { enable = true; @@ -19,6 +23,7 @@ in { cb = "checkout -b"; fu = "fetch upstream"; fo = "fetch origin"; + dh = "diff HEAD"; }; lfs.enable = true; ignores = [".idea/"]; @@ -27,6 +32,14 @@ in { merge.conflictstyle = "diff3"; diff.colorMoved = "default"; core.editor = "hx"; + push = { + default = "current"; + gpgSign = "if-asked"; + }; + url = + insteadOf "gh" "github.com" + // insteadOf "jojo" "git.jojodev.com" + // insteadOf "tea" "gitea.com"; }; delta = { enable = true; diff --git a/apps/nushell.nix b/apps/nushell.nix index 66a2b7d..99c5f26 100644 --- a/apps/nushell.nix +++ b/apps/nushell.nix @@ -8,7 +8,7 @@ find = "fd"; df = "duf"; du = "dust -b -d 1"; - # ll = "ls -al"; # Handled by exa + ll = "ls -al"; }; extraConfig = '' use ${pkgs.nu_scripts}/share/nu_scripts/custom-completions/bitwarden-cli/bitwarden-cli-completions.nu *