renamed zsh and format

This commit is contained in:
2026-07-04 18:25:18 +01:00
parent 5d7739d0f6
commit 7e753132ea

View File

@@ -10,7 +10,7 @@
}: { }: {
nixpkgs.overlays = [ nixpkgs.overlays = [
(final: prev: { (final: prev: {
zsh = self.packages.${pkgs.stdenv.hostPlatform.system}.myZsh; zsh = self.packages.${pkgs.stdenv.hostPlatform.system}.zsh;
}) })
]; ];
programs.zsh = { programs.zsh = {
@@ -30,11 +30,11 @@
... ...
}: { }: {
packages = { packages = {
myZsh = inputs.wrappers.wrappers.zsh.wrap { zsh = inputs.wrappers.wrappers.zsh.wrap {
inherit pkgs; inherit pkgs;
runtimePkgs = [pkgs.carapace]; runtimePkgs = [pkgs.carapace];
zshAliases = { zshAliases = {
ls = lib.getExe pkgs.lsd; ls = "${lib.getExe pkgs.lsd} -l";
cat = lib.getExe pkgs.bat; cat = lib.getExe pkgs.bat;
lg = lib.getExe pkgs.lazygit; lg = lib.getExe pkgs.lazygit;
devenv = lib.getExe pkgs.devenv; devenv = lib.getExe pkgs.devenv;
@@ -43,20 +43,20 @@
nsh = "nix-shell -p"; nsh = "nix-shell -p";
}; };
zshrc.content = '' zshrc.content = ''
autoload -U compinit && compinit autoload -U compinit && compinit
export CARAPACE_BRIDGES='zsh,fish,bash,inshellisense' # optional export CARAPACE_BRIDGES='zsh,fish,bash,inshellisense' # optional
zstyle ':completion:*' format $'\e[2;37mCompleting %d\e[m' zstyle ':completion:*' format $'\e[2;37mCompleting %d\e[m'
source <(${lib.getExe pkgs.carapace} _carapace) source <(${lib.getExe pkgs.carapace} _carapace)
zstyle ':completion:*' matcher-list 'm:{[:lower:]}={[:upper:]}' 'r:|[._-]=* r:|=*' 'l:|=* r:|=*' zstyle ':completion:*' matcher-list 'm:{[:lower:]}={[:upper:]}' 'r:|[._-]=* r:|=*' 'l:|=* r:|=*'
setopt NO_CASE_GLOB setopt NO_CASE_GLOB
export EDITOR=nvim export EDITOR=nvim
eval "$(${lib.getExe pkgs.devenv} hook zsh)" eval "$(${lib.getExe pkgs.devenv} hook zsh)"
eval "$(${lib.getExe self.packages.${pkgs.host.stdenv.hostPlatform.system}.ohMyPosh} init zsh)" eval "$(${lib.getExe self.packages.${pkgs.host.stdenv.hostPlatform.system}.ohMyPosh} init zsh)"
${lib.getExe pkgs.any-nix-shell} zsh --info-right | source /dev/stdin ${lib.getExe pkgs.any-nix-shell} zsh --info-right | source /dev/stdin
''; '';
}; };
ohMyPosh = inputs.wrappers.wrappers.oh-my-posh.wrap { ohMyPosh = inputs.wrappers.wrappers.oh-my-posh.wrap {