modules/shell: init
This commit is contained in:
parent
c315064e26
commit
32403d2a2a
3 changed files with 37 additions and 0 deletions
0
modules/shell/config.fish
Normal file
0
modules/shell/config.fish
Normal file
25
modules/shell/fishinit.nix
Normal file
25
modules/shell/fishinit.nix
Normal file
|
@ -0,0 +1,25 @@
|
|||
{
|
||||
pkgs,
|
||||
aliasesStr,
|
||||
}:
|
||||
pkgs.writeShellScriptBin "config.fish" ''
|
||||
|
||||
# source ${pkgs.fishPlugins.sponge}/share/zsh-defer/zsh-defer.plugin.zsh
|
||||
${pkgs.atuin}/bin/atuin init fish | source
|
||||
${pkgs.zoxide}/bin/zoxide init fish | source
|
||||
|
||||
source ${./starship.fish}
|
||||
source ${./zoxide.fish}
|
||||
|
||||
source ${./config.fish}
|
||||
|
||||
zsh-defer source ${pkgs.zsh-fast-syntax-highlighting}/share/zsh/site-functions/fast-syntax-highlighting.plugin.zsh
|
||||
zsh-defer source ${pkgs.zsh-nix-shell}/share/zsh-nix-shell/nix-shell.plugin.zsh
|
||||
zsh-defer source ${pkgs.zsh-vi-mode}/share/zsh-vi-mode/zsh-vi-mode.plugin.zsh
|
||||
zsh-defer source ${pkgs.zsh-fzf-tab}/share/fzf-tab/fzf-tab.plugin.zsh
|
||||
zsh-defer source ${pkgs.zsh-autosuggestions}/share/zsh-autosuggestions/zsh-autosuggestions.zsh
|
||||
zsh-defer source ${pkgs.zsh-autopair}/share/zsh/zsh-autopair/autopair.zsh
|
||||
|
||||
|
||||
${aliasesStr}
|
||||
''
|
12
modules/shell/module.nix
Normal file
12
modules/shell/module.nix
Normal file
|
@ -0,0 +1,12 @@
|
|||
# This shell setup was inspired by sioodmy. Check out his setup!
|
||||
{pkgs, ...}: let
|
||||
toml = pkgs.formats.toml {};
|
||||
starship-config = import ./starship.nix;
|
||||
in (pkgs.symlinkJoin {
|
||||
name = "fish-wrapped";
|
||||
paths = [pkgs.fish pkgs.starship pkgs.fzf];
|
||||
buildInputs = [pkgs.makeWrapper];
|
||||
postBuild = ''
|
||||
wrapProgram $out/bin/fish --set STARSHIP_CONFIG "${toml.generate "starship.toml" starship-config}" \
|
||||
'';
|
||||
})
|
Loading…
Add table
Add a link
Reference in a new issue