From f383aeda99e61daa8be28f81d7c5aa2e889809a8 Mon Sep 17 00:00:00 2001 From: Xory Date: Tue, 23 Sep 2025 17:24:49 +0300 Subject: [PATCH] lots of small changes after using nixos for ~1 month --- hardware-configuration.nix | 37 ---------------------------- hosts/voidspear/config/nvim/init.lua | 17 +++---------- hosts/voidspear/configuration.nix | 31 +++++++++++++++++++++-- hosts/voidspear/home.nix | 17 +++++++++++++ 4 files changed, 50 insertions(+), 52 deletions(-) delete mode 100644 hardware-configuration.nix diff --git a/hardware-configuration.nix b/hardware-configuration.nix deleted file mode 100644 index dad7edc..0000000 --- a/hardware-configuration.nix +++ /dev/null @@ -1,37 +0,0 @@ -# Do not modify this file! It was generated by ‘nixos-generate-config’ -# and may be overwritten by future invocations. Please make changes -# to /etc/nixos/configuration.nix instead. -{ config, lib, pkgs, modulesPath, ... }: - -{ - imports = - [ (modulesPath + "/profiles/qemu-guest.nix") - ]; - - boot.initrd.availableKernelModules = [ "ahci" "xhci_pci" "virtio_pci" "sr_mod" "virtio_blk" ]; - boot.initrd.kernelModules = [ ]; - boot.kernelModules = [ "kvm-amd" ]; - boot.extraModulePackages = [ ]; - - fileSystems."/" = - { device = "/dev/disk/by-uuid/ae26f9c8-bbc0-49e6-b792-20f10277367c"; - fsType = "ext4"; - }; - - fileSystems."/boot" = - { device = "/dev/disk/by-uuid/0160-925B"; - fsType = "vfat"; - options = [ "fmask=0077" "dmask=0077" ]; - }; - - swapDevices = [ ]; - - # Enables DHCP on each ethernet and wireless interface. In case of scripted networking - # (the default) this is the recommended approach. When using systemd-networkd it's - # still possible to use this option, but it's recommended to use it in conjunction - # with explicit per-interface declarations with `networking.interfaces..useDHCP`. - networking.useDHCP = lib.mkDefault true; - # networking.interfaces.enp1s0.useDHCP = lib.mkDefault true; - - nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; -} diff --git a/hosts/voidspear/config/nvim/init.lua b/hosts/voidspear/config/nvim/init.lua index e1c8e95..363d6ad 100644 --- a/hosts/voidspear/config/nvim/init.lua +++ b/hosts/voidspear/config/nvim/init.lua @@ -17,11 +17,7 @@ vim.opt.rtp:prepend(lazypath) require("lazy").setup({ { "catppuccin/nvim", name = "catppuccin" }, - { "williamboman/mason.nvim", opts = {} }, - { "williamboman/mason-lspconfig.nvim", opts = {} }, "neovim/nvim-lspconfig", - "mfussenegger/nvim-dap", - { "jay-babu/mason-nvim-dap.nvim", opts = {} }, {"nvim-treesitter/nvim-treesitter", lazy = false, branch = "main", build = ":TSUpdate", opts = {}}, { "nvim-tree/nvim-tree.lua", opts = {} }, "nvim-tree/nvim-web-devicons", @@ -88,12 +84,7 @@ cmp.setup({ local capabilities = require("cmp_nvim_lsp").default_capabilities() -require("mason-lspconfig").setup({ - function (server_name) - require("lspconfig")[server_name].setup({ - capabilities = capabilities - }) - end, -}) - - +vim.lsp.enable("rust_analyzer") +vim.lsp.enable("pylsp") +vim.lsp.enable("biome") +vim.lsp.enable("eslint") diff --git a/hosts/voidspear/configuration.nix b/hosts/voidspear/configuration.nix index d9e834e..139bb66 100644 --- a/hosts/voidspear/configuration.nix +++ b/hosts/voidspear/configuration.nix @@ -27,6 +27,16 @@ # Enable networking networking.networkmanager.enable = true; + # ZeroTier + services.zerotierone.enable = true; + services.zerotierone.joinNetworks = [ "b3ce837c63" "363c67c55a726a89" ]; + + programs.nix-ld.enable = true; + programs.nix-ld.libraries = with pkgs; [ + libGL + SDL2 + ]; + # Set your time zone. time.timeZone = "Europe/Athens"; @@ -80,6 +90,16 @@ #media-session.enable = true; }; + hardware.bluetooth = { + enable = true; + powerOnBoot = true; + settings = { + General.Experimental = true; + General.FastConnectable = true; + Policy.AutoEnable = true; + }; + }; + # Enable touchpad support (enabled default in most desktopManager). # services.xserver.libinput.enable = true; @@ -88,7 +108,7 @@ users.users.xory = { isNormalUser = true; description = "xory"; - extraGroups = [ "networkmanager" "wheel" ]; + extraGroups = [ "networkmanager" "wheel" "docker" "libvirt" "dialout" ]; packages = with pkgs; [ # thunderbird ]; @@ -116,13 +136,15 @@ # nVidia drivers. hardware.graphics.enable = true; - services.xserver.videoDrivers = [ "nvidia "]; + services.xserver.videoDrivers = [ "nvidia"]; hardware.nvidia = { modesetting.enable = true; powerManagement.enable = false; open = false; nvidiaSettings = true; + package = config.boot.kernelPackages.nvidiaPackages.stable; }; + boot.blacklistedKernelModules = [ "nouveau" ]; nix.gc = { automatic = true; @@ -130,6 +152,11 @@ options = "--delete-older-than 2d"; }; + programs.virt-manager.enable = true; + virtualisation.libvirtd.enable = true; + virtualisation.spiceUSBRedirection.enable = true; + virtualisation.docker.enable = true; + # Some programs need SUID wrappers, can be configured further or are # started in user sessions. # programs.mtr.enable = true; diff --git a/hosts/voidspear/home.nix b/hosts/voidspear/home.nix index 60f5db9..9314968 100644 --- a/hosts/voidspear/home.nix +++ b/hosts/voidspear/home.nix @@ -19,6 +19,23 @@ qbittorrent ffmpeg yt-dlp + vesktop + prismlauncher + keepassxc + obs-studio + mpv + kdePackages.kdenlive + distrobox + screen + arduino-ide + (lutris.override { + extraLibraries = pkgs: [ + wineWowPackages.stable + ]; + }) + woeusb-ng + ntfs3g + obsidian ]; home.file = {