From 58f64684c91e42ad12938241b4547344e8fb27bc Mon Sep 17 00:00:00 2001 From: tulg Date: Sat, 25 Oct 2025 11:06:24 +0300 Subject: [PATCH] nixos-anywhere test --- flake.lock | 24 +++++++++---------- hardware-configuration.nix | 24 +++++++++++++++++++ hosts/virgil/configuration.nix | 6 +++-- hosts/virgil/disko.nix | 2 +- ...ation.nix => hhhardware-configuration.nix} | 0 modules/home-manager/home.nix | 15 ++++++------ 6 files changed, 48 insertions(+), 23 deletions(-) create mode 100644 hardware-configuration.nix rename hosts/virgil/{hardware-configuration.nix => hhhardware-configuration.nix} (100%) diff --git a/flake.lock b/flake.lock index 284b272..d342918 100644 --- a/flake.lock +++ b/flake.lock @@ -199,11 +199,11 @@ ] }, "locked": { - "lastModified": 1760887455, - "narHash": "sha256-/xU8iYZjolWbMUNBQF6af5zgGs73Qw21WMgz1tLs3Yw=", + "lastModified": 1761316995, + "narHash": "sha256-BAAjCpjTnfaxtc9NCkbUl9MUv5JmAG5qU7/G8TTHmb4=", "owner": "nix-community", "repo": "home-manager", - "rev": "aeabc1ac63e6ebb8ba4714c4abdfe0556f2de765", + "rev": "82b58f38202540bce4e5e00759d115c5a43cab85", "type": "github" }, "original": { @@ -291,11 +291,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1760524057, - "narHash": "sha256-EVAqOteLBFmd7pKkb0+FIUyzTF61VKi7YmvP1tw4nEw=", + "lastModified": 1761114652, + "narHash": "sha256-f/QCJM/YhrV/lavyCVz8iU3rlZun6d+dAiC3H+CDle4=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "544961dfcce86422ba200ed9a0b00dd4b1486ec5", + "rev": "01f116e4df6a15f4ccdffb1bcd41096869fb385c", "type": "github" }, "original": { @@ -362,11 +362,11 @@ "systems": "systems" }, "locked": { - "lastModified": 1761190730, - "narHash": "sha256-XAs/Q4zBJIfK/bwq9KjTUkTH15A+Pe2rIilyvalEHuM=", + "lastModified": 1761333046, + "narHash": "sha256-3RGdMQKWB0W0IsQt3g51ItTKxhRgF8ZYhiBY2isUmYA=", "owner": "noctalia-dev", "repo": "noctalia-shell", - "rev": "c3439b262c7cb3d57c93197a93a3aa382582bdae", + "rev": "31084062e3f6f37b62a4250a1539937f8127c8fd", "type": "github" }, "original": { @@ -621,11 +621,11 @@ ] }, "locked": { - "lastModified": 1760898315, - "narHash": "sha256-d2qbZpREjUQm65lzS70b2TVgTfOpAjQUZa+FS58+WnA=", + "lastModified": 1761269012, + "narHash": "sha256-/naxU8jbaoZM3CQCjJiI6Z5+vsv+zA7eZdhFY1tbzsM=", "owner": "0xc000022070", "repo": "zen-browser-flake", - "rev": "5e52b6a9ec07d22c9555891005b1b39f1bbd83ed", + "rev": "c7f5f0122cf8c4bfd9ef3b138eb615f0e54f1459", "type": "github" }, "original": { diff --git a/hardware-configuration.nix b/hardware-configuration.nix new file mode 100644 index 0000000..bb23f0b --- /dev/null +++ b/hardware-configuration.nix @@ -0,0 +1,24 @@ +# 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 = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ ]; + boot.extraModulePackages = [ ]; + + # 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.ens18.useDHCP = lib.mkDefault true; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; +} diff --git a/hosts/virgil/configuration.nix b/hosts/virgil/configuration.nix index a132c2c..3c0a440 100644 --- a/hosts/virgil/configuration.nix +++ b/hosts/virgil/configuration.nix @@ -1,4 +1,3 @@ - { config, pkgs, @@ -6,7 +5,7 @@ ... }: { imports = [ - # ./disko.nix + ./disko.nix ./hardware-configuration.nix ./vfio.nix ]; @@ -35,6 +34,9 @@ ]; }; networking.networkmanager.enable = true; + programs.bash.shellAliases = { + fuck = "you"; + }; time.timeZone = "Europe/Istanbul"; programs.hyprland = { diff --git a/hosts/virgil/disko.nix b/hosts/virgil/disko.nix index 8125cd3..88fd9a6 100644 --- a/hosts/virgil/disko.nix +++ b/hosts/virgil/disko.nix @@ -3,7 +3,7 @@ disk = { nixos = { type = "disk"; - device = "/dev/vda"; + device = "/dev/sda"; content = { type = "gpt"; partitions = { diff --git a/hosts/virgil/hardware-configuration.nix b/hosts/virgil/hhhardware-configuration.nix similarity index 100% rename from hosts/virgil/hardware-configuration.nix rename to hosts/virgil/hhhardware-configuration.nix diff --git a/modules/home-manager/home.nix b/modules/home-manager/home.nix index 6f7588d..c6cdac4 100644 --- a/modules/home-manager/home.nix +++ b/modules/home-manager/home.nix @@ -58,8 +58,6 @@ in { pkgs.vscode-extensions.jnoortheen.nix-ide ]; profiles.tulg.userSettings = { - - }; }; programs.zen-browser.enable = true; @@ -84,10 +82,9 @@ in { max_height = 900; }; tasks = { - image_bound = [ 0 0 ]; + image_bound = [0 0]; }; }; - }; xdg.configFile."hypr" = { @@ -120,8 +117,10 @@ in { enable = true; shellAliases = { - a = "echo ids"; - rb = "nixos-rebuild switch --flake"; + a = "echo idssss"; + rb = "sudo nixos-rebuild switch --flake ~/nixdots#"; + nixtest = "sudo nixos-rebuild test --flake ~/nixdots#"; + infect = "nix run github:nix-community/nixos-anywhere -- -- flake"; }; bashrcExtra = '' @@ -132,8 +131,8 @@ in { programs.git = { enable = true; settings = { - user.name = "tulg"; - user.email = "tulg@protonmail.ch"; + user.name = "tulg"; + user.email = "tulg@protonmail.ch"; }; };