aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZhongheng Liu <z.liu@outlook.com.gr>2025-01-08 14:14:12 +0200
committerZhongheng Liu <z.liu@outlook.com.gr>2025-01-08 14:14:12 +0200
commit35b2d418540f398875ea338db1e29dbc1c381a69 (patch)
tree68c040bfc684a4edf6c3cdc2f552fe6f42d0ab8e
parent8953c93b60e31357a60112f8f707a1bb6cff0572 (diff)
parentecaf5df80adb914875ff926410e9226d72f8fa05 (diff)
downloadnixos-configuration-feature-email-msmtp.tar.gz
nixos-configuration-feature-email-msmtp.tar.bz2
nixos-configuration-feature-email-msmtp.zip
Merge branch 'main' into feature-email-msmtpfeature-email-msmtp
-rw-r--r--README.md20
-rw-r--r--common/variables.nix55
-rw-r--r--deploy.sh18
-rw-r--r--devenv.nix16
-rw-r--r--flake.lock254
-rw-r--r--flake.nix81
-rw-r--r--home-manager/stvnliu/ags/config/hyprworkspaces.js2
-rw-r--r--home-manager/stvnliu/ags/config/mpris.js17
-rw-r--r--home-manager/stvnliu/ags/default.nix7
-rw-r--r--home-manager/stvnliu/devenv.nix12
-rw-r--r--home-manager/stvnliu/editors.nix20
-rw-r--r--home-manager/stvnliu/gtk.nix9
-rw-r--r--home-manager/stvnliu/home.nix20
-rw-r--r--home-manager/stvnliu/hypr/default.nix9
-rw-r--r--home-manager/stvnliu/hypr/hypridle.nix6
-rw-r--r--home-manager/stvnliu/hypr/hyprland/binds.nix108
-rw-r--r--home-manager/stvnliu/hypr/hyprland/default.nix39
-rw-r--r--home-manager/stvnliu/hypr/hyprland/hypr_autostart.nix8
-rw-r--r--home-manager/stvnliu/hypr/hyprland/window_rules.nix7
-rw-r--r--home-manager/stvnliu/hypr/hyprland/xf86_binds.nix6
-rw-r--r--home-manager/stvnliu/hypr/hyprlock.nix9
-rw-r--r--home-manager/stvnliu/hypr/hyprpaper.nix11
-rw-r--r--home-manager/stvnliu/mako.nix13
-rw-r--r--home-manager/stvnliu/nixvim/auto-pairs.nix2
-rw-r--r--home-manager/stvnliu/nixvim/bufferline.nix2
-rw-r--r--home-manager/stvnliu/nixvim/cmp.nix32
-rw-r--r--home-manager/stvnliu/nixvim/default.nix4
-rw-r--r--home-manager/stvnliu/nixvim/ionide.nix2
-rw-r--r--home-manager/stvnliu/nixvim/lsp.nix2
-rw-r--r--home-manager/stvnliu/nixvim/telescope.nix2
-rw-r--r--home-manager/stvnliu/nixvim/transparent.nix2
-rw-r--r--home-manager/stvnliu/nixvim/treesitter.nix2
-rw-r--r--home-manager/stvnliu/nixvim/virt-column.nix2
-rw-r--r--home-manager/stvnliu/nixvim/which_key.nix2
-rw-r--r--home-manager/stvnliu/nixvim/wilder.nix2
-rw-r--r--home-manager/stvnliu/packages/default.nix10
-rw-r--r--home-manager/stvnliu/packages/dev.nix7
-rw-r--r--home-manager/stvnliu/packages/discord.nix13
-rw-r--r--home-manager/stvnliu/packages/gaming.nix4
-rw-r--r--home-manager/stvnliu/packages/office-programs.nix9
-rw-r--r--home-manager/stvnliu/packages/pentesting.nix7
-rw-r--r--home-manager/stvnliu/packages/util-programs.nix9
-rw-r--r--home-manager/stvnliu/packages/vscodium.nix4
-rw-r--r--home-manager/stvnliu/packages/wayland-utils.nix11
-rw-r--r--home-manager/stvnliu/programs/default.nix10
-rw-r--r--home-manager/stvnliu/programs/foot.nix11
-rw-r--r--home-manager/stvnliu/programs/git.nix9
-rw-r--r--home-manager/stvnliu/programs/rofi.nix9
-rw-r--r--home-manager/stvnliu/programs/tmux.nix9
-rw-r--r--home-manager/stvnliu/programs/walker.nix19
-rw-r--r--home-manager/stvnliu/scripts/default.nix9
-rw-r--r--home-manager/stvnliu/scripts/git-check.script.nix95
-rw-r--r--home-manager/stvnliu/scripts/heic-to-jpg.script.nix2
-rw-r--r--home-manager/stvnliu/scripts/tmux-default.script.nix31
-rw-r--r--home-manager/stvnliu/services/default.nix8
-rw-r--r--home-manager/stvnliu/services/mpd.nix29
-rw-r--r--home-manager/stvnliu/services/swaync.nix7
-rw-r--r--home-manager/stvnliu/shells/aliases/default.nix2
-rw-r--r--home-manager/stvnliu/shells/default.nix56
-rw-r--r--home-manager/stvnliu/shells/direnv.nix2
-rw-r--r--home-manager/stvnliu/shells/env/default.nix7
-rw-r--r--home-manager/stvnliu/shells/fish/default.nix122
-rw-r--r--home-manager/stvnliu/shells/nushell/default.nix44
-rw-r--r--home-manager/stvnliu/shells/starship/default.nix46
-rw-r--r--home-manager/stvnliu/shells/zoxide.nix9
-rw-r--r--home-manager/stvnliu/shells/zsh.nix62
-rw-r--r--home-manager/stvnliu/spicetify.nix15
-rw-r--r--home-manager/stvnliu/stylix.nix13
-rw-r--r--home-manager/stvnliu/wechat/default.nix2
-rw-r--r--home-manager/stvnliu/wechat/license.tar.gzbin1354 -> 0 bytes
-rw-r--r--home-manager/stvnliu/xdg.nix3
-rw-r--r--nixos/ags.nix2
-rw-r--r--nixos/bootloader.nix23
-rw-r--r--nixos/configuration.nix79
-rw-r--r--nixos/custom-hosts.nix9
-rw-r--r--nixos/fonts.nix2
-rw-r--r--nixos/greetd.nix15
-rw-r--r--nixos/hardware-configuration.nix23
-rw-r--r--nixos/ly.nix9
-rw-r--r--nixos/nvidia.nix13
-rw-r--r--nixos/sddm-theme.nix2
-rw-r--r--nixos/services/avahi.service.nix2
-rw-r--r--nixos/services/laptop.preset.nix3
-rw-r--r--nixos/services/logind.service.nix9
-rw-r--r--nixos/services/misc.service.nix2
-rw-r--r--nixos/services/nginx.service.nix11
-rw-r--r--nixos/services/pipewire.service.nix58
-rw-r--r--nixos/services/power_management.service.nix9
-rw-r--r--nixos/services/printing.service.nix4
-rw-r--r--nixos/services/seatd.service.nix9
-rw-r--r--nixos/services/syncthing.service.nix13
-rw-r--r--nixos/services/tailscale.service.nix7
-rw-r--r--nixos/virtualisation.nix11
93 files changed, 1039 insertions, 784 deletions
diff --git a/README.md b/README.md
index e9de43b..7236e33 100644
--- a/README.md
+++ b/README.md
@@ -1,17 +1,29 @@
# My NixOS configuration
-
- system: `"x86_64-linux"`
- - host os: `Linux 6.10.9-zen1, NixOS, 24.11 (Vicuna), 24.11.20241004.bc947f5`
+ - host os: `Linux 6.12.2-zen1, NixOS, 25.05 (Warbler), 25.05.20241229.88195a9`
- multi-user?: `yes`
- sandbox: `yes`
- - version: `nix-env (Lix, like Nix) 2.91.0
+ - version: `nix-env (Nix) 2.24.11`
+ - channels(root): `"nixos"`
+ - nixpkgs: `/nix/store/8vz84mqgnm1gz5yk7hgnnb5gir5hjxas-source`
## Installation
This configuration is dependent on flakes being enabled in the system building the config.
+### Build script
+Build the default version of this configuration.
+```
+wget https://raw.githubusercontent.com/stvnliu/nixos-configuration/refs/heads/main/deploy.sh
+chmod +x ./deploy.sh
+./deploy.sh https://github.com/stvnliu/nixos-configuration nixos-msi
+```
+
+or manually:
+
```
-sudo nixos-rebuild --flake <path_to_this_config>#<your_hostname> switch
+git clone <repo_url> <path_to_config>
+sudo nixos-rebuild --flake <path_to_config>#<your_hostname> boot
```
## Features
diff --git a/common/variables.nix b/common/variables.nix
index f4af0f1..3e76916 100644
--- a/common/variables.nix
+++ b/common/variables.nix
@@ -1,27 +1,33 @@
-{
- config,
- pkgs,
- lib,
- ...
-}: let
+{ config
+, pkgs
+, lib
+, ...
+}:
+let
monitorMaxBrightness = "255";
monitorMinBrightness = "32";
-in {
+in
+{
# Type definitions for nix variables used in this configuration
options = with lib;
- with types; {
- defaultApplications = {fileManager = mkOption {type = str;};};
- myWallPaperPath = mkOption {type = path;};
- myUserName = mkOption {type = str;};
- myHostName = mkOption {type = str;};
- myWallPaperPathString = mkOption {type = str;};
- myDisplayName = mkOption {type = str;};
- myEmail = mkOption {type = str;};
- displayScale = mkOption {type = int;};
- myAutostartCommands = mkOption {type = listOf str;};
- myConfigLocation = mkOption {type = str;};
- desktopFontFullName = mkOption {type = str;};
- };
+ with types; {
+ usingMusicPlayerDaemon = mkOption { type = bool; };
+ defaultApplications = {
+ fileManager = mkOption { type = str; };
+ appLauncher = mkOption { type = str; };
+ terminal = mkOption { type = str; };
+ };
+ myWallPaperPath = mkOption { type = path; };
+ myUserName = mkOption { type = str; };
+ myHostName = mkOption { type = str; };
+ myWallPaperPathString = mkOption { type = str; };
+ myDisplayName = mkOption { type = str; };
+ myEmail = mkOption { type = str; };
+ displayScale = mkOption { type = int; };
+ myAutostartCommands = mkOption { type = listOf str; };
+ myConfigLocation = mkOption { type = str; };
+ desktopFontFullName = mkOption { type = str; };
+ };
# Default values for this configuration
config = rec {
@@ -33,7 +39,7 @@ in {
myDisplayName = "Zhongheng Liu";
myEmail = "z.liu@outlook.com.gr";
specialisation."powersave".configuration = {
- myAutostartCommands = ["${pkgs.brightnessctl}/bin/brightnessctl s ${monitorMinBrightness}"];
+ myAutostartCommands = [ "${pkgs.brightnessctl}/bin/brightnessctl s ${monitorMinBrightness}" ];
};
myConfigLocation = "/home/${myUserName}/nix-conf";
desktopFontFullName = "IntoneMono NFM:style=Regular";
@@ -45,6 +51,11 @@ in {
"${pkgs.pa-notify}/bin/pa-notify"
"${pkgs.networkmanagerapplet}/bin/nm-applet"
];
- defaultApplications.fileManager = "${pkgs.nemo}/bin/nemo";
+ defaultApplications = {
+ terminal = "${pkgs.foot}/bin/footclient";
+ fileManager = "${pkgs.nemo}/bin/nemo";
+ appLauncher = "${pkgs.walker}/bin/walker";
+ };
+ usingMusicPlayerDaemon = true;
};
}
diff --git a/deploy.sh b/deploy.sh
new file mode 100644
index 0000000..cc2aaf5
--- /dev/null
+++ b/deploy.sh
@@ -0,0 +1,18 @@
+#!/usr/bin/env sh
+
+# Deploys the configuation to your machine
+
+TMP_DIRNAME="/tmp/nix-config"
+GIT_REMOTE_SRC=$1
+NIX_HOST=$2
+echo "Going to clone $GIT_REMOTE_SRC into $TMP_DIRNAME"
+mkdir "$TMP_DIRNAME"
+
+git clone "$GIT_REMOTE_SRC" "$TMP_DIRNAME"
+prev=$PWD
+cd "$TMP_DIRNAME" || return
+echo "Now going to build nix configuration for $NIX_HOST to switch on next boot"
+sudo nixos-rebuild --flake .#"$NIX_HOST" boot
+
+cd "$prev" || return
+
diff --git a/devenv.nix b/devenv.nix
index 475b359..1ba8269 100644
--- a/devenv.nix
+++ b/devenv.nix
@@ -1,21 +1,15 @@
-{
- pkgs,
- lib,
- config,
- inputs,
- ...
-}: {
+{ pkgs, lib, config, inputs, ... }: {
# https://devenv.sh/basics/
env.GREET = "devenv";
cachix.enable = false;
# https://devenv.sh/packages/
- packages = [pkgs.git];
+ packages = [ pkgs.git ];
# https://devenv.sh/languages/
# languages.rust.enable = true;
languages.nix.enable = true;
pre-commit.hooks = {
- alejandra.enable = true;
+ nixpkgs-fmt.enable = true;
shellcheck.enable = true;
commitizen.enable = true;
};
@@ -38,9 +32,7 @@
# https://devenv.sh/tests/
enterTest =
- /*
- shell
- */
+ # shell
''
echo "Running tests"
git --version | grep --color=auto "${pkgs.git.version}"
diff --git a/flake.lock b/flake.lock
index 1fae2f0..701e63a 100644
--- a/flake.lock
+++ b/flake.lock
@@ -74,11 +74,11 @@
]
},
"locked": {
- "lastModified": 1728330715,
- "narHash": "sha256-xRJ2nPOXb//u1jaBnDP56M7v5ldavjbtR6lfGqSvcKg=",
+ "lastModified": 1735644329,
+ "narHash": "sha256-tO3HrHriyLvipc4xr+Ewtdlo7wM1OjXNjlWRgmM7peY=",
"owner": "numtide",
"repo": "devshell",
- "rev": "dd6b80932022cea34a019e2bb32f6fa9e494dfef",
+ "rev": "f7795ede5b02664b57035b3b757876703e2c3eac",
"type": "github"
},
"original": {
@@ -141,11 +141,11 @@
]
},
"locked": {
- "lastModified": 1733312601,
- "narHash": "sha256-4pDvzqnegAfRkPwO3wmwBhVi/Sye1mzps0zHWYnP88c=",
+ "lastModified": 1736143030,
+ "narHash": "sha256-+hu54pAoLDEZT9pjHlqL9DNzWz0NbUn8NEAHP7PQPzU=",
"owner": "hercules-ci",
"repo": "flake-parts",
- "rev": "205b12d8b7cd4802fbcb8e8ef6a0f1408781a4f9",
+ "rev": "b905f6fc23a9051a6e1b741e1438dbfc0634c6de",
"type": "github"
},
"original": {
@@ -156,7 +156,7 @@
},
"flake-utils": {
"inputs": {
- "systems": "systems"
+ "systems": "systems_2"
},
"locked": {
"lastModified": 1731533236,
@@ -219,18 +219,45 @@
"nixpkgs": [
"nixvim",
"nixpkgs"
+ ]
+ },
+ "locked": {
+ "lastModified": 1735882644,
+ "narHash": "sha256-3FZAG+pGt3OElQjesCAWeMkQ7C/nB1oTHLRQ8ceP110=",
+ "owner": "cachix",
+ "repo": "git-hooks.nix",
+ "rev": "a5a961387e75ae44cc20f0a57ae463da5e959656",
+ "type": "github"
+ },
+ "original": {
+ "owner": "cachix",
+ "repo": "git-hooks.nix",
+ "type": "github"
+ }
+ },
+ "git-hooks_2": {
+ "inputs": {
+ "flake-compat": [
+ "stylix",
+ "flake-compat"
+ ],
+ "gitignore": "gitignore_2",
+ "nixpkgs": [
+ "stylix",
+ "nixpkgs"
],
"nixpkgs-stable": [
- "nixvim",
+ "stylix",
+ "git-hooks",
"nixpkgs"
]
},
"locked": {
- "lastModified": 1734797603,
- "narHash": "sha256-ulZN7ps8nBV31SE+dwkDvKIzvN6hroRY8sYOT0w+E28=",
+ "lastModified": 1731363552,
+ "narHash": "sha256-vFta1uHnD29VUY4HJOO/D6p6rxyObnf+InnSMT4jlMU=",
"owner": "cachix",
"repo": "git-hooks.nix",
- "rev": "f0f0dc4920a903c3e08f5bdb9246bb572fcae498",
+ "rev": "cd1af27aa85026ac759d5d3fccf650abe7e1bbf0",
"type": "github"
},
"original": {
@@ -261,6 +288,28 @@
"type": "github"
}
},
+ "gitignore_2": {
+ "inputs": {
+ "nixpkgs": [
+ "stylix",
+ "git-hooks",
+ "nixpkgs"
+ ]
+ },
+ "locked": {
+ "lastModified": 1709087332,
+ "narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=",
+ "owner": "hercules-ci",
+ "repo": "gitignore.nix",
+ "rev": "637db329424fd7e46cf4185293b9cc8c88c95394",
+ "type": "github"
+ },
+ "original": {
+ "owner": "hercules-ci",
+ "repo": "gitignore.nix",
+ "type": "github"
+ }
+ },
"gnome-shell": {
"flake": false,
"locked": {
@@ -285,11 +334,11 @@
]
},
"locked": {
- "lastModified": 1735053786,
- "narHash": "sha256-Gm+0DcbUS338vvkwyYWms5jsWlx8z8MeQBzcnIDuIkw=",
+ "lastModified": 1736089250,
+ "narHash": "sha256-/LPWMiiJGPHGd7ZYEgmbE2da4zvBW0acmshUjYC3WG4=",
"owner": "nix-community",
"repo": "home-manager",
- "rev": "35b98d20ca8f4ca1f6a2c30b8a2c8bb305a36d84",
+ "rev": "172b91bfb2b7f5c4a8c6ceac29fd53a01ef07196",
"type": "github"
},
"original": {
@@ -306,11 +355,11 @@
]
},
"locked": {
- "lastModified": 1734862405,
- "narHash": "sha256-bXZJvUMJ2A6sIpYcCUAGjYCD5UDzmpmQCdmJSkPhleU=",
+ "lastModified": 1736089250,
+ "narHash": "sha256-/LPWMiiJGPHGd7ZYEgmbE2da4zvBW0acmshUjYC3WG4=",
"owner": "nix-community",
"repo": "home-manager",
- "rev": "cb27edb5221d2f2920a03155f8becc502cf60e35",
+ "rev": "172b91bfb2b7f5c4a8c6ceac29fd53a01ef07196",
"type": "github"
},
"original": {
@@ -327,11 +376,11 @@
]
},
"locked": {
- "lastModified": 1733085484,
- "narHash": "sha256-dVmNuUajnU18oHzBQWZm1BQtANCHaqNuxTHZQ+GN0r8=",
+ "lastModified": 1735774425,
+ "narHash": "sha256-C73gLFnEh8ZI0uDijUgCDWCd21T6I6tsaWgIBHcfAXg=",
"owner": "nix-community",
"repo": "home-manager",
- "rev": "c1fee8d4a60b89cae12b288ba9dbc608ff298163",
+ "rev": "5f6aa268e419d053c3d5025da740e390b12ac936",
"type": "github"
},
"original": {
@@ -340,6 +389,51 @@
"type": "github"
}
},
+ "hyprland-qtutils": {
+ "inputs": {
+ "hyprutils": "hyprutils",
+ "nixpkgs": "nixpkgs",
+ "systems": "systems"
+ },
+ "locked": {
+ "lastModified": 1736114838,
+ "narHash": "sha256-FxbuGQExtN37ToWYnGmO6weOYN6WPHN/RAqbr7gNPek=",
+ "owner": "hyprwm",
+ "repo": "hyprland-qtutils",
+ "rev": "6997fe382dcf396704227d2b98ffdd5066da6959",
+ "type": "github"
+ },
+ "original": {
+ "owner": "hyprwm",
+ "repo": "hyprland-qtutils",
+ "type": "github"
+ }
+ },
+ "hyprutils": {
+ "inputs": {
+ "nixpkgs": [
+ "hyprland-qtutils",
+ "nixpkgs"
+ ],
+ "systems": [
+ "hyprland-qtutils",
+ "systems"
+ ]
+ },
+ "locked": {
+ "lastModified": 1734796073,
+ "narHash": "sha256-TnuKsa8OHrSJEmHm3TLGOWbPNA1gRjmZLsRzKrCqOsg=",
+ "owner": "hyprwm",
+ "repo": "hyprutils",
+ "rev": "c3331116ebd0b71df5ae8c6efe9a7f94148b03bf",
+ "type": "github"
+ },
+ "original": {
+ "owner": "hyprwm",
+ "repo": "hyprutils",
+ "type": "github"
+ }
+ },
"ixx": {
"inputs": {
"flake-utils": [
@@ -376,11 +470,11 @@
]
},
"locked": {
- "lastModified": 1733570843,
- "narHash": "sha256-sQJAxY1TYWD1UyibN/FnN97paTFuwBw3Vp3DNCyKsMk=",
+ "lastModified": 1736085891,
+ "narHash": "sha256-bTl9fcUo767VaSx4Q5kFhwiDpFQhBKna7lNbGsqCQiA=",
"owner": "lnl7",
"repo": "nix-darwin",
- "rev": "a35b08d09efda83625bef267eb24347b446c80b8",
+ "rev": "ba9b3173b0f642ada42b78fb9dfc37ca82266f6c",
"type": "github"
},
"original": {
@@ -393,13 +487,13 @@
"locked": {
"lastModified": 1734649271,
"narHash": "sha256-4EVBRhOjMDuGtMaofAIqzJbg4Ql7Ai0PSeuVZTHjyKQ=",
- "owner": "nixos",
+ "owner": "NixOS",
"repo": "nixpkgs",
"rev": "d70bd19e0a38ad4790d3913bf08fcbfc9eeca507",
"type": "github"
},
"original": {
- "owner": "nixos",
+ "owner": "NixOS",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
@@ -407,11 +501,11 @@
},
"nixpkgs-master": {
"locked": {
- "lastModified": 1735211307,
- "narHash": "sha256-k25wxtTjH7dGEKQDfQKOfls39uHnWvwS4v1OxC0Bgms=",
+ "lastModified": 1736192377,
+ "narHash": "sha256-Vjg5Ft+JcUcQtclcaC/muSuBQOnP8SsCIpC3W5uaYPA=",
"owner": "nixos",
"repo": "nixpkgs",
- "rev": "91e1b771ee9589ad41401266fe71dce355879681",
+ "rev": "a8af4a1033a3ab6d14d37731512ecd8bbf39c2b9",
"type": "github"
},
"original": {
@@ -423,11 +517,11 @@
},
"nixpkgs-stable": {
"locked": {
- "lastModified": 1734991663,
- "narHash": "sha256-8T660guvdaOD+2/Cj970bWlQwAyZLKrrbkhYOFcY1YE=",
+ "lastModified": 1736061677,
+ "narHash": "sha256-DjkQPnkAfd7eB522PwnkGhOMuT9QVCZspDpJJYyOj60=",
"owner": "nixos",
"repo": "nixpkgs",
- "rev": "6c90912761c43e22b6fb000025ab96dd31c971ff",
+ "rev": "cbd8ec4de4469333c82ff40d057350c30e9f7d36",
"type": "github"
},
"original": {
@@ -439,16 +533,32 @@
},
"nixpkgs_2": {
"locked": {
- "lastModified": 1732238832,
- "narHash": "sha256-sQxuJm8rHY20xq6Ah+GwIUkF95tWjGRd1X8xF+Pkk38=",
+ "lastModified": 1736012469,
+ "narHash": "sha256-/qlNWm/IEVVH7GfgAIyP6EsVZI6zjAx1cV5zNyrs+rI=",
+ "owner": "nixos",
+ "repo": "nixpkgs",
+ "rev": "8f3e1f807051e32d8c95cd12b9b421623850a34d",
+ "type": "github"
+ },
+ "original": {
+ "owner": "nixos",
+ "ref": "nixos-unstable",
+ "repo": "nixpkgs",
+ "type": "github"
+ }
+ },
+ "nixpkgs_3": {
+ "locked": {
+ "lastModified": 1735648875,
+ "narHash": "sha256-fQ4k/hyQiH9RRPznztsA9kbcDajvwV1sRm01el6Sr3c=",
"owner": "NixOS",
"repo": "nixpkgs",
- "rev": "8edf06bea5bcbee082df1b7369ff973b91618b8d",
+ "rev": "47e29c20abef74c45322eca25ca1550cdf5c3b50",
"type": "github"
},
"original": {
"owner": "NixOS",
- "ref": "nixpkgs-unstable",
+ "ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
@@ -468,11 +578,11 @@
"treefmt-nix": "treefmt-nix"
},
"locked": {
- "lastModified": 1735169833,
- "narHash": "sha256-Wu201kM5vgOUhhwkKuYSZmmTMflgBybqeEIzIH4MRY4=",
+ "lastModified": 1736157655,
+ "narHash": "sha256-/ggXMK8Q/rN94kaaSHPtEcf4SPKgPXfzSbDgAR6Odzs=",
"owner": "nix-community",
"repo": "nixvim",
- "rev": "25c13524642cb7fe98583a5dd5f90992c76198b9",
+ "rev": "31139e0605fd886d981e0a197e30ceac4b859d6e",
"type": "github"
},
"original": {
@@ -491,11 +601,11 @@
]
},
"locked": {
- "lastModified": 1733773348,
- "narHash": "sha256-Y47y+LesOCkJaLvj+dI/Oa6FAKj/T9sKVKDXLNsViPw=",
+ "lastModified": 1735854821,
+ "narHash": "sha256-Iv59gMDZajNfezTO0Fw6LHE7uKAShxbvMidmZREit7c=",
"owner": "NuschtOS",
"repo": "search",
- "rev": "3051be7f403bff1d1d380e4612f0c70675b44fc9",
+ "rev": "836908e3bddd837ae0f13e215dd48767aee355f0",
"type": "github"
},
"original": {
@@ -507,7 +617,8 @@
"root": {
"inputs": {
"home-manager": "home-manager",
- "nixpkgs": "nixpkgs",
+ "hyprland-qtutils": "hyprland-qtutils",
+ "nixpkgs": "nixpkgs_2",
"nixpkgs-master": "nixpkgs-master",
"nixpkgs-stable": "nixpkgs-stable",
"nixvim": "nixvim",
@@ -523,11 +634,11 @@
]
},
"locked": {
- "lastModified": 1735186564,
- "narHash": "sha256-PQIAL/dODi9HroSaW/4nqWQe2CSTgxRYS+XiYPo1FhA=",
+ "lastModified": 1736136999,
+ "narHash": "sha256-bI3pSXx4fihlWNi4b8+Kp04RkDhctEgGdJuNQw/2O88=",
"owner": "Gerg-L",
"repo": "spicetify-nix",
- "rev": "112da8f6b8a3365cf89d5c5b6aaa02ba249373ff",
+ "rev": "046dc4cc0bcf460cafbfd3fe26fdc584f5b0fb80",
"type": "github"
},
"original": {
@@ -544,20 +655,22 @@
"base16-vim": "base16-vim",
"flake-compat": "flake-compat_3",
"flake-utils": "flake-utils_2",
+ "git-hooks": "git-hooks_2",
"gnome-shell": "gnome-shell",
"home-manager": "home-manager_3",
- "nixpkgs": "nixpkgs_2",
- "systems": "systems_2",
+ "nixpkgs": "nixpkgs_3",
+ "systems": "systems_3",
"tinted-foot": "tinted-foot",
"tinted-kitty": "tinted-kitty",
- "tinted-tmux": "tinted-tmux"
+ "tinted-tmux": "tinted-tmux",
+ "tinted-zed": "tinted-zed"
},
"locked": {
- "lastModified": 1735151068,
- "narHash": "sha256-sJ1/y4aXAZ22trJjY+nH/bJ+pydaDKf3wZtafM+Yjcs=",
+ "lastModified": 1736179037,
+ "narHash": "sha256-uhLRE3x5TrFeQm1waBz6ecqa2EHilFM4jLxYbOJPGrU=",
"owner": "danth",
"repo": "stylix",
- "rev": "079fecebad5f616561726359c89cedd811c8a722",
+ "rev": "a6b53aa677ab9bd9098abbdc47924854c76c3eb1",
"type": "github"
},
"original": {
@@ -568,6 +681,21 @@
},
"systems": {
"locked": {
+ "lastModified": 1689347949,
+ "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=",
+ "owner": "nix-systems",
+ "repo": "default-linux",
+ "rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68",
+ "type": "github"
+ },
+ "original": {
+ "owner": "nix-systems",
+ "repo": "default-linux",
+ "type": "github"
+ }
+ },
+ "systems_2": {
+ "locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
@@ -581,7 +709,7 @@
"type": "github"
}
},
- "systems_2": {
+ "systems_3": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
@@ -646,6 +774,22 @@
"type": "github"
}
},
+ "tinted-zed": {
+ "flake": false,
+ "locked": {
+ "lastModified": 1725758778,
+ "narHash": "sha256-8P1b6mJWyYcu36WRlSVbuj575QWIFZALZMTg5ID/sM4=",
+ "owner": "tinted-theming",
+ "repo": "base16-zed",
+ "rev": "122c9e5c0e6f27211361a04fae92df97940eccf9",
+ "type": "github"
+ },
+ "original": {
+ "owner": "tinted-theming",
+ "repo": "base16-zed",
+ "type": "github"
+ }
+ },
"treefmt-nix": {
"inputs": {
"nixpkgs": [
@@ -654,11 +798,11 @@
]
},
"locked": {
- "lastModified": 1734704479,
- "narHash": "sha256-MMi74+WckoyEWBRcg/oaGRvXC9BVVxDZNRMpL+72wBI=",
+ "lastModified": 1736115332,
+ "narHash": "sha256-FBG9d7e0BTFfxVdw4b5EmNll2Mv7hfRc54hbB4LrKko=",
"owner": "numtide",
"repo": "treefmt-nix",
- "rev": "65712f5af67234dad91a5a4baee986a8b62dbf8f",
+ "rev": "1788ca5acd4b542b923d4757d4cfe4183cc6a92d",
"type": "github"
},
"original": {
diff --git a/flake.nix b/flake.nix
index dcc6fce..43c2c20 100644
--- a/flake.nix
+++ b/flake.nix
@@ -16,57 +16,60 @@
inputs.nixpkgs.follows = "nixpkgs";
};
/*
- lix-module = {
+ lix-module = {
url =
"https://git.lix.systems/lix-project/nixos-module/archive/2.91.0.tar.gz";
inputs.nixpkgs.follows = "nixpkgs";
- };
+ };
*/
- stylix = {url = "github:danth/stylix";};
+ stylix = { url = "github:danth/stylix"; };
spicetify-nix = {
url = "github:Gerg-L/spicetify-nix";
inputs.nixpkgs.follows = "nixpkgs";
};
+ hyprland-qtutils.url = "github:hyprwm/hyprland-qtutils";
};
- outputs = {
- self,
- nixpkgs,
- home-manager,
- stylix,
- spicetify-nix,
- ...
- } @ inputs: let
- inherit (self) outputs;
- myHostName = "nixos-msi";
- stevenUserName = "stvnliu";
- in {
- # NixOS configuration entrypoint
- # Available through 'nixos-rebuild --flake .#your-hostname'
- nixosConfigurations = {
- "${myHostName}" = nixpkgs.lib.nixosSystem {
- specialArgs = {inherit inputs outputs;};
- modules = [
- ./nixos/configuration.nix
- #lix-module.nixosModules.default
- ];
+ outputs =
+ { self
+ , nixpkgs
+ , home-manager
+ , stylix
+ , spicetify-nix
+ , ...
+ } @ inputs:
+ let
+ inherit (self) outputs;
+ myHostName = "nixos-msi";
+ stevenUserName = "stvnliu";
+ in
+ {
+ # NixOS configuration entrypoint
+ # Available through 'nixos-rebuild --flake .#your-hostname'
+ nixosConfigurations = {
+ "${myHostName}" = nixpkgs.lib.nixosSystem {
+ specialArgs = { inherit inputs outputs; };
+ modules = [
+ ./nixos/configuration.nix
+ #lix-module.nixosModules.default
+ ];
+ };
};
- };
- # Standalone home-manager configuration entrypoint
- # Available through 'home-manager --flake .#your-username@your-hostname'
- homeConfigurations = {
- "${stevenUserName}@${myHostName}" = home-manager.lib.homeManagerConfiguration {
- pkgs =
- nixpkgs.legacyPackages.x86_64-linux; # Home-manager requires 'pkgs' instance
- extraSpecialArgs = {inherit inputs outputs;};
- modules = [
- ./home-manager/${stevenUserName}/home.nix
- inputs.nixvim.homeManagerModules.nixvim
- stylix.homeManagerModules.stylix
- spicetify-nix.homeManagerModules.default
- ];
+ # Standalone home-manager configuration entrypoint
+ # Available through 'home-manager --flake .#your-username@your-hostname'
+ homeConfigurations = {
+ "${stevenUserName}@${myHostName}" = home-manager.lib.homeManagerConfiguration {
+ pkgs =
+ nixpkgs.legacyPackages.x86_64-linux; # Home-manager requires 'pkgs' instance
+ extraSpecialArgs = { inherit inputs outputs; };
+ modules = [
+ ./home-manager/${stevenUserName}/home.nix
+ stylix.homeManagerModules.stylix
+ inputs.nixvim.homeManagerModules.nixvim
+ spicetify-nix.homeManagerModules.default
+ ];
+ };
};
};
- };
}
diff --git a/home-manager/stvnliu/ags/config/hyprworkspaces.js b/home-manager/stvnliu/ags/config/hyprworkspaces.js
index a1c4af8..270a410 100644
--- a/home-manager/stvnliu/ags/config/hyprworkspaces.js
+++ b/home-manager/stvnliu/ags/config/hyprworkspaces.js
@@ -1,7 +1,7 @@
const hyprland = await Service.import("hyprland")
const dispatch = ws => hyprland.messageAsync(`dispatch workspace ${ws}`);
-const wsSymbols = ["1", "2", "3", "4", "5", "6", "7", "8", "9", "10"]
+const wsSymbols = ["1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20"]
const Workspaces = () => Widget.EventBox({
onScrollUp: () => dispatch('+1'),
onScrollDown: () => dispatch('-1'),
diff --git a/home-manager/stvnliu/ags/config/mpris.js b/home-manager/stvnliu/ags/config/mpris.js
new file mode 100644
index 0000000..b096a84
--- /dev/null
+++ b/home-manager/stvnliu/ags/config/mpris.js
@@ -0,0 +1,17 @@
+const mpris = await Service.import('mpris')
+
+/**
+ * @param {import('types/service/mpris').MprisPlayer} player
+ * */
+const Player = (player, count) => Widget.Button({
+ onClicked: () => player.playPause(),
+ child: Widget.Label().hook(player, label => {
+ const { track_artists, track_title } = player;
+ label.label = `${count} PLAYING`;
+ }),
+})
+
+export const players = Widget.Box({
+ children: mpris.bind('players').as(p => p.map(
+ (this_player, index, array) => { return Player(this_player, array.length) }))
+})
diff --git a/home-manager/stvnliu/ags/default.nix b/home-manager/stvnliu/ags/default.nix
index 96833fb..6518235 100644
--- a/home-manager/stvnliu/ags/default.nix
+++ b/home-manager/stvnliu/ags/default.nix
@@ -1,7 +1,6 @@
-{
- pkgs,
- config,
- ...
+{ pkgs
+, config
+, ...
}: {
config = {
home.file = {
diff --git a/home-manager/stvnliu/devenv.nix b/home-manager/stvnliu/devenv.nix
index 74d0241..928a18b 100644
--- a/home-manager/stvnliu/devenv.nix
+++ b/home-manager/stvnliu/devenv.nix
@@ -1,7 +1,5 @@
-{
- pkgs,
- config,
- lib,
- ...
-}: {
-}
+{ pkgs
+, config
+, lib
+, ...
+}: { }
diff --git a/home-manager/stvnliu/editors.nix b/home-manager/stvnliu/editors.nix
index f548076..ce5aca7 100644
--- a/home-manager/stvnliu/editors.nix
+++ b/home-manager/stvnliu/editors.nix
@@ -1,8 +1,7 @@
-{
- lib,
- pkgs,
- config,
- ...
+{ lib
+, pkgs
+, config
+, ...
}: {
imports = [
#./vscode.nix
@@ -10,9 +9,14 @@
];
programs.nixvim = import ./nixvim;
# dependencies for nixvim configuration
- home.packages = with pkgs; [ripgrep fd];
- programs.vscode = {
+ home.packages = with pkgs; [ ripgrep fd ];
+ programs.helix = {
enable = true;
- package = pkgs.vscode.fhs;
};
+ /*
+ programs.vscode = {
+ enable = true;
+ package = pkgs.vscode.fhs;
+ };
+ */
}
diff --git a/home-manager/stvnliu/gtk.nix b/home-manager/stvnliu/gtk.nix
index 9e38baa..31f3f5b 100644
--- a/home-manager/stvnliu/gtk.nix
+++ b/home-manager/stvnliu/gtk.nix
@@ -1,7 +1,6 @@
-{
- pkgs,
- config,
- ...
+{ pkgs
+, config
+, ...
}: {
gtk = {
enable = true;
@@ -13,6 +12,6 @@
qt = {
enable = true;
platformTheme.name = "gtk";
- style = {name = "Fusion";};
+ style = { name = "Fusion"; };
};
}
diff --git a/home-manager/stvnliu/home.nix b/home-manager/stvnliu/home.nix
index e17cc16..654c770 100644
--- a/home-manager/stvnliu/home.nix
+++ b/home-manager/stvnliu/home.nix
@@ -1,9 +1,8 @@
-{
- inputs,
- lib,
- config,
- pkgs,
- ...
+{ inputs
+, lib
+, config
+, pkgs
+, ...
}: {
imports = [
./hypr
@@ -29,7 +28,7 @@
overlays = [
(final: prev: {
ags = prev.ags.overrideAttrs (old: {
- buildInputs = old.buildInputs ++ [pkgs.libdbusmenu-gtk3];
+ buildInputs = old.buildInputs ++ [ pkgs.libdbusmenu-gtk3 ];
});
})
];
@@ -52,7 +51,7 @@
username = "${config.myUserName}";
homeDirectory = "/home/${config.myUserName}";
# copy wallpaper from assets
- file = {"wallpaper.jpg".source = config.myWallPaperPath;};
+ file = { "wallpaper.jpg".source = config.myWallPaperPath; };
};
home.packages = with pkgs; [
prismlauncher
@@ -70,6 +69,7 @@
teams-for-linux
sxiv
heroic
+ vscodium-fhs
];
myAutostartCommands = [
#"${pkgs.clash-verge-rev}/bin/clash-verge"
@@ -78,7 +78,7 @@
programs = {
obs-studio = {
enable = true;
- plugins = with pkgs.obs-studio-plugins; [wlrobs input-overlay];
+ plugins = with pkgs.obs-studio-plugins; [ wlrobs input-overlay ];
};
home-manager.enable = true;
firefox = {
@@ -97,7 +97,7 @@
};
thunderbird = {
enable = true;
- profiles.default = {isDefault = true;};
+ profiles.default = { isDefault = true; };
};
};
# Nicely reload system units when changing configs
diff --git a/home-manager/stvnliu/hypr/default.nix b/home-manager/stvnliu/hypr/default.nix
index bb8c931..e2ebf96 100644
--- a/home-manager/stvnliu/hypr/default.nix
+++ b/home-manager/stvnliu/hypr/default.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
imports = [
./hyprland
diff --git a/home-manager/stvnliu/hypr/hypridle.nix b/home-manager/stvnliu/hypr/hypridle.nix
index 5439a41..acbcde9 100644
--- a/home-manager/stvnliu/hypr/hypridle.nix
+++ b/home-manager/stvnliu/hypr/hypridle.nix
@@ -1,6 +1,8 @@
-{pkgs, ...}: let
+{ pkgs, ... }:
+let
timeoutSeconds = 600;
-in {
+in
+{
services.hypridle = {
enable = true;
settings = {
diff --git a/home-manager/stvnliu/hypr/hyprland/binds.nix b/home-manager/stvnliu/hypr/hyprland/binds.nix
index dd46cbb..0325faa 100644
--- a/home-manager/stvnliu/hypr/hyprland/binds.nix
+++ b/home-manager/stvnliu/hypr/hyprland/binds.nix
@@ -1,61 +1,75 @@
-{
- config,
- pkgs,
- lib,
- ...
-}: let
- terminalCmd = "${pkgs.foot}/bin/footclient";
+{ config
+, pkgs
+, ...
+}:
+let
+ terminalCmd = config.defaultApplications.terminal;
screenshotLocation = "/home/${config.myUserName}/Screenshots/$(date '+%Y-%m-%d-%H-%M-%S').png";
in
- [
- "$mod SHIFT, L, exec, ${pkgs.wlogout}/bin/wlogout"
+[
+ "$mod SHIFT, L, exec, ${pkgs.wlogout}/bin/wlogout"
- "$mod SHIFT, Print, exec, ${pkgs.grimblast}/bin/grimblast copysave output ${screenshotLocation}"
- ", Print, exec, ${pkgs.grimblast}/bin/grimblast copysave area ${screenshotLocation}"
- "$mod, Print, exec, ${pkgs.grimblast}/bin/grimblast copy area"
+ "$mod SHIFT, Print, exec, ${pkgs.grimblast}/bin/grimblast copysave output ${screenshotLocation}"
+ ", Print, exec, ${pkgs.grimblast}/bin/grimblast copysave area ${screenshotLocation}"
+ "$mod, Print, exec, ${pkgs.grimblast}/bin/grimblast copy area"
- # special workspace keybinds
- "$mod, S, togglespecialworkspace"
- "$mod SHIFT, S, movetoworkspace, special"
+ # special workspace keybinds
+ "$mod, S, togglespecialworkspace"
+ "$mod SHIFT, S, movetoworkspace, special"
- # keysyms for util functions
- # Example volume button that allows press and hold, volume limited to 150%
- "$mod, Q, killactive"
- "$mod, D, exec, ${pkgs.fuzzel}/bin/fuzzel"
- "$mod, F, fullscreen"
- "$mod, E, exec, ${config.defaultApplications.fileManager}"
- # foot terminal
- "$mod, Return, exec, ${terminalCmd} ${config.myShells.defaultShell}"
- "$mod SHIFT, Return, exec, [float] ${terminalCmd} ${config.myShells.defaultShell}"
+ # keysyms for util functions
+ # Example volume button that allows press and hold, volume limited to 150%
+ "$mod, Q, killactive"
+ "$mod, D, exec, ${config.defaultApplications.appLauncher}"
+ "$mod, F, fullscreen"
+ "$mod, E, exec, ${config.defaultApplications.fileManager}"
+ # foot terminal
+ "$mod, Return, exec, ${terminalCmd} ${config.myShells.defaultShell}"
+ "$mod SHIFT, Return, exec, [float] ${terminalCmd} ${config.myShells.defaultShell}"
- # cmdline utilities
- /*
+ # cmdline utilities
+ /*
NOTE Replaced by network manager applet
nmtui interface is no longer needed
TODO Fix floating window rule
*/
- # "$mod, N, exec, [float] ${terminalCmd} ${pkgs.networkmanager}/bin/nmtui"
- "$mod, M, exec, [float] ${terminalCmd} ${pkgs.zenith}/bin/zenith"
+ # "$mod, N, exec, [float] ${terminalCmd} ${pkgs.networkmanager}/bin/nmtui"
+ #"$mod, M, exec, [float] ${terminalCmd} ${pkgs.zenith}/bin/zenith"
- # vimkeys navigation
- "$mod, H, movefocus, l"
- "$mod, J, movefocus, d"
- "$mod, K, movefocus, u"
- "$mod, L, movefocus, r"
- ]
- ++ (
- if config.services.swaync.enable
- then ["$mod, N, exec, ${pkgs.swaynotificationcenter}/bin/swaync-client -t"]
- else []
- )
- ++ (
- # workspaces
- # binds $mod + [shift +] {1..10} to [move to] workspace {1..10}
- builtins.concatLists (builtins.genList (x: let
+ # vimkeys navigation
+ "$mod, H, movefocus, l"
+ "$mod, J, movefocus, d"
+ "$mod, K, movefocus, u"
+ "$mod, L, movefocus, r"
+]
+++ (
+ if config.services.mpd.enable then [ "$mod, M, exec, ${terminalCmd} --title=ncmpc ${pkgs.ncmpc}/bin/ncmpc -h 127.0.0.1" ] else [ ]
+)
+++ (
+ if config.services.swaync.enable
+ then [ "$mod, N, exec, ${pkgs.swaynotificationcenter}/bin/swaync-client -t" ]
+ else [ ]
+)
+++ (
+ # workspaces
+ # binds $mod + [shift +] {1..10} to [move to] workspace {1..10}
+ builtins.concatLists (builtins.genList
+ (x:
+ let
ws = let c = (x + 1) / 10; in builtins.toString (x + 1 - (c * 10));
- in [
+ in
+ [
"$mod, ${ws}, workspace, ${toString (x + 1)}"
"$mod SHIFT, ${ws}, movetoworkspace, ${toString (x + 1)}"
- ])
- 10)
- )
+ ]) 10)
+ # workspaces
+ # binds $mod + [shift +] {1..10} to [move to] workspace {1..10}
+ /*
+ builtins.concatLists (builtins.genList (x:
+ let ws = let c = (x + 1) / 10; in builtins.toString (x + 1 - (c * 10));
+ in [
+ "$mod M, ${ws}, workspace, ${toString (x + 10 + 1)}"
+ "$mod SHIFT M, ${ws}, movetoworkspace, ${toString (x + 10 + 1)}"
+ ]) 10)
+ */
+)
diff --git a/home-manager/stvnliu/hypr/hyprland/default.nix b/home-manager/stvnliu/hypr/hyprland/default.nix
index c4bd966..bb3c3e6 100644
--- a/home-manager/stvnliu/hypr/hyprland/default.nix
+++ b/home-manager/stvnliu/hypr/hyprland/default.nix
@@ -1,23 +1,21 @@
-{
- config,
- pkgs,
- lib,
- ...
-}: {
- home.packages = with pkgs; [foot];
+{ inputs, config, pkgs, lib, ... }: {
+ home.packages =
+ [ inputs.hyprland-qtutils.packages.x86_64-linux.default pkgs.foot ];
wayland.windowManager.hyprland = {
# Whether to enable Hyprland wayland compositor
enable = true;
# The hyprland package to use
package = pkgs.hyprland;
- plugins = with pkgs.hyprlandPlugins; [
- # hyprfocus
- ];
+ plugins = with pkgs.hyprlandPlugins;
+ [
+ # hyprfocus
+ # hycov
+ ];
# Whether to enable XWayland
xwayland.enable = true;
settings = {
- env = ["AQ_DRM_DEVICES, /dev/dri/card1:/dev/dri/card0"];
- xwayland = {force_zero_scaling = true;};
+ env = [ "AQ_DRM_DEVICES, /dev/dri/card1:/dev/dri/card0" ];
+ xwayland = { force_zero_scaling = true; };
monitor = [
#"eDP-1, 1920x1080@165,0x0,1"
"desc:Xiaomi Corporation Mi 27 NFGL 3215000032603, 1920x1080@75, 2560x0, 1"
@@ -32,8 +30,8 @@
gaps_out = 5;
allow_tearing = true;
};
- windowrulev2 = ["immediate, class:^(cs2)$"];
- decoration = {rounding = 5;};
+ windowrulev2 = import ./window_rules.nix;
+ decoration = { rounding = 5; };
input = {
# xset rate 250 50 replacement on wayland...
# FAST MODE LET'S GOOO
@@ -41,13 +39,10 @@
repeat_delay = 250;
accel_profile = "flat";
};
- exec-once =
- config.myAutostartCommands
- ++ [
- # future hyprland-specific exec commands
- "${config.programs.firefox.package}/bin/firefox"
- "${pkgs.thunderbird}/bin/thunderbird"
- ];
+ exec-once = config.myAutostartCommands ++ import ./hypr_autostart.nix {
+ inherit pkgs;
+ inherit config;
+ };
misc = {
disable_hyprland_logo = true;
disable_splash_rendering = true;
@@ -73,7 +68,7 @@
};
# Optional
# Whether to enable hyprland-session.target on hyprland startup
- systemd = {enable = true;};
+ systemd = { enable = true; };
};
# ...
}
diff --git a/home-manager/stvnliu/hypr/hyprland/hypr_autostart.nix b/home-manager/stvnliu/hypr/hyprland/hypr_autostart.nix
new file mode 100644
index 0000000..f245efa
--- /dev/null
+++ b/home-manager/stvnliu/hypr/hyprland/hypr_autostart.nix
@@ -0,0 +1,8 @@
+{ pkgs, config }:
+let
+ term = config.defaultApplications.terminal;
+ shell = config.myShells.defaultShell;
+in
+[
+ "${term} --title=autorun ${shell}"
+]
diff --git a/home-manager/stvnliu/hypr/hyprland/window_rules.nix b/home-manager/stvnliu/hypr/hyprland/window_rules.nix
new file mode 100644
index 0000000..b09a597
--- /dev/null
+++ b/home-manager/stvnliu/hypr/hyprland/window_rules.nix
@@ -0,0 +1,7 @@
+[
+ "workspace special silent, class:^(foot.*)$, title:autorun"
+ "float, tag:floats"
+ "float, title:ncmpc"
+ "size 50% 50%, title:ncmpc"
+ "immediate, class:^(cs2)$"
+]
diff --git a/home-manager/stvnliu/hypr/hyprland/xf86_binds.nix b/home-manager/stvnliu/hypr/hyprland/xf86_binds.nix
index 215a4a8..eed6ff6 100644
--- a/home-manager/stvnliu/hypr/hyprland/xf86_binds.nix
+++ b/home-manager/stvnliu/hypr/hyprland/xf86_binds.nix
@@ -1,6 +1,6 @@
-{
- pkgs,
- config,
+{ pkgs
+, config
+,
}: [
", XF86AudioPlay, exec, ${pkgs.playerctl}/bin/playerctl play-pause"
", XF86AudioStop, exec, ${pkgs.playerctl}/bin/playerctl stop"
diff --git a/home-manager/stvnliu/hypr/hyprlock.nix b/home-manager/stvnliu/hypr/hyprlock.nix
index 99529f3..9901cba 100644
--- a/home-manager/stvnliu/hypr/hyprlock.nix
+++ b/home-manager/stvnliu/hypr/hyprlock.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
programs.hyprlock = {
enable = true;
diff --git a/home-manager/stvnliu/hypr/hyprpaper.nix b/home-manager/stvnliu/hypr/hyprpaper.nix
index 8266871..81140a1 100644
--- a/home-manager/stvnliu/hypr/hyprpaper.nix
+++ b/home-manager/stvnliu/hypr/hyprpaper.nix
@@ -1,15 +1,14 @@
-{
- pkgs,
- config,
- ...
+{ pkgs
+, config
+, ...
}: {
services.hyprpaper = {
enable = true;
settings = {
ipc = "on";
splash = false;
- preload = [config.myWallPaperPathString];
- wallpaper = [",${config.myWallPaperPathString}"];
+ preload = [ config.myWallPaperPathString ];
+ wallpaper = [ ",${config.myWallPaperPathString}" ];
#preload = [/home/stvnliu/Downloads/mao-zedong.jpg];
#wallpaper = [",/home/stvnliu/Downloads/mao-zedong.jpg"];
};
diff --git a/home-manager/stvnliu/mako.nix b/home-manager/stvnliu/mako.nix
index 5b22460..69bbe5c 100644
--- a/home-manager/stvnliu/mako.nix
+++ b/home-manager/stvnliu/mako.nix
@@ -1,10 +1,11 @@
-{
- pkgs,
- lib,
- ...
-}: let
+{ pkgs
+, lib
+, ...
+}:
+let
defaultTimeoutMillis = 5 * 1000;
-in {
+in
+{
services.mako = {
enable = true;
defaultTimeout = defaultTimeoutMillis;
diff --git a/home-manager/stvnliu/nixvim/auto-pairs.nix b/home-manager/stvnliu/nixvim/auto-pairs.nix
index c57a48b..f8a479c 100644
--- a/home-manager/stvnliu/nixvim/auto-pairs.nix
+++ b/home-manager/stvnliu/nixvim/auto-pairs.nix
@@ -1 +1 @@
-{plugins.nvim-autopairs = {enable = true;};}
+{ plugins.nvim-autopairs = { enable = true; }; }
diff --git a/home-manager/stvnliu/nixvim/bufferline.nix b/home-manager/stvnliu/nixvim/bufferline.nix
index 628aaa6..9039f66 100644
--- a/home-manager/stvnliu/nixvim/bufferline.nix
+++ b/home-manager/stvnliu/nixvim/bufferline.nix
@@ -1 +1 @@
-{plugins.bufferline = {enable = true;};}
+{ plugins.bufferline = { enable = true; }; }
diff --git a/home-manager/stvnliu/nixvim/cmp.nix b/home-manager/stvnliu/nixvim/cmp.nix
index 5c91e90..260de1f 100644
--- a/home-manager/stvnliu/nixvim/cmp.nix
+++ b/home-manager/stvnliu/nixvim/cmp.nix
@@ -3,28 +3,28 @@
plugins = {
luasnip.enable = true;
/*
- copilot-lua = {
+ copilot-lua = {
enable = true;
suggestion.enabled = false;
panel.enabled = false;
- };
+ };
*/
cmp = {
enable = true;
settings = {
autoEnableSources = true;
- experimental = {ghost_text = false;};
+ experimental = { ghost_text = false; };
performance = {
debounce = 60;
fetchingTimeout = 200;
maxViewEntries = 30;
};
- snippet = {expand = "luasnip";};
- cmp-buffer = {enable = true;};
- cmp-emoji = {enable = true;};
- cmp-nvim-lsp = {enable = true;};
- cmp-path = {enable = true;};
- cmp_luasnip = {enable = true;};
+ snippet = { expand = "luasnip"; };
+ cmp-buffer = { enable = true; };
+ cmp-emoji = { enable = true; };
+ cmp-nvim-lsp = { enable = true; };
+ cmp-path = { enable = true; };
+ cmp_luasnip = { enable = true; };
/*
snippet.expand = ''
@@ -34,17 +34,17 @@
'';
*/
sources = [
- {name = "nvim_lsp";}
- {name = "luasnip";}
+ { name = "nvim_lsp"; }
+ { name = "luasnip"; }
{
name = "buffer";
option.get_bufnrs.__raw = "vim.api.nvim_list_bufs";
}
- {name = "nvim_lua";}
- {name = "path";}
+ { name = "nvim_lua"; }
+ { name = "path"; }
];
formatting = {
- fields = ["abbr" "kind" "menu"];
+ fields = [ "abbr" "kind" "menu" ];
format =
# lua
''
@@ -104,11 +104,11 @@
winhighlight = "FloatBorder:CmpBorder,Normal:CmpPmenu,CursorLine:CmpSel,Search:PmenuSel";
scrollbar = false;
sidePadding = 0;
- border = ["╭" "─" "╮" "│" "╯" "─" "╰" "│"];
+ border = [ "╭" "─" "╮" "│" "╯" "─" "╰" "│" ];
};
settings.documentation = {
- border = ["╭" "─" "╮" "│" "╯" "─" "╰" "│"];
+ border = [ "╭" "─" "╮" "│" "╯" "─" "╰" "│" ];
winhighlight = "FloatBorder:CmpBorder,Normal:CmpPmenu,CursorLine:CmpSel,Search:PmenuSel";
};
};
diff --git a/home-manager/stvnliu/nixvim/default.nix b/home-manager/stvnliu/nixvim/default.nix
index f865f09..33cf395 100644
--- a/home-manager/stvnliu/nixvim/default.nix
+++ b/home-manager/stvnliu/nixvim/default.nix
@@ -1,4 +1,4 @@
-{config, ...}: {
+{ config, ... }: {
imports = [
./auto-pairs.nix
./autosave.nix
@@ -26,7 +26,7 @@
enableMan = true;
defaultEditor = true;
globals.mapleader = " ";
- colorschemes.gruvbox = {enable = true;};
+ colorschemes.gruvbox = { enable = true; };
keymaps =
[
# Global
diff --git a/home-manager/stvnliu/nixvim/ionide.nix b/home-manager/stvnliu/nixvim/ionide.nix
index db3d3fc..3de2422 100644
--- a/home-manager/stvnliu/nixvim/ionide.nix
+++ b/home-manager/stvnliu/nixvim/ionide.nix
@@ -1,4 +1,4 @@
-{pkgs, ...}: {
+{ pkgs, ... }: {
extraPlugins = with pkgs.vimPlugins; [
Ionide-vim
];
diff --git a/home-manager/stvnliu/nixvim/lsp.nix b/home-manager/stvnliu/nixvim/lsp.nix
index 675dbf9..201aab1 100644
--- a/home-manager/stvnliu/nixvim/lsp.nix
+++ b/home-manager/stvnliu/nixvim/lsp.nix
@@ -1,4 +1,4 @@
-{...}: {
+{ ... }: {
plugins = {
lsp-signature.enable = true;
lsp-status.enable = true;
diff --git a/home-manager/stvnliu/nixvim/telescope.nix b/home-manager/stvnliu/nixvim/telescope.nix
index 989ff58..95e672f 100644
--- a/home-manager/stvnliu/nixvim/telescope.nix
+++ b/home-manager/stvnliu/nixvim/telescope.nix
@@ -10,6 +10,6 @@
};
};
};
- extensions.fzf-native = {enable = true;};
+ extensions.fzf-native = { enable = true; };
};
}
diff --git a/home-manager/stvnliu/nixvim/transparent.nix b/home-manager/stvnliu/nixvim/transparent.nix
index f81c39b..b392fb8 100644
--- a/home-manager/stvnliu/nixvim/transparent.nix
+++ b/home-manager/stvnliu/nixvim/transparent.nix
@@ -1 +1 @@
-{plugins.transparent.enable = true;}
+{ plugins.transparent.enable = true; }
diff --git a/home-manager/stvnliu/nixvim/treesitter.nix b/home-manager/stvnliu/nixvim/treesitter.nix
index 7a360c6..9105918 100644
--- a/home-manager/stvnliu/nixvim/treesitter.nix
+++ b/home-manager/stvnliu/nixvim/treesitter.nix
@@ -1,4 +1,4 @@
-{pkgs, ...}: {
+{ pkgs, ... }: {
plugins = {
treesitter = {
enable = true;
diff --git a/home-manager/stvnliu/nixvim/virt-column.nix b/home-manager/stvnliu/nixvim/virt-column.nix
index 0daf880..ef15de2 100644
--- a/home-manager/stvnliu/nixvim/virt-column.nix
+++ b/home-manager/stvnliu/nixvim/virt-column.nix
@@ -1,7 +1,7 @@
{
plugins.virt-column = {
enable = true;
- settings.char = ["┃"];
+ settings.char = [ "┃" ];
settings.virtcolumn = "80";
};
}
diff --git a/home-manager/stvnliu/nixvim/which_key.nix b/home-manager/stvnliu/nixvim/which_key.nix
index 1b73707..bf4f909 100644
--- a/home-manager/stvnliu/nixvim/which_key.nix
+++ b/home-manager/stvnliu/nixvim/which_key.nix
@@ -1 +1 @@
-{plugins.which-key = {enable = true;};}
+{ plugins.which-key = { enable = true; }; }
diff --git a/home-manager/stvnliu/nixvim/wilder.nix b/home-manager/stvnliu/nixvim/wilder.nix
index 84d2a31..1cca351 100644
--- a/home-manager/stvnliu/nixvim/wilder.nix
+++ b/home-manager/stvnliu/nixvim/wilder.nix
@@ -1,6 +1,6 @@
{
plugins.wilder = {
enable = true;
- modes = [":" "/" "?"];
+ modes = [ ":" "/" "?" ];
};
}
diff --git a/home-manager/stvnliu/packages/default.nix b/home-manager/stvnliu/packages/default.nix
index 9063c20..71fb0d8 100644
--- a/home-manager/stvnliu/packages/default.nix
+++ b/home-manager/stvnliu/packages/default.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
imports = [
./util-programs.nix
@@ -11,5 +10,6 @@
./wayland-utils.nix
./pentesting.nix
./dev.nix
+ ./gaming.nix
];
}
diff --git a/home-manager/stvnliu/packages/dev.nix b/home-manager/stvnliu/packages/dev.nix
index e1e91ff..cbf8d4d 100644
--- a/home-manager/stvnliu/packages/dev.nix
+++ b/home-manager/stvnliu/packages/dev.nix
@@ -1,7 +1,6 @@
-{
- pkgs,
- config,
- ...
+{ pkgs
+, config
+, ...
}: {
home.packages = with pkgs; [
wget
diff --git a/home-manager/stvnliu/packages/discord.nix b/home-manager/stvnliu/packages/discord.nix
index 90fff5a..cd89efb 100644
--- a/home-manager/stvnliu/packages/discord.nix
+++ b/home-manager/stvnliu/packages/discord.nix
@@ -1,14 +1,13 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
- home.packages = with pkgs; [vesktop];
+ home.packages = with pkgs; [ vesktop ];
xdg.desktopEntries.discord = {
exec = "${pkgs.vesktop}/bin/vesktop";
terminal = false;
- mimeType = ["x-scheme-handler/discord"];
+ mimeType = [ "x-scheme-handler/discord" ];
name = "Discord - Vesktop";
genericName = "Discord but substituted with Vesktop";
type = "Application";
diff --git a/home-manager/stvnliu/packages/gaming.nix b/home-manager/stvnliu/packages/gaming.nix
new file mode 100644
index 0000000..9d95d6f
--- /dev/null
+++ b/home-manager/stvnliu/packages/gaming.nix
@@ -0,0 +1,4 @@
+{ pkgs, config, ... }:
+{
+ home.packages = with pkgs; [ bottles ];
+}
diff --git a/home-manager/stvnliu/packages/office-programs.nix b/home-manager/stvnliu/packages/office-programs.nix
index c34d033..4b52405 100644
--- a/home-manager/stvnliu/packages/office-programs.nix
+++ b/home-manager/stvnliu/packages/office-programs.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
home.packages = with pkgs; [
libreoffice
diff --git a/home-manager/stvnliu/packages/pentesting.nix b/home-manager/stvnliu/packages/pentesting.nix
index 81bfd41..0a3ba0b 100644
--- a/home-manager/stvnliu/packages/pentesting.nix
+++ b/home-manager/stvnliu/packages/pentesting.nix
@@ -1,7 +1,6 @@
-{
- pkgs,
- config,
- ...
+{ pkgs
+, config
+, ...
}: {
home.packages = with pkgs; [
openvpn
diff --git a/home-manager/stvnliu/packages/util-programs.nix b/home-manager/stvnliu/packages/util-programs.nix
index caf3138..bd8c9ac 100644
--- a/home-manager/stvnliu/packages/util-programs.nix
+++ b/home-manager/stvnliu/packages/util-programs.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
home.packages = with pkgs; [
bottom
diff --git a/home-manager/stvnliu/packages/vscodium.nix b/home-manager/stvnliu/packages/vscodium.nix
new file mode 100644
index 0000000..3ea5951
--- /dev/null
+++ b/home-manager/stvnliu/packages/vscodium.nix
@@ -0,0 +1,4 @@
+{ pkgs, config, ... }: {
+ home.packages = with pkgs; [ vscodium-fhs ];
+ xdg.desktopEntries.codium = { };
+}
diff --git a/home-manager/stvnliu/packages/wayland-utils.nix b/home-manager/stvnliu/packages/wayland-utils.nix
index 6d47482..dfc526d 100644
--- a/home-manager/stvnliu/packages/wayland-utils.nix
+++ b/home-manager/stvnliu/packages/wayland-utils.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
- home.packages = with pkgs; [wl-clipboard];
+ home.packages = with pkgs; [ wl-clipboard ];
}
diff --git a/home-manager/stvnliu/programs/default.nix b/home-manager/stvnliu/programs/default.nix
index 6451c71..1e62067 100644
--- a/home-manager/stvnliu/programs/default.nix
+++ b/home-manager/stvnliu/programs/default.nix
@@ -1,13 +1,13 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
imports = [
./git.nix
./rofi.nix
./tmux.nix
./foot.nix
+ #./walker.nix
];
}
diff --git a/home-manager/stvnliu/programs/foot.nix b/home-manager/stvnliu/programs/foot.nix
index ae5188e..136d53b 100644
--- a/home-manager/stvnliu/programs/foot.nix
+++ b/home-manager/stvnliu/programs/foot.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
programs.foot = {
enable = true;
@@ -11,7 +10,7 @@
term = "xterm-256color";
dpi-aware = lib.mkForce "yes";
};
- mouse = {hide-when-typing = "yes";};
+ mouse = { hide-when-typing = "yes"; };
};
server.enable = true;
};
diff --git a/home-manager/stvnliu/programs/git.nix b/home-manager/stvnliu/programs/git.nix
index 6690fb1..e7bd955 100644
--- a/home-manager/stvnliu/programs/git.nix
+++ b/home-manager/stvnliu/programs/git.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
programs.git = {
enable = true;
diff --git a/home-manager/stvnliu/programs/rofi.nix b/home-manager/stvnliu/programs/rofi.nix
index b0731a3..6d73636 100644
--- a/home-manager/stvnliu/programs/rofi.nix
+++ b/home-manager/stvnliu/programs/rofi.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
programs.rofi = {
enable = true;
diff --git a/home-manager/stvnliu/programs/tmux.nix b/home-manager/stvnliu/programs/tmux.nix
index 8522af8..5e407d0 100644
--- a/home-manager/stvnliu/programs/tmux.nix
+++ b/home-manager/stvnliu/programs/tmux.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
programs.tmux = {
enable = true;
diff --git a/home-manager/stvnliu/programs/walker.nix b/home-manager/stvnliu/programs/walker.nix
new file mode 100644
index 0000000..e6dc416
--- /dev/null
+++ b/home-manager/stvnliu/programs/walker.nix
@@ -0,0 +1,19 @@
+{ pkgs
+, config
+, ...
+}: {
+ programs.walker = {
+ enable = true;
+ runAsService = true;
+
+ # All options from the config.json can be used here.
+ config = {
+ search.placeholder = "Example";
+ list = { height = 200; };
+ websearch.prefix = "?";
+ switcher.prefix = "/";
+ };
+
+ # If this is not set the default styling is used.
+ };
+}
diff --git a/home-manager/stvnliu/scripts/default.nix b/home-manager/stvnliu/scripts/default.nix
index ff6f091..4096c43 100644
--- a/home-manager/stvnliu/scripts/default.nix
+++ b/home-manager/stvnliu/scripts/default.nix
@@ -1,10 +1,9 @@
-{
- config,
- pkgs,
- ...
+{ config
+, pkgs
+, ...
}: {
home.packages = [
- (import ./heic-to-jpg.script.nix {inherit pkgs;})
+ (import ./heic-to-jpg.script.nix { inherit pkgs; })
(import ./tmux-default.script.nix {
inherit pkgs;
inherit config;
diff --git a/home-manager/stvnliu/scripts/git-check.script.nix b/home-manager/stvnliu/scripts/git-check.script.nix
index fa1d3c3..82120bc 100644
--- a/home-manager/stvnliu/scripts/git-check.script.nix
+++ b/home-manager/stvnliu/scripts/git-check.script.nix
@@ -1,54 +1,55 @@
-{
- pkgs,
- config,
-}: let
+{ pkgs
+, config
+,
+}:
+let
git = config.programs.git.package;
# checks for any Git repositories with uncommitted changes
# used because I am too lazy
in
- pkgs.writeShellScriptBin "git-check" ''
- #!${pkgs.bash}/bin/bash
- cd_err() {
- echo "change-directory occurred error. interrupting..."
- }
- git_check() {
- prev=$1
- repo_dir=$2
- #echo "Checking git-cleanliness at $repo_dir, working in $PWD"
- cd "$repo_dir" || return
- inside_git_repo="$(${git}/bin/git rev-parse --is-inside-work-tree 2>/dev/null)"
- result=256
- default_skip=false
- if [ "$inside_git_repo" ]; then
- if [ "$(${git}/bin/git status --porcelain)" ]; then
- result=0
- else
- result=1
- fi
- #echo "not a git repository"
+pkgs.writeShellScriptBin "git-check" ''
+ #!${pkgs.bash}/bin/bash
+ cd_err() {
+ echo "change-directory occurred error. interrupting..."
+ }
+ git_check() {
+ prev=$1
+ repo_dir=$2
+ #echo "Checking git-cleanliness at $repo_dir, working in $PWD"
+ cd "$repo_dir" || return
+ inside_git_repo="$(${git}/bin/git rev-parse --is-inside-work-tree 2>/dev/null)"
+ result=256
+ default_skip=false
+ if [ "$inside_git_repo" ]; then
+ if [ "$(${git}/bin/git status --porcelain)" ]; then
+ result=0
+ else
+ result=1
+ fi
+ #echo "not a git repository"
+ fi
+ if [[ $result -eq 0 ]]; then
+ echo "DIRTY $PWD"
+ if $default_skip; then return; fi
+ read -rp "Enter dirty directory? [y/n/N(skip others)] " userinput
+ if [[ "$userinput" = "y" ]]; then
+ $SHELL
fi
- if [[ $result -eq 0 ]]; then
- echo "DIRTY $PWD"
- if $default_skip; then return; fi
- read -rp "Enter dirty directory? [y/n/N(skip others)] " userinput
- if [[ "$userinput" = "y" ]]; then
- $SHELL
- fi
- if [[ "$userinput" = "N" ]]; then
- default_skip=true
- fi
+ if [[ "$userinput" = "N" ]]; then
+ default_skip=true
fi
- #echo "going back to $prev"
- cd "$prev" || return
- }
- path=$PWD
- scan_path=$PWD
- if [ -z "$1" ]; then
- scan_path=$PWD
- else
- scan_path=$1
fi
- for item in $(find $scan_path -maxdepth 1 -type d); do
- git_check "$path" "$item"
- done
- ''
+ #echo "going back to $prev"
+ cd "$prev" || return
+ }
+ path=$PWD
+ scan_path=$PWD
+ if [ -z "$1" ]; then
+ scan_path=$PWD
+ else
+ scan_path=$1
+ fi
+ for item in $(find $scan_path -maxdepth 1 -type d); do
+ git_check "$path" "$item"
+ done
+''
diff --git a/home-manager/stvnliu/scripts/heic-to-jpg.script.nix b/home-manager/stvnliu/scripts/heic-to-jpg.script.nix
index c247474..a4a4ab8 100644
--- a/home-manager/stvnliu/scripts/heic-to-jpg.script.nix
+++ b/home-manager/stvnliu/scripts/heic-to-jpg.script.nix
@@ -1,4 +1,4 @@
-{pkgs}:
+{ pkgs }:
pkgs.writeShellScriptBin "heic-to-jpg" ''
mkdir -p ./heic-to-jpg-out
${pkgs.findutils}/bin/find . -type f -print0 | ${pkgs.findutils}/bin/xargs -0 -I "{}" ${pkgs.imagemagick}/bin/magick "{}" -quality 100% ./jpg-out/"{}.conv.jpg"
diff --git a/home-manager/stvnliu/scripts/tmux-default.script.nix b/home-manager/stvnliu/scripts/tmux-default.script.nix
index 8641d90..7f28493 100644
--- a/home-manager/stvnliu/scripts/tmux-default.script.nix
+++ b/home-manager/stvnliu/scripts/tmux-default.script.nix
@@ -1,18 +1,19 @@
-{
- pkgs,
- config,
-}: let
+{ pkgs
+, config
+,
+}:
+let
tmux = config.programs.tmux.package;
windowName = "code-mode";
in
- pkgs.writeShellScriptBin "tmux-code" ''
- #!${pkgs.bash}/bin/bash
- ${tmux}/bin/tmux has-session -t ${windowName} 2>/dev/null
- if [ $? != 0 ]; then
- # setting up session
- ${tmux}/bin/tmux new -s ${windowName} -d
- ${tmux}/bin/tmux send-keys -t ${windowName} 'nvim' Enter
- ${tmux}/bin/tmux split-window -h
- fi
- ${tmux}/bin/tmux attach -t ${windowName}
- ''
+pkgs.writeShellScriptBin "tmux-code" ''
+ #!${pkgs.bash}/bin/bash
+ ${tmux}/bin/tmux has-session -t ${windowName} 2>/dev/null
+ if [ $? != 0 ]; then
+ # setting up session
+ ${tmux}/bin/tmux new -s ${windowName} -d
+ ${tmux}/bin/tmux send-keys -t ${windowName} 'nvim' Enter
+ ${tmux}/bin/tmux split-window -h
+ fi
+ ${tmux}/bin/tmux attach -t ${windowName}
+''
diff --git a/home-manager/stvnliu/services/default.nix b/home-manager/stvnliu/services/default.nix
index c7801d9..32ae334 100644
--- a/home-manager/stvnliu/services/default.nix
+++ b/home-manager/stvnliu/services/default.nix
@@ -1,9 +1,9 @@
-{
- pkgs,
- config,
- ...
+{ pkgs
+, config
+, ...
}: {
imports = [
./swaync.nix
+ ./mpd.nix
];
}
diff --git a/home-manager/stvnliu/services/mpd.nix b/home-manager/stvnliu/services/mpd.nix
new file mode 100644
index 0000000..23e38e0
--- /dev/null
+++ b/home-manager/stvnliu/services/mpd.nix
@@ -0,0 +1,29 @@
+{ pkgs, config, lib, ... }:
+lib.mkIf config.usingMusicPlayerDaemon {
+ home.packages = [ pkgs.ncmpc ];
+ services.mpd = {
+ enable = true;
+ network.listenAddress = "any";
+ network.port = 6600;
+ extraConfig = ''
+ audio_output {
+ type "pipewire"
+ name "my pipewire output"
+ }
+ audio_output {
+ type "httpd"
+ name "My HTTP Stream"
+ encoder "vorbis" # optional, vorbis or lame
+ port "8000"
+ # bind_to_address "0.0.0.0" # optional, IPv4 or IPv6
+ quality "5.0" # do not define if bitrate is defined
+ # bitrate "128" # do not define if quality is defined
+ format "44100:16:1"
+ max_clients "5" # optional 0=no limit
+ }
+ '';
+ };
+ services.mpd-mpris = {
+ enable = true;
+ };
+}
diff --git a/home-manager/stvnliu/services/swaync.nix b/home-manager/stvnliu/services/swaync.nix
index 2a5d5bc..3feef00 100644
--- a/home-manager/stvnliu/services/swaync.nix
+++ b/home-manager/stvnliu/services/swaync.nix
@@ -1,7 +1,6 @@
-{
- pkgs,
- config,
- ...
+{ pkgs
+, config
+, ...
}: {
services.swaync = {
enable = true;
diff --git a/home-manager/stvnliu/shells/aliases/default.nix b/home-manager/stvnliu/shells/aliases/default.nix
index dde4dff..1159a90 100644
--- a/home-manager/stvnliu/shells/aliases/default.nix
+++ b/home-manager/stvnliu/shells/aliases/default.nix
@@ -1,4 +1,4 @@
-{pkgs}: {
+{ pkgs }: {
gil = "${pkgs.lazygit}/bin/lazygit";
cd = "z";
cdi = "zi";
diff --git a/home-manager/stvnliu/shells/default.nix b/home-manager/stvnliu/shells/default.nix
index d28a526..304ee9b 100644
--- a/home-manager/stvnliu/shells/default.nix
+++ b/home-manager/stvnliu/shells/default.nix
@@ -1,32 +1,32 @@
-{
- pkgs,
- lib,
- config,
- ...
-}: let
+{ pkgs
+, lib
+, config
+, ...
+}:
+let
cfg = config.myShells;
in
- with lib; {
- imports = [
- ./zsh.nix
- ./fish
- ./nushell
- ./zoxide.nix
- ./direnv.nix
- ./starship
- ];
+with lib; {
+ imports = [
+ ./zsh.nix
+ ./fish
+ ./nushell
+ ./zoxide.nix
+ ./direnv.nix
+ ./starship
+ ];
- options.myShells = {
- defaultShell = with types; mkOption {type = str;};
- enable = mkEnableOption "Enables the shell customisation module.";
+ options.myShells = {
+ defaultShell = with types; mkOption { type = str; };
+ enable = mkEnableOption "Enables the shell customisation module.";
+ };
+ config = {
+ myShells = {
+ zsh.enable = false;
+ fish.enable = true;
+ #nushell.enable = true;
+ defaultShell = "${config.programs.fish.package}/bin/fish";
+ prompts.starship.enable = true;
};
- config = {
- myShells = {
- zsh.enable = false;
- fish.enable = true;
- #nushell.enable = true;
- defaultShell = "${config.programs.fish.package}/bin/fish";
- prompts.starship.enable = true;
- };
- };
- }
+ };
+}
diff --git a/home-manager/stvnliu/shells/direnv.nix b/home-manager/stvnliu/shells/direnv.nix
index 6124695..e0fdc47 100644
--- a/home-manager/stvnliu/shells/direnv.nix
+++ b/home-manager/stvnliu/shells/direnv.nix
@@ -1,4 +1,4 @@
-{config, ...}: {
+{ config, ... }: {
programs = {
direnv = {
enable = true;
diff --git a/home-manager/stvnliu/shells/env/default.nix b/home-manager/stvnliu/shells/env/default.nix
index 9f2ab73..7900d1c 100644
--- a/home-manager/stvnliu/shells/env/default.nix
+++ b/home-manager/stvnliu/shells/env/default.nix
@@ -1,7 +1,6 @@
-{
- pkgs,
- config,
- ...
+{ pkgs
+, config
+, ...
}: {
EDITOR = "nvim";
}
diff --git a/home-manager/stvnliu/shells/fish/default.nix b/home-manager/stvnliu/shells/fish/default.nix
index e06fe00..4ea1d96 100644
--- a/home-manager/stvnliu/shells/fish/default.nix
+++ b/home-manager/stvnliu/shells/fish/default.nix
@@ -1,65 +1,65 @@
-{
- pkgs,
- config,
- lib,
- ...
-}: let
+{ pkgs
+, config
+, lib
+, ...
+}:
+let
cfg = config.myShells.fish;
in
- with lib; {
- options = {
- myShells.fish = {enable = mkEnableOption "Enables fish and components.";};
- };
- config = mkIf cfg.enable {
- programs.fish = {
- enable = true;
- shellInit = ''
- ${builtins.readFile ./init/zoxide.fish}
- ${builtins.readFile ./init/nh.fish}
- ${builtins.readFile ./init/tailscale.fish}
- ${builtins.readFile ./init/pass.fish}
- function fish_greeting
- ${(pkgs.fortune.override {withOffensive = true;})}/bin/fortune -as
- end
- funcsave -q fish_greeting
+with lib; {
+ options = {
+ myShells.fish = { enable = mkEnableOption "Enables fish and components."; };
+ };
+ config = mkIf cfg.enable {
+ programs.fish = {
+ enable = true;
+ shellInit = ''
+ ${builtins.readFile ./init/zoxide.fish}
+ ${builtins.readFile ./init/nh.fish}
+ ${builtins.readFile ./init/tailscale.fish}
+ ${builtins.readFile ./init/pass.fish}
+ function fish_greeting
+ ${(pkgs.fortune.override {withOffensive = true;})}/bin/fortune -as
+ end
+ funcsave -q fish_greeting
- ${pkgs.thefuck}/bin/thefuck --alias | source
- '';
- shellAliases = import ../aliases {inherit pkgs;};
- plugins = with pkgs.fishPlugins; [
- {
- name = "z";
- src = z.src;
- }
- {
- name = "plugin-git";
- src = plugin-git.src;
- }
- {
- name = "transient-fish";
- src = transient-fish.src;
- }
- {
- name = "done";
- src = done.src;
- }
- {
- name = "gruvbox";
- src = gruvbox.src;
- }
- {
- name = "colored-man-pages";
- src = colored-man-pages.src;
- }
- {
- name = "puffer";
- src = puffer.src;
- }
- {
- name = "pisces";
- src = pisces.src;
- }
- ];
- };
+ ${pkgs.thefuck}/bin/thefuck --alias | source
+ '';
+ shellAliases = import ../aliases { inherit pkgs; };
+ plugins = with pkgs.fishPlugins; [
+ {
+ name = "z";
+ src = z.src;
+ }
+ {
+ name = "plugin-git";
+ src = plugin-git.src;
+ }
+ {
+ name = "transient-fish";
+ src = transient-fish.src;
+ }
+ {
+ name = "done";
+ src = done.src;
+ }
+ {
+ name = "gruvbox";
+ src = gruvbox.src;
+ }
+ {
+ name = "colored-man-pages";
+ src = colored-man-pages.src;
+ }
+ {
+ name = "puffer";
+ src = puffer.src;
+ }
+ {
+ name = "pisces";
+ src = pisces.src;
+ }
+ ];
};
- }
+ };
+}
diff --git a/home-manager/stvnliu/shells/nushell/default.nix b/home-manager/stvnliu/shells/nushell/default.nix
index 059c68a..0b048e0 100644
--- a/home-manager/stvnliu/shells/nushell/default.nix
+++ b/home-manager/stvnliu/shells/nushell/default.nix
@@ -1,26 +1,26 @@
-{
- pkgs,
- config,
- lib,
- ...
-}: let
+{ pkgs
+, config
+, lib
+, ...
+}:
+let
cfg = config.myShells.nushell;
in
- with lib; {
- options = {
- myShells.nushell = {enable = mkEnableOption "Enables nushell config";};
- };
- config = mkIf cfg.enable {
- programs = {
- nushell = {
- enable = true;
- configFile.source = ./init/config.nu;
- shellAliases = import ../aliases/default.nix {inherit pkgs;};
- };
- carapace = {
- enable = true;
- enableNushellIntegration = true;
- };
+with lib; {
+ options = {
+ myShells.nushell = { enable = mkEnableOption "Enables nushell config"; };
+ };
+ config = mkIf cfg.enable {
+ programs = {
+ nushell = {
+ enable = true;
+ configFile.source = ./init/config.nu;
+ shellAliases = import ../aliases/default.nix { inherit pkgs; };
+ };
+ carapace = {
+ enable = true;
+ enableNushellIntegration = true;
};
};
- }
+ };
+}
diff --git a/home-manager/stvnliu/shells/starship/default.nix b/home-manager/stvnliu/shells/starship/default.nix
index 3cf3aed..3231dc3 100644
--- a/home-manager/stvnliu/shells/starship/default.nix
+++ b/home-manager/stvnliu/shells/starship/default.nix
@@ -1,27 +1,27 @@
-{
- lib,
- pkgs,
- config,
- ...
-}: let
+{ lib
+, pkgs
+, config
+, ...
+}:
+let
cfg = config.myShells.prompts.starship;
in
- with lib; {
- options = {
- myShells.prompts.starship.enable = mkEnableOption "Enables starship prompts.";
- myShells.prompts.starship.confPath = mkOption {
- type = types.path;
- default = ./presets/default.toml;
- };
+with lib; {
+ options = {
+ myShells.prompts.starship.enable = mkEnableOption "Enables starship prompts.";
+ myShells.prompts.starship.confPath = mkOption {
+ type = types.path;
+ default = ./presets/default.toml;
};
- config = mkIf cfg.enable {
- myShells.prompts.starship.confPath = ./presets/pure-direnv.toml;
- programs.starship = {
- enable = true;
- enableZshIntegration = config.myShells.zsh.enable;
- enableFishIntegration = config.myShells.fish.enable;
- enableNushellIntegration = config.myShells.nushell.enable;
- settings = builtins.fromTOML (builtins.readFile cfg.confPath);
- };
+ };
+ config = mkIf cfg.enable {
+ myShells.prompts.starship.confPath = ./presets/pure-direnv.toml;
+ programs.starship = {
+ enable = true;
+ enableZshIntegration = config.myShells.zsh.enable;
+ enableFishIntegration = config.myShells.fish.enable;
+ enableNushellIntegration = config.myShells.nushell.enable;
+ settings = builtins.fromTOML (builtins.readFile cfg.confPath);
};
- }
+ };
+}
diff --git a/home-manager/stvnliu/shells/zoxide.nix b/home-manager/stvnliu/shells/zoxide.nix
index 9f33410..a9f7300 100644
--- a/home-manager/stvnliu/shells/zoxide.nix
+++ b/home-manager/stvnliu/shells/zoxide.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
programs.zoxide = {
enable = true;
diff --git a/home-manager/stvnliu/shells/zsh.nix b/home-manager/stvnliu/shells/zsh.nix
index c329684..9dded59 100644
--- a/home-manager/stvnliu/shells/zsh.nix
+++ b/home-manager/stvnliu/shells/zsh.nix
@@ -1,36 +1,36 @@
-{
- pkgs,
- lib,
- config,
- ...
-}: let
+{ pkgs
+, lib
+, config
+, ...
+}:
+let
cfg = config.shell.zsh;
in
- with lib; {
- options.myShells.zsh = {
- enable = mkEnableOption "Enables zsh and components.";
- };
- config = {
- programs.zsh = {
+with lib; {
+ options.myShells.zsh = {
+ enable = mkEnableOption "Enables zsh and components.";
+ };
+ config = {
+ programs.zsh = {
+ enable = true;
+ syntaxHighlighting.enable = true;
+ shellAliases = import ./aliases { inherit pkgs; };
+ dirHashes = {
+ docs = "$HOME/Documents";
+ dl = "$HOME/Downloads";
+ dev = "$HOME/devel";
+ screen = "$HOME/Pictures/Screenshots";
+ };
+ oh-my-zsh = {
enable = true;
- syntaxHighlighting.enable = true;
- shellAliases = import ./aliases {inherit pkgs;};
- dirHashes = {
- docs = "$HOME/Documents";
- dl = "$HOME/Downloads";
- dev = "$HOME/devel";
- screen = "$HOME/Pictures/Screenshots";
- };
- oh-my-zsh = {
- enable = true;
- plugins = [
- "git"
- "rsync"
- "zoxide"
- ];
- theme = "agnoster";
- };
+ plugins = [
+ "git"
+ "rsync"
+ "zoxide"
+ ];
+ theme = "agnoster";
};
- home.packages = with pkgs; [zoxide];
};
- }
+ home.packages = with pkgs; [ zoxide ];
+ };
+}
diff --git a/home-manager/stvnliu/spicetify.nix b/home-manager/stvnliu/spicetify.nix
index e21389c..620b0c0 100644
--- a/home-manager/stvnliu/spicetify.nix
+++ b/home-manager/stvnliu/spicetify.nix
@@ -1,11 +1,12 @@
-{
- pkgs,
- lib,
- inputs,
- ...
-}: let
+{ pkgs
+, lib
+, inputs
+, ...
+}:
+let
spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.system};
-in {
+in
+{
# allow spotify to be installed if you don't have unfree enabled already
nixpkgs.config.allowUnfreePredicate = pkg:
builtins.elem (lib.getName pkg) [
diff --git a/home-manager/stvnliu/stylix.nix b/home-manager/stvnliu/stylix.nix
index 6f5a796..a33a96a 100644
--- a/home-manager/stvnliu/stylix.nix
+++ b/home-manager/stvnliu/stylix.nix
@@ -1,10 +1,11 @@
-{
- pkgs,
- config,
- ...
-}: let
+{ pkgs
+, config
+, ...
+}:
+let
globalOpacity = 0.75;
-in {
+in
+{
stylix = {
enable = true;
autoEnable = true;
diff --git a/home-manager/stvnliu/wechat/default.nix b/home-manager/stvnliu/wechat/default.nix
index c0126db..0362926 100644
--- a/home-manager/stvnliu/wechat/default.nix
+++ b/home-manager/stvnliu/wechat/default.nix
@@ -1,4 +1,4 @@
-{pkgs, ...}: {
+{ pkgs, ... }: {
nixpkgs.config.permittedInsecurePackages = [
"openssl-1.1.1w"
];
diff --git a/home-manager/stvnliu/wechat/license.tar.gz b/home-manager/stvnliu/wechat/license.tar.gz
deleted file mode 100644
index fcef1de..0000000
--- a/home-manager/stvnliu/wechat/license.tar.gz
+++ /dev/null
Binary files differ
diff --git a/home-manager/stvnliu/xdg.nix b/home-manager/stvnliu/xdg.nix
index 2899822..72c8fee 100644
--- a/home-manager/stvnliu/xdg.nix
+++ b/home-manager/stvnliu/xdg.nix
@@ -1,6 +1,7 @@
-{pkgs, ...}: {
+{ pkgs, ... }: {
xdg = {
enable = true;
+ userDirs.enable = true;
mimeApps = {
enable = true;
defaultApplications = {
diff --git a/nixos/ags.nix b/nixos/ags.nix
index 036fee1..e1f8b28 100644
--- a/nixos/ags.nix
+++ b/nixos/ags.nix
@@ -1,4 +1,4 @@
-{pkgs, ...}: {
+{ pkgs, ... }: {
environment.systemPackages = [
pkgs.ags
];
diff --git a/nixos/bootloader.nix b/nixos/bootloader.nix
index e18e85e..00691b2 100644
--- a/nixos/bootloader.nix
+++ b/nixos/bootloader.nix
@@ -1,8 +1,8 @@
-{
- config,
- pkgs,
- ...
-}: let
+{ config
+, pkgs
+, ...
+}:
+let
distro-grub-themes = pkgs.stdenv.mkDerivation {
pname = "distro-grub-themes";
version = "3.1";
@@ -25,8 +25,9 @@
};
installPhase = "cp -r xenlism-grub-1080p-nixos/Xenlism-Nixos $out";
};
-in {
- environment.systemPackages = with pkgs; [hack-font];
+in
+{
+ environment.systemPackages = with pkgs; [ hack-font ];
#fileSystems."/mnt/winsys" = {
# device = "/dev/nvme0n1p5";
# fsType = "ntfs-3g";
@@ -43,7 +44,7 @@ in {
theme = "rings";
themePackages = with pkgs; [
# By default we would install all themes
- (adi1090x-plymouth-themes.override {selected_themes = ["rings"];})
+ (adi1090x-plymouth-themes.override { selected_themes = [ "rings" ]; })
];
};
@@ -62,16 +63,16 @@ in {
# Hide the OS choice for bootloaders.
# It's still possible to open the bootloader list by pressing any key
# It will just not appear on screen unless a key is pressed
- supportedFilesystems = ["ntfs"];
+ supportedFilesystems = [ "ntfs" ];
loader = {
#timeout = 0;
- efi = {canTouchEfiVariables = true;};
+ efi = { canTouchEfiVariables = true; };
grub = {
enable = true;
efiSupport = true;
device = "nodev";
fsIdentifier = "label";
- devices = ["nodev"];
+ devices = [ "nodev" ];
extraConfig = ''
function load_video {
if [ x$feature_all_video_module = xy ]; then
diff --git a/nixos/configuration.nix b/nixos/configuration.nix
index 7348d2b..8eae995 100644
--- a/nixos/configuration.nix
+++ b/nixos/configuration.nix
@@ -1,16 +1,14 @@
# This is your system's configuration file.
# Use this to configure your system environment (it replaces /etc/nixos/configuration.nix)
-{
- inputs,
- lib,
- config,
- pkgs,
- ...
+{ inputs
+, lib
+, config
+, pkgs
+, ...
}: {
imports = [
../common/variables.nix
./greetd.nix
- #./ly.nix
./bootloader.nix
./nvidia.nix
./fonts.nix
@@ -23,13 +21,14 @@
FLAKE = config.myConfigLocation;
MANPAGER = "nvim +Man!";
NVD_BACKEND = "direct";
+ NIXOS_OZONE_WL = "1";
# GTK_IM_MODULE = lib.mkForce "";
};
services.keyd = {
enable = true;
keyboards = {
default = {
- ids = ["*"];
+ ids = [ "*" ];
settings = {
main = {
capslock = "overload(control, esc)";
@@ -49,7 +48,7 @@
enable = true;
capSysNice = true;
};
- security.pam.services.hyprlock = {};
+ security.pam.services.hyprlock = { };
i18n.inputMethod = {
type = "fcitx5";
enable = true;
@@ -65,7 +64,7 @@
hardware.bluetooth = {
enable = true;
powerOnBoot = true;
- settings = {General = {Disable = "Handsfree,Headset";};};
+ settings = { General = { Disable = "Handsfree,Headset"; }; };
};
specialisation = {
in-china.configuration = {
@@ -77,13 +76,13 @@
};
xdg.portal = {
enable = true;
- extraPortals = with pkgs; [xdg-desktop-portal-gtk];
- config = {common.default = ["gtk"];};
+ extraPortals = with pkgs; [ xdg-desktop-portal-gtk ];
+ config = { common.default = [ "gtk" ]; };
};
systemd.user.services.mpris-proxy = {
description = "Mpris proxy";
- after = ["network.target" "sound.target"];
- wantedBy = ["default.target"];
+ after = [ "network.target" "sound.target" ];
+ wantedBy = [ "default.target" ];
serviceConfig.ExecStart = "${pkgs.bluez}/bin/mpris-proxy";
};
programs = {
@@ -96,13 +95,13 @@
true; # Open ports in the firewall for Source Dedicated Server
localNetworkGameTransfers.openFirewall =
true; # Open ports in the firewall for Steam Local Network Game Transfers
- extraCompatPackages = with pkgs; [proton-ge-bin];
+ extraCompatPackages = with pkgs; [ proton-ge-bin ];
};
gamemode.enable = true;
};
boot = {
kernelPackages = pkgs.linuxPackages_zen;
- supportedFilesystems = ["ntfs"];
+ supportedFilesystems = [ "ntfs" ];
};
documentation = {
enable = true;
@@ -114,7 +113,7 @@
environment.systemPackages = with pkgs; [
man-pages-posix
man-pages
- (pass-wayland.withExtensions (exts: [exts.pass-otp exts.pass-import]))
+ (pass-wayland.withExtensions (exts: [ exts.pass-otp exts.pass-import ]))
gparted
zed-editor
libsForQt5.qt5.qtquickcontrols2
@@ -122,7 +121,7 @@
/*
(blender.override {
cudaSupport = true;
- })
+ })
*/
trash-cli
#inputs.hyprswitch.packages.x86_64-linux.default
@@ -154,28 +153,30 @@
# wrapperFeatures.gtk = true;
#};
nixpkgs = {
- overlays = [];
+ overlays = [ ];
config = {
allowUnfree = true;
- permittedInsecurePackages = ["dotnet-core-combined"];
+ permittedInsecurePackages = [ "dotnet-core-combined" ];
};
};
- nix = let
- flakeInputs = lib.filterAttrs (_: lib.isType "flake") inputs;
- in {
- settings = {
- experimental-features = "nix-command flakes";
- # flake-registry = "";
- nix-path = config.nix.nixPath;
+ nix =
+ let
+ flakeInputs = lib.filterAttrs (_: lib.isType "flake") inputs;
+ in
+ {
+ settings = {
+ experimental-features = "nix-command flakes";
+ # flake-registry = "";
+ nix-path = config.nix.nixPath;
+ };
+ extraOptions = ''
+ trusted-users = root stvnliu
+ '';
+ channel.enable = false;
+ registry = lib.mapAttrs (_: flake: { inherit flake; }) flakeInputs;
+ nixPath = lib.mapAttrsToList (n: _: "${n}=flake:${n}") flakeInputs;
};
- extraOptions = ''
- trusted-users = root stvnliu
- '';
- channel.enable = false;
- registry = lib.mapAttrs (_: flake: {inherit flake;}) flakeInputs;
- nixPath = lib.mapAttrsToList (n: _: "${n}=flake:${n}") flakeInputs;
- };
systemd.network.wait-online.enable = false;
networking = {
@@ -188,15 +189,15 @@
"${config.myUserName}" = {
initialPassword = "stevenpassword";
isNormalUser = true;
- openssh.authorizedKeys.keys = [];
- packages = with pkgs; [nh];
- extraGroups = ["wheel" "input" "networkmanager"];
+ openssh.authorizedKeys.keys = [ ];
+ packages = with pkgs; [ nh ];
+ extraGroups = [ "wheel" "input" "networkmanager" ];
};
"xi_jinping" = {
initialPassword = "bingchilling";
isNormalUser = true;
- packages = with pkgs; [git];
- extraGroups = ["input"];
+ packages = with pkgs; [ git ];
+ extraGroups = [ "input" ];
};
};
# https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion
diff --git a/nixos/custom-hosts.nix b/nixos/custom-hosts.nix
index 942bc4f..954eaf4 100644
--- a/nixos/custom-hosts.nix
+++ b/nixos/custom-hosts.nix
@@ -1,8 +1,7 @@
-{
- config,
- lib,
- pkgs,
- ...
+{ config
+, lib
+, pkgs
+, ...
}: {
networking.extraHosts = ''
# home IP mapping
diff --git a/nixos/fonts.nix b/nixos/fonts.nix
index 2c29f8c..4de6abf 100644
--- a/nixos/fonts.nix
+++ b/nixos/fonts.nix
@@ -1,4 +1,4 @@
-{pkgs, ...}: {
+{ pkgs, ... }: {
fonts.packages = with pkgs;
[
helvetica-neue-lt-std
diff --git a/nixos/greetd.nix b/nixos/greetd.nix
index 212cde7..ae2f3ce 100644
--- a/nixos/greetd.nix
+++ b/nixos/greetd.nix
@@ -1,11 +1,12 @@
-{
- pkgs,
- config,
- lib,
- ...
-}: let
+{ pkgs
+, config
+, lib
+, ...
+}:
+let
tuigreet = "${pkgs.greetd.tuigreet}/bin/tuigreet";
-in {
+in
+{
services.greetd = {
enable = true;
settings = {
diff --git a/nixos/hardware-configuration.nix b/nixos/hardware-configuration.nix
index 020471e..1dc6755 100644
--- a/nixos/hardware-configuration.nix
+++ b/nixos/hardware-configuration.nix
@@ -1,21 +1,20 @@
# 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,
- ...
+{ config
+, lib
+, pkgs
+, modulesPath
+, ...
}: {
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
];
- boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "usbhid"];
- boot.initrd.kernelModules = [];
- boot.kernelModules = ["kvm-amd"];
- boot.extraModulePackages = [];
+ boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "usbhid" ];
+ boot.initrd.kernelModules = [ ];
+ boot.kernelModules = [ "kvm-amd" ];
+ boot.extraModulePackages = [ ];
fileSystems."/" = {
device = "/dev/disk/by-uuid/f9ff609f-6e72-43cf-917c-3bd3fde6c410";
@@ -25,7 +24,7 @@
fileSystems."/boot" = {
device = "/dev/disk/by-uuid/2E4F-3060";
fsType = "vfat";
- options = ["fmask=0022" "dmask=0022"];
+ options = [ "fmask=0022" "dmask=0022" ];
};
fileSystems."/games" = {
@@ -33,7 +32,7 @@
fsType = "ext4";
};
- swapDevices = [];
+ 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
diff --git a/nixos/ly.nix b/nixos/ly.nix
deleted file mode 100644
index 20482d0..0000000
--- a/nixos/ly.nix
+++ /dev/null
@@ -1,9 +0,0 @@
-{
- pkgs,
- config,
- ...
-}: {
- services.displayManager.ly = {
- enable = true;
- };
-}
diff --git a/nixos/nvidia.nix b/nixos/nvidia.nix
index e28d41e..bb2f679 100644
--- a/nixos/nvidia.nix
+++ b/nixos/nvidia.nix
@@ -1,8 +1,7 @@
-{
- config,
- lib,
- pkgs,
- ...
+{ config
+, lib
+, pkgs
+, ...
}: {
specialisation = {
powersave.configuration = {
@@ -15,14 +14,14 @@
};
};
};
- boot.kernelModules = ["nvidia_uvm"];
+ boot.kernelModules = [ "nvidia_uvm" ];
hardware.graphics = {
enable = true;
extraPackages = with pkgs; [
libvdpau-va-gl
];
};
- services.xserver.videoDrivers = ["nvidia"];
+ services.xserver.videoDrivers = [ "nvidia" ];
hardware.nvidia = {
dynamicBoost.enable = true;
prime = {
diff --git a/nixos/sddm-theme.nix b/nixos/sddm-theme.nix
index 463038d..b285337 100644
--- a/nixos/sddm-theme.nix
+++ b/nixos/sddm-theme.nix
@@ -1,4 +1,4 @@
-{pkgs, ...}:
+{ pkgs, ... }:
pkgs.stdenv.mkDerivation {
name = "sddm-theme";
src = pkgs.fetchFromGitHub {
diff --git a/nixos/services/avahi.service.nix b/nixos/services/avahi.service.nix
index 4187309..b0bd53f 100644
--- a/nixos/services/avahi.service.nix
+++ b/nixos/services/avahi.service.nix
@@ -1,4 +1,4 @@
-{...}: {
+{ ... }: {
services.avahi = {
enable = true;
nssmdns4 = true;
diff --git a/nixos/services/laptop.preset.nix b/nixos/services/laptop.preset.nix
index 17f72ae..96e097e 100644
--- a/nixos/services/laptop.preset.nix
+++ b/nixos/services/laptop.preset.nix
@@ -1,4 +1,4 @@
-{...}: {
+{ ... }: {
imports = [
./nginx.service.nix
./pipewire.service.nix
@@ -10,5 +10,6 @@
./power_management.service.nix
./seatd.service.nix
./logind.service.nix
+ #./mpd.service.nix
];
}
diff --git a/nixos/services/logind.service.nix b/nixos/services/logind.service.nix
index 6d54e20..7de7ea0 100644
--- a/nixos/services/logind.service.nix
+++ b/nixos/services/logind.service.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
services.logind.extraConfig = ''
# don't shutdown in short press
diff --git a/nixos/services/misc.service.nix b/nixos/services/misc.service.nix
index 72fcd2c..86f490d 100644
--- a/nixos/services/misc.service.nix
+++ b/nixos/services/misc.service.nix
@@ -1,4 +1,4 @@
-{...}: {
+{ ... }: {
specialisation.powersave.configuration = {
services.auto-cpufreq.enable = true;
};
diff --git a/nixos/services/nginx.service.nix b/nixos/services/nginx.service.nix
index bd8b2ef..53025c3 100644
--- a/nixos/services/nginx.service.nix
+++ b/nixos/services/nginx.service.nix
@@ -1,7 +1,6 @@
-{
- pkgs,
- config,
- ...
+{ pkgs
+, config
+, ...
}: {
services.nginx = {
enable = true;
@@ -15,8 +14,8 @@
'';
};
};
- listenAddresses = ["127.0.0.1" "[::1]"];
+ listenAddresses = [ "127.0.0.1" "[::1]" ];
};
};
- networking.firewall.allowedTCPPorts = [80];
+ networking.firewall.allowedTCPPorts = [ 80 ];
}
diff --git a/nixos/services/pipewire.service.nix b/nixos/services/pipewire.service.nix
index be0cc76..83548a4 100644
--- a/nixos/services/pipewire.service.nix
+++ b/nixos/services/pipewire.service.nix
@@ -1,4 +1,5 @@
-{pkgs, ...}: let
+{ pkgs, ... }:
+let
pw_rnnoise_config = {
"context.modules" = [
{
@@ -13,11 +14,11 @@
"name" = "rnnoise";
"plugin" = "${pkgs.rnnoise-plugin}/lib/ladspa/librnnoise_ladspa.so";
"label" = "noise_suppressor_stereo";
- "control" = {"VAD Threshold (%)" = 50.0;};
+ "control" = { "VAD Threshold (%)" = 50.0; };
}
];
};
- "audio.position" = ["FL" "FR"];
+ "audio.position" = [ "FL" "FR" ];
"capture.props" = {
"node.name" = "effect_input.rnnoise";
"node.passive" = true;
@@ -30,7 +31,8 @@
}
];
};
-in {
+in
+{
services.pipewire = {
enable = true;
alsa = {
@@ -42,33 +44,33 @@ in {
wireplumber.configPackages = [
(pkgs.writeTextDir
"share/wireplumber/wireplumber.conf.d/52-profile-switch.conf" ''
- wireplumber.settings = {
- bluetooth.autoswitch-to-headset-profile = false
- }
+ wireplumber.settings = {
+ bluetooth.autoswitch-to-headset-profile = false
+ }
- monitor.bluez.properties = {
- ## Supported roles: hsp_hs (HSP Headset),
- ## hsp_ag (HSP Audio Gateway),
- ## hfp_hf (HFP Hands-Free),
- ## hfp_ag (HFP Audio Gateway)
- ## a2dp_sink (A2DP Audio Sink)
- ## a2dp_source (A2DP Audio Source)
- ## bap_sink (LE Audio Basic Audio Profile Sink)
- ## bap_source (LE Audio Basic Audio Profile Source)
- ## --
- ## Only enable A2DP here and disable HFP. See note at the top as to why.
- bluez5.roles = [ a2dp_sink a2dp_source ]
- }
- '')
+ monitor.bluez.properties = {
+ ## Supported roles: hsp_hs (HSP Headset),
+ ## hsp_ag (HSP Audio Gateway),
+ ## hfp_hf (HFP Hands-Free),
+ ## hfp_ag (HFP Audio Gateway)
+ ## a2dp_sink (A2DP Audio Sink)
+ ## a2dp_source (A2DP Audio Source)
+ ## bap_sink (LE Audio Basic Audio Profile Sink)
+ ## bap_source (LE Audio Basic Audio Profile Source)
+ ## --
+ ## Only enable A2DP here and disable HFP. See note at the top as to why.
+ bluez5.roles = [ a2dp_sink a2dp_source ]
+ }
+ '')
(pkgs.writeTextDir
"share/wireplumber/bluetooth.lua.d/51-bluez-config.lua" ''
- bluez_monitor.properties = {
- ["bluez5.enable-sbc-xq"] = true,
- ["bluez5.enable-msbc"] = true,
- ["bluez5.enable-hw-volume"] = true,
- ["bluez5.headset-roles"] = "[ hsp_hs hsp_ag hfp_hf hfp_ag ]"
- }
- '')
+ bluez_monitor.properties = {
+ ["bluez5.enable-sbc-xq"] = true,
+ ["bluez5.enable-msbc"] = true,
+ ["bluez5.enable-hw-volume"] = true,
+ ["bluez5.headset-roles"] = "[ hsp_hs hsp_ag hfp_hf hfp_ag ]"
+ }
+ '')
];
#extraConfig.pipewire."99-input-denoising" = pw_rnnoise_config;
};
diff --git a/nixos/services/power_management.service.nix b/nixos/services/power_management.service.nix
index 06d638b..e86d18c 100644
--- a/nixos/services/power_management.service.nix
+++ b/nixos/services/power_management.service.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
services.tlp = {
enable = true;
diff --git a/nixos/services/printing.service.nix b/nixos/services/printing.service.nix
index a89c732..88c01b2 100644
--- a/nixos/services/printing.service.nix
+++ b/nixos/services/printing.service.nix
@@ -1,6 +1,6 @@
-{...}: {
+{ ... }: {
services.printing = {
enable = true;
- drivers = [];
+ drivers = [ ];
};
}
diff --git a/nixos/services/seatd.service.nix b/nixos/services/seatd.service.nix
index 8207217..fe75f90 100644
--- a/nixos/services/seatd.service.nix
+++ b/nixos/services/seatd.service.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
services.seatd = {
enable = true;
diff --git a/nixos/services/syncthing.service.nix b/nixos/services/syncthing.service.nix
index 47015e2..bd53243 100644
--- a/nixos/services/syncthing.service.nix
+++ b/nixos/services/syncthing.service.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- config,
- lib,
- ...
+{ pkgs
+, config
+, lib
+, ...
}: {
services = {
syncthing = {
@@ -12,6 +11,6 @@
configDir = "/home/${config.myUserName}/.config/syncthing";
};
};
- networking.firewall.allowedTCPPorts = [8384 22000];
- networking.firewall.allowedUDPPorts = [22000 21027];
+ networking.firewall.allowedTCPPorts = [ 8384 22000 ];
+ networking.firewall.allowedUDPPorts = [ 22000 21027 ];
}
diff --git a/nixos/services/tailscale.service.nix b/nixos/services/tailscale.service.nix
index d0fbde1..d373aa9 100644
--- a/nixos/services/tailscale.service.nix
+++ b/nixos/services/tailscale.service.nix
@@ -1,7 +1,6 @@
-{
- pkgs,
- config,
- ...
+{ pkgs
+, config
+, ...
}: {
services.tailscale = {
enable = true;
diff --git a/nixos/virtualisation.nix b/nixos/virtualisation.nix
index ccf9fe9..c91d0e2 100644
--- a/nixos/virtualisation.nix
+++ b/nixos/virtualisation.nix
@@ -1,8 +1,7 @@
-{
- pkgs,
- lib,
- config,
- ...
+{ pkgs
+, lib
+, config
+, ...
}: {
virtualisation = {
libvirtd.enable = true;
@@ -13,5 +12,5 @@
#virtualisation.virtualbox.host = {
# enable = true;
#};
- users.users."${config.myUserName}".extraGroups = ["libvirtd"];
+ users.users."${config.myUserName}".extraGroups = [ "libvirtd" ];
}