From 394e6fa46d759d530aa71aa526a700a7f0bc032a Mon Sep 17 00:00:00 2001 From: William Date: Sat, 19 Aug 2023 12:08:07 -0300 Subject: [PATCH] Configured helix nix formatter --- flake.nix | 3 +-- hosts/desktops/common/packages.nix | 1 - users/common/programs.nix | 21 +++++++++------------ 3 files changed, 10 insertions(+), 15 deletions(-) diff --git a/flake.nix b/flake.nix index 5306dea..cf76864 100644 --- a/flake.nix +++ b/flake.nix @@ -166,8 +166,7 @@ }; devShells = { - "x86_64-linux".default = nixpkgs.legacyPackages."x86_64-linux".mkShell { - packages = with nixpkgs.legacyPackages."x86_64-linux"; [ nil nixfmt ]; + "x86_64-linux".default = nixpkgs.legacyPackages."x86_64-linux".mkShell { packages = with nixpkgs.legacyPackages."x86_64-linux"; [ nil nixfmt ]; }; "aarch64-linux".default = nixpkgs.legacyPackages."aarch64-linux".mkShell { diff --git a/hosts/desktops/common/packages.nix b/hosts/desktops/common/packages.nix index f93d41d..b20d304 100644 --- a/hosts/desktops/common/packages.nix +++ b/hosts/desktops/common/packages.nix @@ -34,7 +34,6 @@ mangohud mpv nextcloud-client - nixfmt nix-init obs-studio p7zip diff --git a/users/common/programs.nix b/users/common/programs.nix index 572b815..7ebc1c2 100644 --- a/users/common/programs.nix +++ b/users/common/programs.nix @@ -23,6 +23,7 @@ cursor-shape.insert = "bar"; mouse = false; soft-wrap.enable = true; + auto-format = true; }; keys.normal.space = { space = "file_picker"; @@ -31,6 +32,13 @@ esc = [ "collapse_selection" "keep_primary_selection" ]; }; }; + languages = { + language = [{ + name = "nix"; + auto-format = true; + formatter.command = "nixfmt"; + }]; + }; themes.catppuccin-mocha_transparent = { inherits = "catppuccin_mocha"; "ui.background" = "{}"; @@ -150,24 +158,13 @@ }; }; - micro = { - enable = true; - settings = { - clipboard = "terminal"; - mkparents = true; - scrollbar = true; - tabstospaces = true; - tabsize = 2; - colorscheme = "simple"; - }; - }; - fish = { enable = true; interactiveShellInit = "nix-your-shell fish | source"; loginShellInit = "nix-your-shell fish | source"; shellAliases = { wget = ''wget --hsts-file="$XDG_DATA_HOME/wget-hsts"''; + h = "hx"; }; functions = { fish_greeting = "";