From a4c6d821c91181c142493de63c48d4d7b6ba112e Mon Sep 17 00:00:00 2001 From: albert Date: Sat, 8 Jun 2024 16:48:59 +0900 Subject: [PATCH] Fixes for 24.05 --- flake.nix | 4 +- home-manager/common/software/cli/nixvim.nix | 2 +- .../common/software/cli/nixvim/base.nix | 2 +- .../common/software/cli/nixvim/cmp.nix | 82 +++++++++---------- nixos/common/packages/default.nix | 1 - nixos/common/services/openssh.nix | 2 +- nixos/hosts/nixos-framework/default.nix | 2 +- 7 files changed, 46 insertions(+), 49 deletions(-) diff --git a/flake.nix b/flake.nix index e098e7f4..dc9f45bb 100644 --- a/flake.nix +++ b/flake.nix @@ -64,7 +64,7 @@ framework-server = libx.mkHost { hostname = "framework-server"; }; nuc-server = libx.mkHost { hostname = "nuc-server"; }; nixos-desktop = libx.mkHost { hostname = "nixos-desktop"; unfree = true; desktop = "hyprland"; theme = "green"; }; - nixos-framework = libx.mkHost { hostname = "nixos-framework"; unfree = true; desktop = "plasma6"; theme = "stylix-day"; }; + nixos-framework = libx.mkHost { hostname = "nixos-framework"; unfree = true; desktop = "plasma6"; theme = "tokyo-day"; }; backups-rpi4 = libx.mkHost { hostname = "backups-rpi4"; system = "aarch64-linux"; type = "small"; }; piaware-rpi4 = libx.mkHost { hostname = "piaware-rpi4"; system = "aarch64-linux"; type = "small"; }; quitman-rpi4 = libx.mkHost { hostname = "quitman-rpi4"; system = "aarch64-linux"; type = "small"; }; @@ -77,7 +77,7 @@ "albert@framework-server" = libx.mkHome { hostname = "framework-server"; }; "albert@nuc-server" = libx.mkHome { hostname = "nuc-server"; }; "albert@nixos-desktop" = libx.mkHome { hostname = "nixos-desktop"; desktop = "hyprland"; theme = "green"; }; - "albert@nixos-framework" = libx.mkHome { hostname = "nixos-framework"; desktop = "plasma6"; theme = "stylix-day";}; + "albert@nixos-framework" = libx.mkHome { hostname = "nixos-framework"; desktop = "plasma6"; theme = "tokyo-day";}; "albert@backups-rpi4" = libx.mkHome { hostname = "backups-rpi4"; system = "aarch64-linux"; type = "small"; }; "albert@piaware-rpi4" = libx.mkHome { hostname = "piaware-rpi4"; system = "aarch64-linux"; type = "small"; }; "albert@quitman-rpi4" = libx.mkHome { hostname = "quitman-rpi4"; system = "aarch64-linux"; type = "small"; }; diff --git a/home-manager/common/software/cli/nixvim.nix b/home-manager/common/software/cli/nixvim.nix index 85dc9c98..486b38d1 100644 --- a/home-manager/common/software/cli/nixvim.nix +++ b/home-manager/common/software/cli/nixvim.nix @@ -66,7 +66,7 @@ }; }; rnix-lsp.enable = lib.mkForce false; - nil_ls.enable = false; + nil-ls.enable = false; html.enable = true; cssls.enable = true; bashls.enable = true; diff --git a/home-manager/common/software/cli/nixvim/base.nix b/home-manager/common/software/cli/nixvim/base.nix index e4ac8eac..69a4f132 100644 --- a/home-manager/common/software/cli/nixvim/base.nix +++ b/home-manager/common/software/cli/nixvim/base.nix @@ -18,7 +18,7 @@ globals.mapleader = " "; globals.maplocalleader = " "; - options = { + opts = { number = true; wrap = false; cursorline = true; diff --git a/home-manager/common/software/cli/nixvim/cmp.nix b/home-manager/common/software/cli/nixvim/cmp.nix index fd9f9f47..af3a4e33 100644 --- a/home-manager/common/software/cli/nixvim/cmp.nix +++ b/home-manager/common/software/cli/nixvim/cmp.nix @@ -10,50 +10,48 @@ cmp-nvim-lsp-document-symbol.enable = true; cmp-nvim-lsp-signature-help.enable = true; - cmp.settings = { - sources = [ - { name = "nvim_lua"; } - { name = "nvim_lsp"; } - { name = "calc"; } - { name = "path"; } - { name = "buffer"; } - { name = "luasnip"; } - ]; - snippet.expand = "luasnip"; - - }; - - nvim-cmp = { + cmp = { enable = true; autoEnableSources = true; - mapping = { - "" = "cmp.mapping.complete()"; - "" = "cmp.mapping.scroll_docs(-4)"; - "" = "cmp.mapping.close()"; - "" = "cmp.mapping.scroll_docs(4)"; - "" = "cmp.mapping.confirm({ select = true })"; - "" = "cmp.mapping.select_prev_item()"; - "" = "cmp.mapping.select_next_item()"; - }; - window = { - completion.border = "rounded"; - documentation.border = "rounded"; - }; - formatting = { - fields = [ "menu" "abbr" "kind" ]; - # https://rsdlt.github.io/posts/rust-nvim-ide-guide-walkthrough-development-debug/ - format = '' - function(entry, item) - local menu_icon = { - nvim_lsp = 'λ', - luasnip = '⋗', - buffer = 'Ω', - path = '🖫', - } - item.menu = menu_icon[entry.source.name] - return item - end, - ''; + settings = { + mapping = { + "" = "cmp.mapping.complete()"; + "" = "cmp.mapping.scroll_docs(-4)"; + "" = "cmp.mapping.close()"; + "" = "cmp.mapping.scroll_docs(4)"; + "" = "cmp.mapping.confirm({ select = true })"; + "" = "cmp.mapping.select_prev_item()"; + "" = "cmp.mapping.select_next_item()"; + }; + window = { + completion.border = "rounded"; + documentation.border = "rounded"; + }; + sources = [ + { name = "nvim_lua"; } + { name = "nvim_lsp"; } + { name = "calc"; } + { name = "path"; } + { name = "buffer"; } + { name = "luasnip"; } + ]; + snippet.expand = "luasnip"; + formatting = { + fields = [ "menu" "abbr" "kind" ]; + # https://rsdlt.github.io/posts/rust-nvim-ide-guide-walkthrough-development-debug/ + format = '' + function(entry, item) + local menu_icon = { + nvim_lsp = 'λ', + luasnip = '⋗', + buffer = 'Ω', + path = '🖫', + } + item.menu = menu_icon[entry.source.name] + return item + end, + ''; + }; }; }; }; diff --git a/nixos/common/packages/default.nix b/nixos/common/packages/default.nix index 9ebd4d26..82fcbb5f 100644 --- a/nixos/common/packages/default.nix +++ b/nixos/common/packages/default.nix @@ -4,7 +4,6 @@ # List packages installed in system profile environment.systemPackages = with pkgs; [ nfs-utils # nfs network share tools - nixfmt # Formatting nix output sbctl # Secureboot Control wget # WebGet killall # Killall diff --git a/nixos/common/services/openssh.nix b/nixos/common/services/openssh.nix index f446ded4..5a879879 100644 --- a/nixos/common/services/openssh.nix +++ b/nixos/common/services/openssh.nix @@ -1,7 +1,7 @@ { hostname, ... }: { # enable passwordless elevation # Useful for deploy-rs - security.pam.enableSSHAgentAuth = true; + security.pam.sshAgentAuth.enable = true; programs.ssh.startAgent = true; # By default no ports are open. diff --git a/nixos/hosts/nixos-framework/default.nix b/nixos/hosts/nixos-framework/default.nix index b1b807ef..e61b2567 100644 --- a/nixos/hosts/nixos-framework/default.nix +++ b/nixos/hosts/nixos-framework/default.nix @@ -76,7 +76,7 @@ wineWowPackages.stable winetricks wineWowPackages.waylandFull - nvtop-amd + nvtopPackages.amd distrobox # RGB stuff openrgb-with-all-plugins