shell ++ git extra commands

This commit is contained in:
Lennart J. Kurzweg (Nx2)
2024-05-02 14:45:19 +02:00
parent 8e7b9456f5
commit c202666c0d
3 changed files with 12 additions and 7 deletions

View File

@@ -1,10 +1,11 @@
{ config, pkgs, lib, system, user, allowed, secrets, ... }:
{
home.packages = [
pkgs.fish
home.packages = with pkgs; [
fish
any-nix-shell
(pkgs.writeShellScriptBin "nxfetch" ''
(writeShellScriptBin "nxfetch" ''
logo=$(echo -e "
OS
@@ -65,6 +66,8 @@
glg = "git log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(auto)%d%C(reset)' --all";
gll = "git log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(auto)%d%C(reset)%n'' %C(white)%s%C(reset) %C(dim white)- %an%C(reset)'";
gmt = "git_monitor";
gsw = "git switch";
gft = "git fetch";
ns = "nix-shell";
code = "codium";
@@ -73,8 +76,11 @@
};
interactiveShellInit = ''
set -g fish_greeting
if not set -q IN_NIX_SHELL
nxfetch
end
${pkgs.starship}/bin/starship init fish | source
# ${pkgs.any-nix-shell}/bin/any-nix-shell fish --info-right | source
'';
};
}

View File

@@ -119,7 +119,7 @@
memory_usage.format = "[\\[$symbol[$ram( | $swap)\\]]($style)";
meson.format = "[\\[$symbol$project\\]]($style)";
nim.format = "[\\[$symbol($version)\\]]($style)";
nix_shell.format = "[\\[$symbol$state( \\($name\\))\\]]($style)";
nix_shell.format = "[\\[󱄅 $state \\($name\\)\\]]($style)";
nodejs.format = "[\\[$symbol($version)\\]]($style)";
ocaml.format = "[\\[$symbol($version)(\\($switch_indicator$switch_name\\))\\]]($style)";
openstack.format = "[\\[$symbol$cloud(\\($project\\))\\]]($style)";

View File

@@ -72,7 +72,6 @@
element sssnake pipes
dig
nodejs
gnumake
cmake