treewide: format using nixfmt

Signed-off-by: Bloxx12 <charlie@charlieroot.dev>
Change-Id: I6a6a69641c36f9763e104087a559c148d0449f00
This commit is contained in:
Bloxx12 2025-07-20 01:23:48 +02:00
commit e641dfa114
Signed by: faukah
SSH key fingerprint: SHA256:jpYIt4Vkz1NBTQcks/N9OPTfTFxE6KF2W/rV7hrfrIw
113 changed files with 1545 additions and 1019 deletions

View file

@ -1,6 +1,8 @@
{pkgs, ...}: let
{ pkgs, ... }:
let
inherit (pkgs.lib) getExe;
in {
in
{
ls = "${getExe pkgs.eza} --icons=never";
la = "${getExe pkgs.eza} --icons=never -lha --git";

View file

@ -1,14 +1,15 @@
# This shell setup was originally inspired by sioodmy.
# Some further cool tricks, like using vendor_conf.d to avoid having
# to build fish myself, are taken from viperml's setup.
{pkgs, ...}: let
{ pkgs, ... }:
let
inherit (pkgs) lib;
inherit (lib.strings) concatStringsSep;
inherit (lib.attrsets) mapAttrsToList;
toml = pkgs.formats.toml {};
toml = pkgs.formats.toml { };
starship-config = import ./starship.nix;
aliases = import ./aliases.nix {inherit pkgs;};
aliases = import ./aliases.nix { inherit pkgs; };
vendorConf = "share/fish/vendor_conf.d";
fishinit = import ./fishinit.nix {
@ -19,27 +20,25 @@
;
};
aliasesStr =
mapAttrsToList (k: v: "alias ${k}=\"${v}\"") aliases
|> concatStringsSep "\n";
aliasesStr = mapAttrsToList (k: v: "alias ${k}=\"${v}\"") aliases |> concatStringsSep "\n";
packages = import ./packages.nix pkgs;
in
(pkgs.symlinkJoin {
name = "fish";
paths = [pkgs.fish] ++ packages;
nativeBuildInputs = [pkgs.makeWrapper];
postBuild = ''
wrapProgram $out/bin/fish \
--set STARSHIP_CONFIG "${toml.generate "starship.toml" starship-config}" \
--prefix XDG_DATA_DIRS : "${
lib.makeSearchPathOutput "out" "share" [
fishinit
]
}"
'';
})
.overrideAttrs (_: {
(pkgs.symlinkJoin {
name = "fish";
paths = [ pkgs.fish ] ++ packages;
nativeBuildInputs = [ pkgs.makeWrapper ];
postBuild = ''
wrapProgram $out/bin/fish \
--set STARSHIP_CONFIG "${toml.generate "starship.toml" starship-config}" \
--prefix XDG_DATA_DIRS : "${
lib.makeSearchPathOutput "out" "share" [
fishinit
]
}"
'';
}).overrideAttrs
(_: {
passthru = {
shellPath = "/bin/fish";
};

View file

@ -4,31 +4,31 @@
vendorConf,
}:
pkgs.writeTextDir "${vendorConf}/blox_config.fish"
# fish
''
# source ${pkgs.fishPlugins.sponge}/share/zsh-defer/zsh-defer.plugin.zsh
${pkgs.atuin}/bin/atuin init fish | source
bind up _atuin_bind_up
# fish
''
# source ${pkgs.fishPlugins.sponge}/share/zsh-defer/zsh-defer.plugin.zsh
${pkgs.atuin}/bin/atuin init fish | source
bind up _atuin_bind_up
${pkgs.zoxide}/bin/zoxide init fish | source
# abbr --erase cd &>/dev/null
# alias cd=__zoxide_z
${pkgs.zoxide}/bin/zoxide init fish | source
# abbr --erase cd &>/dev/null
# alias cd=__zoxide_z
# abbr --erase ci &>/dev/null
# alias ci=__zoxide_zi
# abbr --erase ci &>/dev/null
# alias ci=__zoxide_zi
${pkgs.starship}/bin/starship init fish | source
${pkgs.direnv}/bin/direnv hook fish | source
${pkgs.pay-respects}/bin/pay-respects fish --alias f --nocnf | source
${pkgs.starship}/bin/starship init fish | source
${pkgs.direnv}/bin/direnv hook fish | source
${pkgs.pay-respects}/bin/pay-respects fish --alias f --nocnf | source
# I need to source /etc/profile using foreign-env, to get stuff set by nixos, e.g. environment.systemVariables.
# set -p fish_function_path ${pkgs.fishPlugins.foreign-env}/share/fish/vendor_functions.d
# I need to source /etc/profile using foreign-env, to get stuff set by nixos, e.g. environment.systemVariables.
# set -p fish_function_path ${pkgs.fishPlugins.foreign-env}/share/fish/vendor_functions.d
# fenv source /etc/profile
# fenv source /etc/profile
source ${./config.fish}
source ${./config.fish}
${aliasesStr}
''
${aliasesStr}
''

View file

@ -1,7 +1,6 @@
pkgs:
builtins.attrValues {
inherit
(pkgs)
inherit (pkgs)
# better cd
zoxide
# pipe viewer

View file

@ -14,44 +14,110 @@
docker_context.symbol = " ";
elixir.symbol = " ";
elm.symbol = " ";
fennel = {symbol = " ";};
fossil_branch = {symbol = " ";};
gcloud = {symbol = " ";};
git_branch = {symbol = " ";};
git_commit = {tag_symbol = " ";};
fennel = {
symbol = " ";
};
fossil_branch = {
symbol = " ";
};
gcloud = {
symbol = " ";
};
git_branch = {
symbol = " ";
};
git_commit = {
tag_symbol = " ";
};
golang.symbol = " ";
gradle = {symbol = " ";};
guix_shell = {symbol = " ";};
haskell = {symbol = " ";};
haxe = {symbol = " ";};
hg_branch = {symbol = " ";};
hostname = {ssh_symbol = " ";};
java = {symbol = " ";};
julia = {symbol = " ";};
kotlin = {symbol = " ";};
lua = {symbol = " ";};
memory_usage = {symbol = "󰍛 ";};
meson = {symbol = "󰔷 ";};
nim = {symbol = "󰆥 ";};
nix_shell = {symbol = " ";};
nodejs = {symbol = " ";};
ocaml = {symbol = " ";};
gradle = {
symbol = " ";
};
guix_shell = {
symbol = " ";
};
haskell = {
symbol = " ";
};
haxe = {
symbol = " ";
};
hg_branch = {
symbol = " ";
};
hostname = {
ssh_symbol = " ";
};
java = {
symbol = " ";
};
julia = {
symbol = " ";
};
kotlin = {
symbol = " ";
};
lua = {
symbol = " ";
};
memory_usage = {
symbol = "󰍛 ";
};
meson = {
symbol = "󰔷 ";
};
nim = {
symbol = "󰆥 ";
};
nix_shell = {
symbol = " ";
};
nodejs = {
symbol = " ";
};
ocaml = {
symbol = " ";
};
os = {
symbols = {
Linux = " ";
NixOS = " ";
};
};
package = {symbol = "󰏗 ";};
perl = {symbol = " ";};
php = {symbol = " ";};
pijul_channel = {symbol = " ";};
pixi = {symbol = "󰏗 ";};
python = {symbol = " ";};
rlang = {symbol = "󰟔 ";};
ruby = {symbol = " ";};
rust = {symbol = "󱘗 ";};
scala = {symbol = " ";};
swift = {symbol = " ";};
zig = {symbol = " ";};
package = {
symbol = "󰏗 ";
};
perl = {
symbol = " ";
};
php = {
symbol = " ";
};
pijul_channel = {
symbol = " ";
};
pixi = {
symbol = "󰏗 ";
};
python = {
symbol = " ";
};
rlang = {
symbol = "󰟔 ";
};
ruby = {
symbol = " ";
};
rust = {
symbol = "󱘗 ";
};
scala = {
symbol = " ";
};
swift = {
symbol = " ";
};
zig = {
symbol = " ";
};
}