From 04df2c6fcda6e40c52bfdae6678f04eb1e86cf0b Mon Sep 17 00:00:00 2001 From: Markus Heurung Date: Wed, 17 Jul 2024 17:21:05 +0200 Subject: [PATCH 1/6] update lix --- flake.nix | 2 +- modules/common.nix | 23 +++++++++++++++++++++++ 2 files changed, 24 insertions(+), 1 deletion(-) create mode 100644 modules/common.nix diff --git a/flake.nix b/flake.nix index bda9e3d..f4fbc74 100644 --- a/flake.nix +++ b/flake.nix @@ -21,7 +21,7 @@ inputs.nixpkgs.follows = "nixpkgs"; }; lix-module = { - url = "https://git.lix.systems/lix-project/nixos-module/archive/2.90.0-rc1.tar.gz"; + url = "https://git.lix.systems/lix-project/nixos-module/archive/2.90.0.tar.gz"; inputs.nixpkgs.follows = "nixpkgs"; }; niri = { diff --git a/modules/common.nix b/modules/common.nix new file mode 100644 index 0000000..e4aff01 --- /dev/null +++ b/modules/common.nix @@ -0,0 +1,23 @@ +{ config, pkgs, ... }: + +{ + nix.settings.experimental-features = [ "nix-command" "flakes" ]; + + # Set your time zone. + time.timeZone = "Europe/Berlin"; + + # Select internationalisation properties. + i18n.defaultLocale = "en_US.UTF-8"; + + i18n.extraLocaleSettings = { + LC_ADDRESS = "de_DE.UTF-8"; + LC_IDENTIFICATION = "de_DE.UTF-8"; + LC_MEASUREMENT = "de_DE.UTF-8"; + LC_MONETARY = "de_DE.UTF-8"; + LC_NAME = "de_DE.UTF-8"; + LC_NUMERIC = "de_DE.UTF-8"; + LC_PAPER = "de_DE.UTF-8"; + LC_TELEPHONE = "de_DE.UTF-8"; + LC_TIME = "de_DE.UTF-8"; + }; +}; From 010e402f5eb511b1efc904ed4b80bfc6a4ecd916 Mon Sep 17 00:00:00 2001 From: Markus Heurung Date: Wed, 17 Jul 2024 17:21:16 +0200 Subject: [PATCH 2/6] install darktable --- home.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/home.nix b/home.nix index 4799efd..23587fd 100644 --- a/home.nix +++ b/home.nix @@ -25,6 +25,7 @@ alacritty brightnessctl curl + darktable ddcutil distrobox dog From f1c69c8cf84a0b09d14cea4b3c8e608e2709e2b7 Mon Sep 17 00:00:00 2001 From: Markus Heurung Date: Wed, 17 Jul 2024 17:21:23 +0200 Subject: [PATCH 3/6] configure waybar --- home.nix | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) diff --git a/home.nix b/home.nix index 23587fd..67d7e08 100644 --- a/home.nix +++ b/home.nix @@ -420,6 +420,48 @@ "custom/notification" "custom/power" ]; + "sway/scratchpad" = { + format = "{icon} {count}"; + show-empty = false; + format-icons = ["" ""]; + tooltip = true; + tooltip-format = "{app}: {title}"; + }; + "backlight" = { + device = "ddcci6"; + format = "{percent}% {icon}"; + format-icons = [ "" "" "" "" "" "" ""]; + }; + "clock" = { + format = "{:%d. %B | %H:%M}"; + tooltip-format = "{:%Y %B}\n{calendar}"; + format-alt = "{: KW %OV, %A, %d. %B %Y | %H:%M}"; + calendar = { + mode = "year"; + mode-mon-col = 3; + weeks-pos = "right"; + on-scroll = 1; + on-click-right = "mode"; + format = { + months = "{}"; + days = "{}"; + weeks = "W{}"; + weekdays = "{}"; + today = "{}"; + }; + }; + "actions" = { + on-click-right = "mode"; + on-click-forward = "tz_up"; + on-click-backward = "tz_down"; + on-scroll-up = "shift_up"; + on-scroll-down = "shift_down"; + }; + }; + "tray" = { + icon-size = 16; + spacing = 6; + }; }; }; }; From 4cc9a13e7ff6cc948c7d020de0f5c6f487a2b768 Mon Sep 17 00:00:00 2001 From: Markus Heurung Date: Wed, 17 Jul 2024 17:21:42 +0200 Subject: [PATCH 4/6] start reworking justfile --- justfile | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/justfile b/justfile index f05757d..fa70683 100644 --- a/justfile +++ b/justfile @@ -1,16 +1,17 @@ default: - just --list + @just --list -system_rebuild: +rebuild-pre: + git add *.nix + +rebuild-post: + just check-sops + +rebuild: rebuild sudo nixos-rebuild switch --flake .#$(hostname) home_rebuild: home-manager switch --flake .#muhh -full_rebuild: - system_rebuild - home_rebuild - -update_system: +update: nix flake update - full_rebuild From 4460a9f28840d4981832e1cc5c8294ac5d30e838 Mon Sep 17 00:00:00 2001 From: Markus Heurung Date: Wed, 17 Jul 2024 17:22:24 +0200 Subject: [PATCH 5/6] first things refactored in nixos configuration --- hosts/cube.nix | 31 ++++--------------------------- modules/common.nix | 4 ++-- 2 files changed, 6 insertions(+), 29 deletions(-) diff --git a/hosts/cube.nix b/hosts/cube.nix index d5f62c6..0739c88 100644 --- a/hosts/cube.nix +++ b/hosts/cube.nix @@ -1,13 +1,10 @@ -# Edit this configuration file to define what should be installed on -# your system. Help is available in the configuration.nix(5) man page -# and in the NixOS manual (accessible by running ‘nixos-help’). - { config, pkgs, ... }: { imports = - [ # Include the results of the hardware scan. + [ ./cube-hardware-configuration.nix + ../modules/common.nix ]; # Bootloader. @@ -21,8 +18,6 @@ boot.loader.efi.canTouchEfiVariables = true; - nix.settings.experimental-features = [ "nix-command" "flakes" ]; - networking.hostName = "cube"; # Define your hostname. # networking.wireless.enable = true; # Enables wireless support via wpa_supplicant. @@ -41,24 +36,6 @@ }; }; - # Set your time zone. - time.timeZone = "Europe/Berlin"; - - # Select internationalisation properties. - i18n.defaultLocale = "en_US.UTF-8"; - - i18n.extraLocaleSettings = { - LC_ADDRESS = "de_DE.UTF-8"; - LC_IDENTIFICATION = "de_DE.UTF-8"; - LC_MEASUREMENT = "de_DE.UTF-8"; - LC_MONETARY = "de_DE.UTF-8"; - LC_NAME = "de_DE.UTF-8"; - LC_NUMERIC = "de_DE.UTF-8"; - LC_PAPER = "de_DE.UTF-8"; - LC_TELEPHONE = "de_DE.UTF-8"; - LC_TIME = "de_DE.UTF-8"; - }; - security = { pam.services.swaylock = {}; polkit.enable = true; @@ -73,8 +50,8 @@ alsa.enable = true; alsa.support32Bit = true; pulse.enable = true; - # If you want to use JACK applications, uncomment this - #jack.enable = true; + # If you want to use JACK applications, uncomment this + # jack.enable = true; }; services.plex = { enable = true; diff --git a/modules/common.nix b/modules/common.nix index e4aff01..bc4be3a 100644 --- a/modules/common.nix +++ b/modules/common.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, lib, pkgs, modulesPath, ... }: { nix.settings.experimental-features = [ "nix-command" "flakes" ]; @@ -20,4 +20,4 @@ LC_TELEPHONE = "de_DE.UTF-8"; LC_TIME = "de_DE.UTF-8"; }; -}; +} From aea9ebc16ac2bb15b6c05b10f5f05f0e9b0bbe8d Mon Sep 17 00:00:00 2001 From: Markus Heurung Date: Wed, 17 Jul 2024 17:22:30 +0200 Subject: [PATCH 6/6] updates --- flake.lock | 147 ++++++++++++++++++++++++----------------------------- 1 file changed, 67 insertions(+), 80 deletions(-) diff --git a/flake.lock b/flake.lock index 953fbc9..97c2830 100644 --- a/flake.lock +++ b/flake.lock @@ -53,11 +53,11 @@ "base16-helix": { "flake": false, "locked": { - "lastModified": 1696727917, - "narHash": "sha256-FVrbPk+NtMra0jtlC5oxyNchbm8FosmvXIatkRbYy1g=", + "lastModified": 1720809814, + "narHash": "sha256-numb3xigRGnr/deF7wdjBwVg7fpbTH7reFDkJ75AJkY=", "owner": "tinted-theming", "repo": "base16-helix", - "rev": "dbe1480d99fe80f08df7970e471fac24c05f2ddb", + "rev": "34f41987bec14c0f3f6b2155c19787b1f6489625", "type": "github" }, "original": { @@ -463,22 +463,6 @@ } }, "flake-compat_5": { - "flake": false, - "locked": { - "lastModified": 1696426674, - "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", - "owner": "edolstra", - "repo": "flake-compat", - "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", - "type": "github" - }, - "original": { - "owner": "edolstra", - "repo": "flake-compat", - "type": "github" - } - }, - "flake-compat_6": { "flake": false, "locked": { "lastModified": 1673956053, @@ -589,11 +573,11 @@ ] }, "locked": { - "lastModified": 1719877454, - "narHash": "sha256-g5N1yyOSsPNiOlFfkuI/wcUjmtah+nxdImJqrSATjOU=", + "lastModified": 1719994518, + "narHash": "sha256-pQMhCCHyQGRzdfAkdJ4cIWiw+JNuWsTX7f0ZYSyz0VY=", "owner": "hercules-ci", "repo": "flake-parts", - "rev": "4e3583423212f9303aa1a6337f8dffb415920e4f", + "rev": "9227223f6d922fee3c7b190b2cc238a99527bbb7", "type": "github" }, "original": { @@ -761,7 +745,10 @@ }, "git-hooks": { "inputs": { - "flake-compat": "flake-compat_5", + "flake-compat": [ + "nixvim", + "flake-compat" + ], "gitignore": "gitignore_4", "nixpkgs": [ "nixvim", @@ -773,11 +760,11 @@ ] }, "locked": { - "lastModified": 1719259945, - "narHash": "sha256-F1h+XIsGKT9TkGO3omxDLEb/9jOOsI6NnzsXFsZhry4=", + "lastModified": 1720524665, + "narHash": "sha256-ni/87oHPZm6Gv0ECYxr1f6uxB0UKBWJ6HvS7lwLU6oY=", "owner": "cachix", "repo": "git-hooks.nix", - "rev": "0ff4381bbb8f7a52ca4a851660fc7a437a4c6e07", + "rev": "8d6a17d0cdf411c55f12602624df6368ad86fac1", "type": "github" }, "original": { @@ -904,11 +891,11 @@ ] }, "locked": { - "lastModified": 1720167120, - "narHash": "sha256-K9JYdlPiyaXp33JRg7CT8rMwH56e4ncXSsXW/YKnNXc=", + "lastModified": 1721135958, + "narHash": "sha256-H548rpPMsn25LDKn1PCFmPxmWlClJJGnvdzImHkqjuY=", "owner": "nix-community", "repo": "home-manager", - "rev": "bbe6e94737289c8cb92d4d8f9199fbfe4f11c0ba", + "rev": "afd2021bedff2de92dfce0e257a3d03ae65c603d", "type": "github" }, "original": { @@ -926,11 +913,11 @@ ] }, "locked": { - "lastModified": 1719827439, - "narHash": "sha256-tneHOIv1lEavZ0vQ+rgz67LPNCgOZVByYki3OkSshFU=", + "lastModified": 1720734513, + "narHash": "sha256-neWQ8eNtLTd+YMesb7WjKl1SVCbDyCm46LUgP/g/hdo=", "owner": "nix-community", "repo": "home-manager", - "rev": "59ce796b2563e19821361abbe2067c3bb4143a7d", + "rev": "90ae324e2c56af10f20549ab72014804a3064c7f", "type": "github" }, "original": { @@ -963,15 +950,15 @@ "lix": { "flake": false, "locked": { - "lastModified": 1718419213, - "narHash": "sha256-WY7BGnu5PnbK4O8cKKv9kvxwzZIGbIQUQLGPHFXitI0=", - "rev": "253546d5fbf8a5aa60ac8164c1b4f5794dc4e9d1", + "lastModified": 1720626042, + "narHash": "sha256-f8k+BezKdJfmE+k7zgBJiohtS3VkkriycdXYsKOm3sc=", + "rev": "2a4376be20d70feaa2b0e640c5041fb66ddc67ed", "type": "tarball", - "url": "https://git.lix.systems/api/v1/repos/lix-project/lix/archive/253546d5fbf8a5aa60ac8164c1b4f5794dc4e9d1.tar.gz" + "url": "https://git.lix.systems/api/v1/repos/lix-project/lix/archive/2a4376be20d70feaa2b0e640c5041fb66ddc67ed.tar.gz" }, "original": { "type": "tarball", - "url": "https://git.lix.systems/lix-project/lix/archive/2.90.0-rc1.tar.gz" + "url": "https://git.lix.systems/lix-project/lix/archive/2.90.0.tar.gz" } }, "lix-module": { @@ -984,15 +971,15 @@ ] }, "locked": { - "lastModified": 1718778548, - "narHash": "sha256-64lB/NO6AQ6z6EDCemPSYZWX/Qc6Rt04cPia5T5v01g=", - "rev": "29ed1bb67751e5b107d08df35d18dda6d45324e9", + "lastModified": 1720641669, + "narHash": "sha256-yEO2cGNgzm9x/XxiDQI+WckSWnZX63R8aJLBRSXtYNE=", + "rev": "5c48c833c15bb80d127a398a8c2484d42fdd8257", "type": "tarball", - "url": "https://git.lix.systems/api/v1/repos/lix-project/nixos-module/archive/29ed1bb67751e5b107d08df35d18dda6d45324e9.tar.gz" + "url": "https://git.lix.systems/api/v1/repos/lix-project/nixos-module/archive/5c48c833c15bb80d127a398a8c2484d42fdd8257.tar.gz" }, "original": { "type": "tarball", - "url": "https://git.lix.systems/lix-project/nixos-module/archive/2.90.0-rc1.tar.gz" + "url": "https://git.lix.systems/lix-project/nixos-module/archive/2.90.0.tar.gz" } }, "niri": { @@ -1006,11 +993,11 @@ "xwayland-satellite": "xwayland-satellite" }, "locked": { - "lastModified": 1720168240, - "narHash": "sha256-X3kvUPWY6OjC7he7ddfm12H5vHKXyxWYF6vdPiuEuDg=", + "lastModified": 1721168270, + "narHash": "sha256-wmFlWj5d8XcgDksIrWohKsGxiidr6YsI4qLVpDtK95U=", "owner": "sodiboo", "repo": "niri-flake", - "rev": "9ae9706a379024287dc16b397c92ceddabaceffa", + "rev": "e59130f4e446a0161ac75ce031760deec6f7c5ac", "type": "github" }, "original": { @@ -1039,11 +1026,11 @@ "niri-unstable": { "flake": false, "locked": { - "lastModified": 1720166663, - "narHash": "sha256-R/MLWwmDbrKlwBxP3dKfDN5efv71GmIArGfKJgmbpn4=", + "lastModified": 1721114523, + "narHash": "sha256-HXUNwB2qeTNmTGX7z8JvyJAKJcDWGRsneaisSW9U1MA=", "owner": "YaLTeR", "repo": "niri", - "rev": "6147a31b48aadfd34018fcf4733c101271774f50", + "rev": "3ace97660fde7fe1f0cc07a3925d1114af9a9c2f", "type": "github" }, "original": { @@ -1060,11 +1047,11 @@ ] }, "locked": { - "lastModified": 1719845423, - "narHash": "sha256-ZLHDmWAsHQQKnmfyhYSHJDlt8Wfjv6SQhl2qek42O7A=", + "lastModified": 1720845312, + "narHash": "sha256-yPhAsJTpyoIPQZJGC8Fw8W2lAXyhLoTn+HP20bmfkfk=", "owner": "lnl7", "repo": "nix-darwin", - "rev": "ec12b88104d6c117871fad55e931addac4626756", + "rev": "5ce8503cf402cf76b203eba4b7e402bea8e44abc", "type": "github" }, "original": { @@ -1151,11 +1138,11 @@ }, "nixpkgs-stable": { "locked": { - "lastModified": 1719956923, - "narHash": "sha256-nNJHJ9kfPdzYsCOlHOnbiiyKjZUW5sWbwx3cakg3/C4=", + "lastModified": 1720954236, + "narHash": "sha256-1mEKHp4m9brvfQ0rjCca8P1WHpymK3TOr3v34ydv9bs=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "706eef542dec88cc0ed25b9075d3037564b2d164", + "rev": "53e81e790209e41f0c1efa9ff26ff2fd7ab35e27", "type": "github" }, "original": { @@ -1167,16 +1154,16 @@ }, "nixpkgs-stable_2": { "locked": { - "lastModified": 1719663039, - "narHash": "sha256-tXlrgAQygNIy49LDVFuPXlWD2zTQV9/F8pfoqwwPJyo=", + "lastModified": 1720915306, + "narHash": "sha256-6vuViC56+KSr+945bCV8akHK+7J5k6n/epYg/W3I5eQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "4a1e673523344f6ccc84b37f4413ad74ea19a119", + "rev": "74348da2f3a312ee25cea09b98cdba4cb9fa5d5d", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-23.11", + "ref": "release-24.05", "repo": "nixpkgs", "type": "github" } @@ -1255,11 +1242,11 @@ }, "nixpkgs_7": { "locked": { - "lastModified": 1720031269, - "narHash": "sha256-rwz8NJZV+387rnWpTYcXaRNvzUSnnF9aHONoJIYmiUQ=", + "lastModified": 1720957393, + "narHash": "sha256-oedh2RwpjEa+TNxhg5Je9Ch6d3W1NKi7DbRO1ziHemA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "9f4128e00b0ae8ec65918efeba59db998750ead6", + "rev": "693bc46d169f5af9c992095736e82c3488bf7dbb", "type": "github" }, "original": { @@ -1271,11 +1258,11 @@ }, "nixpkgs_8": { "locked": { - "lastModified": 1720031269, - "narHash": "sha256-rwz8NJZV+387rnWpTYcXaRNvzUSnnF9aHONoJIYmiUQ=", + "lastModified": 1720957393, + "narHash": "sha256-oedh2RwpjEa+TNxhg5Je9Ch6d3W1NKi7DbRO1ziHemA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "9f4128e00b0ae8ec65918efeba59db998750ead6", + "rev": "693bc46d169f5af9c992095736e82c3488bf7dbb", "type": "github" }, "original": { @@ -1298,11 +1285,11 @@ "treefmt-nix": "treefmt-nix" }, "locked": { - "lastModified": 1720126856, - "narHash": "sha256-xtRwIUKv7EpuyGtvq+rO7PoZZIpD55AYe6rl+plEhY8=", + "lastModified": 1721224205, + "narHash": "sha256-W0+l7HNzZfEmIx/1Yp3Tow/GZILVjrMjWfTt1Mos7mI=", "owner": "nix-community", "repo": "nixvim", - "rev": "92e9f5466dcfd51e8e2e7627e992c1c9d5fc6fd6", + "rev": "55bda0cc3b230255d271e5eef82f3279dae9f859", "type": "github" }, "original": { @@ -1439,11 +1426,11 @@ "nixpkgs-stable": "nixpkgs-stable_2" }, "locked": { - "lastModified": 1719873517, - "narHash": "sha256-D1dxZmXf6M2h5lNE1m6orojuUawVPjogbGRsqSBX+1g=", + "lastModified": 1720926522, + "narHash": "sha256-eTpnrT6yu1vp8C0B5fxHXhgKxHoYMoYTEikQx///jxY=", "owner": "Mic92", "repo": "sops-nix", - "rev": "a11224af8d824935f363928074b4717ca2e280db", + "rev": "0703ba03fd9c1665f8ab68cc3487302475164617", "type": "github" }, "original": { @@ -1461,7 +1448,7 @@ "base16-kitty": "base16-kitty", "base16-tmux": "base16-tmux", "base16-vim": "base16-vim", - "flake-compat": "flake-compat_6", + "flake-compat": "flake-compat_5", "gnome-shell": "gnome-shell", "home-manager": "home-manager_3", "nixpkgs": [ @@ -1469,11 +1456,11 @@ ] }, "locked": { - "lastModified": 1719525570, - "narHash": "sha256-xSO/H67GAHEW0siD2PHoO/e97MbROL3r3s5SpF6A6Dc=", + "lastModified": 1720818679, + "narHash": "sha256-u9PqY7O6TN42SLeb0e6mnYAgQOoQmclaVSHfLKMpmu0=", "owner": "danth", "repo": "stylix", - "rev": "1ff9d37d27377bfe8994c24a8d6c6c1734ffa116", + "rev": "29148118cc33f08b71058e1cda7ca017f5300b51", "type": "github" }, "original": { @@ -1595,11 +1582,11 @@ ] }, "locked": { - "lastModified": 1719887753, - "narHash": "sha256-p0B2r98UtZzRDM5miGRafL4h7TwGRC4DII+XXHDHqek=", + "lastModified": 1720818892, + "narHash": "sha256-f52x9srIcqQm1Df3T+xYR5P6VfdnDFa2vkkcLhlTp6U=", "owner": "numtide", "repo": "treefmt-nix", - "rev": "bdb6355009562d8f9313d9460c0d3860f525bc6c", + "rev": "5b002f8a53ed04c1a4177e7b00809d57bd2c696f", "type": "github" }, "original": { @@ -1611,11 +1598,11 @@ "xwayland-satellite": { "flake": false, "locked": { - "lastModified": 1720130149, - "narHash": "sha256-NcvFk8u43Q/XiuHzO1yQX9veXy6frRBJZhDHz3ESUX0=", + "lastModified": 1721167978, + "narHash": "sha256-0sFfLanX66bDSbIiGZP63hFiYg7pmH6ykR7wYSJ1IAk=", "owner": "Supreeeme", "repo": "xwayland-satellite", - "rev": "d32eae139dc7d2bdb288a308e76fc98a57a4e66b", + "rev": "054af2a1f7d2785baa25e2eb4de51d88226bed23", "type": "github" }, "original": {