1

Compare commits

..

1 Commits

Author SHA1 Message Date
7b1ebeeed5 Home: Slightly decrease transparent windows opacity 2025-07-21 14:09:47 +02:00
216 changed files with 2398 additions and 8490 deletions

1
.gitignore vendored
View File

@ -11,4 +11,3 @@ config/neovim/store
home/modules/ags/config/types home/modules/ags/config/types
home/modules/ags/config/tsconfig.json home/modules/ags/config/tsconfig.json
system/modules/agenix/secrets.nix system/modules/agenix/secrets.nix
config/neovim/nvim_bundle

BIN
Btop.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 MiB

After

Width:  |  Height:  |  Size: 2.0 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 MiB

After

Width:  |  Height:  |  Size: 1.9 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 MiB

After

Width:  |  Height:  |  Size: 1.7 MiB

BIN
Niri.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 777 KiB

View File

@ -1,6 +1,6 @@
# NixOS Configuration # NixOS Configuration
Modular NixOS configuration, using Hyprland (yikes) or Niri for a tiling/scrolling desktop. Modular NixOS configuration, using Hyprland for a lightweight desktop.
![](FastFetch.png) ![](FastFetch.png)
@ -10,10 +10,7 @@ Modular NixOS configuration, using Hyprland (yikes) or Niri for a tiling/scrolli
<img src="/Btop.png" width="33%" /> <img src="/Btop.png" width="33%" />
</p> </p>
![](Niri.png)
To install, run `nixos-rebuild` with the `--flake` parameter from the `NixFlake` directory: `nixos-rebuild switch --flake .#nixinator`. To install, run `nixos-rebuild` with the `--flake` parameter from the `NixFlake` directory: `nixos-rebuild switch --flake .#nixinator`.
Alternatively, use `nh os switch` or `nh os boot`.
## NixFlake/system ## NixFlake/system
@ -21,8 +18,7 @@ Contains all the system configurations.
- There is a common configuration used for all systems: `NixFlake/system/default.nix` - There is a common configuration used for all systems: `NixFlake/system/default.nix`
- Every system has its own special configuration: `NixFlake/system/<hostname>/default.nix` - Every system has its own special configuration: `NixFlake/system/<hostname>/default.nix`
- System modules are located in `NixFlake/system/systemmodules` - System modules are located in `NixFlake/system/modules`
- Hosted services are located in `NixFlake/system/services`
When creating a NixOS configuration inside the `NixFlake/flake.nix` the common configuration is imported. When creating a NixOS configuration inside the `NixFlake/flake.nix` the common configuration is imported.
Because the hostname is propagated to the common configuration, it can import the host-specific config by itself. Because the hostname is propagated to the common configuration, it can import the host-specific config by itself.
@ -33,7 +29,7 @@ Contains all the home-manager configurations.
- There is a common configuration for each user: `NixFlake/home/<username>/default.nix` - There is a common configuration for each user: `NixFlake/home/<username>/default.nix`
- There is a configuration for a single system of this user: `NixFlake/home/<username>/<hostname>/default.nix` - There is a configuration for a single system of this user: `NixFlake/home/<username>/<hostname>/default.nix`
- Home-Manager modules are located in `NixFlake/home/homemodules` - Home-Manager modules are located in `NixFlake/home/modules`
When creating a NixOS configuration inside the `NixFlake/flake.nix` the common configuration is imported. When creating a NixOS configuration inside the `NixFlake/flake.nix` the common configuration is imported.
Because the hostname is propagated to the common configuration, it can import the host-specific config by itself. Because the hostname is propagated to the common configuration, it can import the host-specific config by itself.
@ -45,6 +41,6 @@ Each derivation is loaded into `NixFlake/derivations/default.nix`.
## NixFlake/overlays ## NixFlake/overlays
Contains all overlays, e.g. package version overrides. Contains (not at the moment) all overlays.
The `NixFlake/overlays/default.nix` imports all overlays and all derivations. The `NixFlake/overlays/default.nix` imports all of the overlays and all of the derivations.
It is then imported by the top-level `NixFlake/flake.nix`, to make everything available to the system/home configurations. It is then imported by the toplevel `NixFlake/flake.nix`, to make everything available to the system/home configurations.

BIN
Rmpc.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.3 MiB

After

Width:  |  Height:  |  Size: 1.6 MiB

View File

@ -1,555 +0,0 @@
{
"id": "catppuccin",
"name": "Catppuccin",
"version": "1.0.0",
"author": "Avenge Media",
"description": "Soothing pastel theme for the high-spirited",
"dark": {},
"light": {},
"variants": {
"type": "multi",
"defaults": {
"dark": {
"accent": "mauve",
"flavor": "mocha"
},
"light": {
"accent": "mauve",
"flavor": "latte"
}
},
"flavors": [
{
"id": "mocha",
"name": "Mocha",
"dark": {
"surface": "#181825",
"surfaceText": "#cdd6f4",
"surfaceVariant": "#1e1e2e",
"surfaceVariantText": "#a6adc8",
"background": "#1e1e2e",
"backgroundText": "#cdd6f4",
"outline": "#6c7086",
"surfaceContainer": "#1e1e2e",
"surfaceContainerHigh": "#313244",
"surfaceContainerHighest": "#45475a",
"error": "#f38ba8",
"warning": "#fab387",
"info": "#89b4fa"
},
"light": {}
},
{
"id": "macchiato",
"name": "Macchiato",
"dark": {
"surface": "#1e2030",
"surfaceText": "#cad3f5",
"surfaceVariant": "#24273a",
"surfaceVariantText": "#a5adcb",
"background": "#24273a",
"backgroundText": "#cad3f5",
"outline": "#6e738d",
"surfaceContainer": "#24273a",
"surfaceContainerHigh": "#363a4f",
"surfaceContainerHighest": "#494d64",
"error": "#ed8796",
"warning": "#f5a97f",
"info": "#8aadf4"
},
"light": {}
},
{
"id": "frappe",
"name": "Frappé",
"dark": {
"surface": "#292c3c",
"surfaceText": "#c6d0f5",
"surfaceVariant": "#303446",
"surfaceVariantText": "#a5adce",
"background": "#303446",
"backgroundText": "#c6d0f5",
"outline": "#737994",
"surfaceContainer": "#303446",
"surfaceContainerHigh": "#414559",
"surfaceContainerHighest": "#51576d",
"error": "#e78284",
"warning": "#ef9f76",
"info": "#8caaee"
},
"light": {}
},
{
"id": "latte",
"name": "Latte",
"dark": {},
"light": {
"surface": "#e6e9ef",
"surfaceText": "#4c4f69",
"surfaceVariant": "#eff1f5",
"surfaceVariantText": "#6c6f85",
"background": "#eff1f5",
"backgroundText": "#4c4f69",
"outline": "#9ca0b0",
"surfaceContainer": "#e6e9ef",
"surfaceContainerHigh": "#ccd0da",
"surfaceContainerHighest": "#bcc0cc",
"error": "#d20f39",
"warning": "#fe640b",
"info": "#1e66f5"
}
}
],
"accents": [
{
"frappe": {
"primary": "#f2d5cf",
"primaryText": "#303446",
"primaryContainer": "#76534f",
"secondary": "#eebebe",
"surfaceTint": "#3a2f33"
},
"id": "rosewater",
"latte": {
"primary": "#dc8a78",
"primaryText": "#eff1f5",
"primaryContainer": "#f6e7e3",
"secondary": "#dd7878",
"surfaceTint": "#f6e7e3"
},
"macchiato": {
"primary": "#f4dbd6",
"primaryText": "#24273a",
"primaryContainer": "#7a5853",
"secondary": "#f0c6c6",
"surfaceTint": "#3b3035"
},
"mocha": {
"primary": "#f5e0dc",
"primaryText": "#1e1e2e",
"primaryContainer": "#7d5d56",
"secondary": "#f2cdcd",
"surfaceTint": "#3d3237"
},
"name": "Rosewater"
},
{
"frappe": {
"primary": "#eebebe",
"primaryText": "#303446",
"primaryContainer": "#744f52",
"secondary": "#f2d5cf",
"surfaceTint": "#392e31"
},
"id": "flamingo",
"latte": {
"primary": "#dd7878",
"primaryText": "#eff1f5",
"primaryContainer": "#f6e5e5",
"secondary": "#dc8a78",
"surfaceTint": "#f6e5e5"
},
"macchiato": {
"primary": "#f0c6c6",
"primaryText": "#24273a",
"primaryContainer": "#775256",
"secondary": "#f4dbd6",
"surfaceTint": "#3a3033"
},
"mocha": {
"primary": "#f2cdcd",
"primaryText": "#1e1e2e",
"primaryContainer": "#7a555a",
"secondary": "#f5e0dc",
"surfaceTint": "#3c3134"
},
"name": "Flamingo"
},
{
"frappe": {
"primary": "#f4b8e4",
"primaryText": "#303446",
"primaryContainer": "#793d65",
"secondary": "#ca9ee6",
"surfaceTint": "#3c2e37"
},
"id": "pink",
"latte": {
"primary": "#ea76cb",
"primaryText": "#eff1f5",
"primaryContainer": "#f7d7ee",
"secondary": "#8839ef",
"surfaceTint": "#f7d7ee"
},
"macchiato": {
"primary": "#f5bde6",
"primaryText": "#24273a",
"primaryContainer": "#7a3e67",
"secondary": "#c6a0f6",
"surfaceTint": "#3d2f38"
},
"mocha": {
"primary": "#f5c2e7",
"primaryText": "#1e1e2e",
"primaryContainer": "#7a3f69",
"secondary": "#cba6f7",
"surfaceTint": "#3d2f39"
},
"name": "Pink"
},
{
"frappe": {
"primary": "#ca9ee6",
"primaryText": "#303446",
"primaryContainer": "#542f79",
"secondary": "#babbf1",
"surfaceTint": "#33293c"
},
"id": "mauve",
"latte": {
"primary": "#8839ef",
"primaryText": "#eff1f5",
"primaryContainer": "#eadcff",
"secondary": "#7287fd",
"surfaceTint": "#eadcff"
},
"macchiato": {
"primary": "#c6a0f6",
"primaryText": "#24273a",
"primaryContainer": "#532f7d",
"secondary": "#b7bdf8",
"surfaceTint": "#32293e"
},
"mocha": {
"primary": "#cba6f7",
"primaryText": "#1e1e2e",
"primaryContainer": "#55307f",
"secondary": "#b4befe",
"surfaceTint": "#33293f"
},
"name": "Mauve"
},
{
"frappe": {
"primary": "#e78284",
"primaryText": "#303446",
"primaryContainer": "#692233",
"secondary": "#ea999c",
"surfaceTint": "#38272e"
},
"id": "red",
"latte": {
"primary": "#d20f39",
"primaryText": "#eff1f5",
"primaryContainer": "#f6d0d6",
"secondary": "#e64553",
"surfaceTint": "#f6d0d6"
},
"macchiato": {
"primary": "#ed8796",
"primaryText": "#24273a",
"primaryContainer": "#6c2336",
"secondary": "#ee99a0",
"surfaceTint": "#3a2830"
},
"mocha": {
"primary": "#f38ba8",
"primaryText": "#1e1e2e",
"primaryContainer": "#6f2438",
"secondary": "#eba0ac",
"surfaceTint": "#3c2930"
},
"name": "Red"
},
{
"frappe": {
"primary": "#ea999c",
"primaryText": "#303446",
"primaryContainer": "#69333d",
"secondary": "#e78284",
"surfaceTint": "#382a2f"
},
"id": "maroon",
"latte": {
"primary": "#e64553",
"primaryText": "#eff1f5",
"primaryContainer": "#f7d8dc",
"secondary": "#d20f39",
"surfaceTint": "#f7d8dc"
},
"macchiato": {
"primary": "#ee99a0",
"primaryText": "#24273a",
"primaryContainer": "#6b343f",
"secondary": "#ed8796",
"surfaceTint": "#392b30"
},
"mocha": {
"primary": "#eba0ac",
"primaryText": "#1e1e2e",
"primaryContainer": "#6d3641",
"secondary": "#f38ba8",
"surfaceTint": "#3a2c31"
},
"name": "Maroon"
},
{
"frappe": {
"primary": "#ef9f76",
"primaryText": "#303446",
"primaryContainer": "#6d3e24",
"secondary": "#e5c890",
"surfaceTint": "#382e27"
},
"id": "peach",
"latte": {
"primary": "#fe640b",
"primaryText": "#eff1f5",
"primaryContainer": "#ffe4d5",
"secondary": "#df8e1d",
"surfaceTint": "#ffe4d5"
},
"macchiato": {
"primary": "#f5a97f",
"primaryText": "#24273a",
"primaryContainer": "#704025",
"secondary": "#eed49f",
"surfaceTint": "#3a2f28"
},
"mocha": {
"primary": "#fab387",
"primaryText": "#1e1e2e",
"primaryContainer": "#734226",
"secondary": "#f9e2af",
"surfaceTint": "#3b3028"
},
"name": "Peach"
},
{
"frappe": {
"primary": "#e5c890",
"primaryText": "#303446",
"primaryContainer": "#68542c",
"secondary": "#a6d189",
"surfaceTint": "#383428"
},
"id": "yellow",
"latte": {
"primary": "#df8e1d",
"primaryText": "#eff1f5",
"primaryContainer": "#fff6d6",
"secondary": "#40a02b",
"surfaceTint": "#fff6d6"
},
"macchiato": {
"primary": "#eed49f",
"primaryText": "#24273a",
"primaryContainer": "#6b572e",
"secondary": "#a6da95",
"surfaceTint": "#393529"
},
"mocha": {
"primary": "#f9e2af",
"primaryText": "#1e1e2e",
"primaryContainer": "#6e5a2f",
"secondary": "#a6e3a1",
"surfaceTint": "#3a362a"
},
"name": "Yellow"
},
{
"frappe": {
"primary": "#a6d189",
"primaryText": "#303446",
"primaryContainer": "#2d5932",
"secondary": "#81c8be",
"surfaceTint": "#2a362b"
},
"id": "green",
"latte": {
"primary": "#40a02b",
"primaryText": "#eff1f5",
"primaryContainer": "#dff4e0",
"secondary": "#179299",
"surfaceTint": "#dff4e0"
},
"macchiato": {
"primary": "#a6da95",
"primaryText": "#24273a",
"primaryContainer": "#2e5c34",
"secondary": "#8bd5ca",
"surfaceTint": "#2b372c"
},
"mocha": {
"primary": "#a6e3a1",
"primaryText": "#1e1e2e",
"primaryContainer": "#2f5f36",
"secondary": "#94e2d5",
"surfaceTint": "#2b382c"
},
"name": "Green"
},
{
"frappe": {
"primary": "#81c8be",
"primaryText": "#303446",
"primaryContainer": "#2c5853",
"secondary": "#99d1db",
"surfaceTint": "#2a3634"
},
"id": "teal",
"latte": {
"primary": "#179299",
"primaryText": "#eff1f5",
"primaryContainer": "#daf3f1",
"secondary": "#04a5e5",
"surfaceTint": "#daf3f1"
},
"macchiato": {
"primary": "#8bd5ca",
"primaryText": "#24273a",
"primaryContainer": "#2d5b56",
"secondary": "#91d7e3",
"surfaceTint": "#2b3735"
},
"mocha": {
"primary": "#94e2d5",
"primaryText": "#1e1e2e",
"primaryContainer": "#2e5e59",
"secondary": "#89dceb",
"surfaceTint": "#2b3836"
},
"name": "Teal"
},
{
"frappe": {
"primary": "#99d1db",
"primaryText": "#303446",
"primaryContainer": "#245464",
"secondary": "#85c1dc",
"surfaceTint": "#283438"
},
"id": "sky",
"latte": {
"primary": "#04a5e5",
"primaryText": "#eff1f5",
"primaryContainer": "#dbf1fb",
"secondary": "#209fb5",
"surfaceTint": "#dbf1fb"
},
"macchiato": {
"primary": "#91d7e3",
"primaryText": "#24273a",
"primaryContainer": "#245667",
"secondary": "#7dc4e4",
"surfaceTint": "#293539"
},
"mocha": {
"primary": "#89dceb",
"primaryText": "#1e1e2e",
"primaryContainer": "#24586a",
"secondary": "#74c7ec",
"surfaceTint": "#29363a"
},
"name": "Sky"
},
{
"frappe": {
"primary": "#85c1dc",
"primaryText": "#303446",
"primaryContainer": "#1f4967",
"secondary": "#8caaee",
"surfaceTint": "#27323a"
},
"id": "sapphire",
"latte": {
"primary": "#209fb5",
"primaryText": "#eff1f5",
"primaryContainer": "#def3f8",
"secondary": "#1e66f5",
"surfaceTint": "#def3f8"
},
"macchiato": {
"primary": "#7dc4e4",
"primaryText": "#24273a",
"primaryContainer": "#1f4b6b",
"secondary": "#8aadf4",
"surfaceTint": "#27333b"
},
"mocha": {
"primary": "#74c7ec",
"primaryText": "#1e1e2e",
"primaryContainer": "#1f4d6f",
"secondary": "#89b4fa",
"surfaceTint": "#27343c"
},
"name": "Sapphire"
},
{
"frappe": {
"primary": "#8caaee",
"primaryText": "#303446",
"primaryContainer": "#243d6f",
"secondary": "#babbf1",
"surfaceTint": "#282f3b"
},
"id": "blue",
"latte": {
"primary": "#1e66f5",
"primaryText": "#eff1f5",
"primaryContainer": "#e0e9ff",
"secondary": "#7287fd",
"surfaceTint": "#e0e9ff"
},
"macchiato": {
"primary": "#8aadf4",
"primaryText": "#24273a",
"primaryContainer": "#243e72",
"secondary": "#b7bdf8",
"surfaceTint": "#29303c"
},
"mocha": {
"primary": "#89b4fa",
"primaryText": "#1e1e2e",
"primaryContainer": "#243f75",
"secondary": "#b4befe",
"surfaceTint": "#29313d"
},
"name": "Blue"
},
{
"frappe": {
"primary": "#babbf1",
"primaryText": "#303446",
"primaryContainer": "#3d427b",
"secondary": "#ca9ee6",
"surfaceTint": "#2e2f3e"
},
"id": "lavender",
"latte": {
"primary": "#7287fd",
"primaryText": "#eff1f5",
"primaryContainer": "#e5e8ff",
"secondary": "#8839ef",
"surfaceTint": "#e5e8ff"
},
"macchiato": {
"primary": "#b7bdf8",
"primaryText": "#24273a",
"primaryContainer": "#3e437e",
"secondary": "#c6a0f6",
"surfaceTint": "#2f303f"
},
"mocha": {
"primary": "#b4befe",
"primaryText": "#1e1e2e",
"primaryContainer": "#3f4481",
"secondary": "#cba6f7",
"surfaceTint": "#2f3140"
},
"name": "Lavender"
}
]
},
"sourceDir": "catppuccin"
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 70 KiB

View File

@ -34,28 +34,11 @@ rec {
# Define custom dependencies # Define custom dependencies
# =========================================================================================== # ===========================================================================================
# Python package example
# typed-ffmpeg = pkgs.python313Packages.buildPythonPackage rec {
# pname = "typed_ffmpeg";
# version = "3.6";
#
# src = pkgs.python313Packages.fetchPypi {
# inherit pname version;
# hash = "sha256-YPspq/lqI/jx/9FCQntmQPw4lrPIsdxtHTUg0F0QbrM=";
# };
#
# pyproject = true;
# build-system = [
# pkgs.python313Packages.setuptools
# pkgs.python313Packages.setuptools-scm
# ];
# };
# python = pkgs.python313.withPackages (p: # python = pkgs.python313.withPackages (p:
# with p; [ # with p; [
# # numpy # # numpy
# # matplotlib # # matplotlib
# # typed-ffmpeg # # ffmpeg-python
# # pyside6 # # pyside6
# ]); # ]);
@ -68,7 +51,7 @@ rec {
# bintools = pkgs.bintools.bintools; # Unwrapped bintools # bintools = pkgs.bintools.bintools; # Unwrapped bintools
# libc = pkgs.glibc; # libc = pkgs.glibc;
# }; # };
# gcc = lib.hiPrio (pkgs.wrapCCWith { # gcc = pkgs.hiPrio (pkgs.wrapCCWith {
# cc = pkgs.gcc.cc; # Unwrapped gcc # cc = pkgs.gcc.cc; # Unwrapped gcc
# libc = pkgs.glibc; # libc = pkgs.glibc;
# bintools = bintools; # bintools = bintools;
@ -84,7 +67,7 @@ rec {
# bintools = pkgs.bintools.bintools; # Unwrapped bintools # bintools = pkgs.bintools.bintools; # Unwrapped bintools
# libc = pkgs.glibc_multi; # libc = pkgs.glibc_multi;
# }; # };
# gcc_multilib = lib.hiPrio (pkgs.wrapCCWith { # gcc_multilib = pkgs.hiPrio (pkgs.wrapCCWith {
# cc = pkgs.gcc.cc; # Unwrapped gcc # cc = pkgs.gcc.cc; # Unwrapped gcc
# libc = pkgs.glibc_multi; # libc = pkgs.glibc_multi;
# bintools = bintools_multilib; # bintools = bintools_multilib;
@ -227,9 +210,6 @@ rec {
# Set PYTHONPATH # Set PYTHONPATH
# PYTHONPATH = "."; # PYTHONPATH = ".";
# Set matplotlib backend
# MPLBACKEND = "TkAgg";
# ========================================================================================= # =========================================================================================
# Define shell environment # Define shell environment
# ========================================================================================= # =========================================================================================

View File

@ -200,20 +200,6 @@ $ file: eza -1
sudo chattr -R -i <file> sudo chattr -R -i <file>
$ file: eza -1 $ file: eza -1
% dos2unix
# Convert line endings to unix format
dos2unix <file>
$ file: eza -1
% unix2dos
Convert line endings to dos format
unix2dos <file>
$ file: eza -1
% tiddl
Download stuff from tidal
tiddl download --track-quality max --path ~/Downloads/Beet/Albums --videos none url "<url>"
; =========================== ; ===========================
; SECRETS ; SECRETS
; =========================== ; ===========================

View File

@ -1,204 +0,0 @@
#!/usr/bin/env python3
import argparse
import os
import re
import shutil
import subprocess
from typing import cast
from urllib.request import urlretrieve
INIT_LUA: str = "/home/christoph/.config/nvim/init.lua"
def patch_paths(text: str, mappings: dict[str, str]) -> str:
"""Patches /nix/store paths in init.lua"""
patched = text
for old, new in mappings.items():
print(f"Patching init.lua: {old} -> {new}")
patched = patched.replace(old, new)
return patched
def patch_various(text: str) -> str:
"""Patches various incompatibilities with NixVim init.lua"""
# Install lazy
print("Patching init.lua: Bootstrap lazy.nvim")
patched = (
"""-- Bootstrap lazy.nvim
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not (vim.uv or vim.loop).fs_stat(lazypath) then
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
if vim.v.shell_error ~= 0 then
vim.api.nvim_echo({
{ "Failed to clone lazy.nvim:\\n", "ErrorMsg" },
{ out, "WarningMsg" },
{ "\\nPress any key to exit..." },
}, true, {})
vim.fn.getchar()
os.exit(1)
end
end
vim.opt.rtp:prepend(lazypath)
"""
+ text
)
# print("Patching init.lua: Disabling vim.loader")
# patched = patched.replace("vim.loader.enable(true)", "vim.loader.enable(false)")
return patched
def copy_plugins(text: str, path: str) -> dict[str, str]:
"""Copies NeoVim plugins from the Nix Store"""
os.makedirs(path, exist_ok=True)
plugins_path: str = re.findall(r"\"(/nix/store/.*-lazy-plugins)\"", text)[0]
print(f"Copying: {plugins_path} -> {path}/plugins")
_ = shutil.copytree(plugins_path, f"{path}/plugins")
treesitter_path: str = re.findall(
r"\"(/nix/store/.*-vimplugin-nvim-treesitter.*)\"", text
)[0]
print(f"Copying: {treesitter_path} -> {path}/treesitter")
_ = shutil.copytree(treesitter_path, f"{path}/treesitter")
parsers_path: str = re.findall(r"\"(/nix/store/.*-treesitter-parsers)\"", text)[0]
print(f"Copying: {parsers_path} -> {path}/parsers")
_ = shutil.copytree(parsers_path, f"{path}/parsers")
return {
plugins_path: "./plugins",
treesitter_path: "./treesitter",
parsers_path: "./parsers",
}
def write_file(text: str, path: str) -> None:
"""Write text to a file"""
with open(path, "w") as file:
_ = file.write(text)
# TODO: Could add etc. nvim/lsp/formatter/linter binaries here
# TODO: Needs "install recipe", as in most cases the download will be an archive
DOWNLOADS: list[tuple[str, str]] = [
# (
# "https://github.com/neovim/neovim/releases/download/v0.11.6/nvim-linux-x86_64.tar.gz",
# "nvim",
# ),
]
def download_binaries(path: str, urls: list[tuple[str, str]]) -> None:
"""Download required binaries"""
os.makedirs(f"{path}/bin", exist_ok=True)
def download(url: str, path: str) -> None:
"""Download from URL"""
print(f"Downloading: {url}")
_ = urlretrieve(url, path)
for url, name in urls:
download(url, f"{path}/bin/{name}")
def build_nvim(path: str) -> None:
"""Builds a static nvim binary against musl"""
# TODO: Build etc. is working, but on the target system there are
# lua-ffi errors from noice.nvim with the static binary.
# This does not happen with nvim from system package repository.
def run(command: list[str]) -> None:
"""Run a subprocess"""
print(f"Running: {' '.join(command)}")
_ = subprocess.run(command)
os.makedirs(f"{path}/nvim-build", exist_ok=True)
with open(f"{path}/nvim-build/build-nvim.sh", "w") as file:
_ = file.write(
"\n".join(
[
"#!/bin/sh",
"git clone https://github.com/neovim/neovim",
"cd neovim",
"git checkout stable",
'make -j$(nproc) CMAKE_BUILD_TYPE=Release CMAKE_EXTRA_FLAGS="-DSTATIC_BUILD=1"',
"make CMAKE_INSTALL_PREFIX=/workdir/install install",
]
)
)
run(
[
"docker",
"run",
"--rm",
"-it",
"-v",
f"{os.path.abspath(path)}/nvim-build:/workdir",
"-w",
"/workdir",
"alpine:3.23.3",
"/bin/sh",
"-c",
"apk add build-base cmake coreutils curl gettext-tiny-dev git && chmod +x ./build-nvim.sh && ./build-nvim.sh",
]
)
_ = shutil.copytree(f"{path}/nvim-build/install/bin", f"{path}/bin")
_ = shutil.copytree(f"{path}/nvim-build/install/lib", f"{path}/lib")
_ = shutil.copytree(f"{path}/nvim-build/install/share", f"{path}/share")
_ = shutil.rmtree(f"{path}/nvim-build")
def bundle() -> None:
"""Creates a standalone NeoVim bundle from the NixVim configuration"""
parser = argparse.ArgumentParser()
_ = parser.add_argument(
"--config",
type=str,
default=INIT_LUA,
help="init.lua or other config file",
)
_ = parser.add_argument(
"--out",
type=str,
default="./nvim_bundle",
help="destination folder",
)
args = parser.parse_args()
args.config = cast(str, args.config)
args.out = cast(str, args.out)
with open(args.config, "r") as file:
patched_init_lua: str = file.read()
path_mappings = copy_plugins(patched_init_lua, args.out)
patched_init_lua = patch_paths(patched_init_lua, path_mappings)
patched_init_lua = patch_various(patched_init_lua)
write_file(patched_init_lua, f"{args.out}/init.lua")
# build_nvim(args.out)
# download_binaries(args.out, DOWNLOADS)
if __name__ == "__main__":
bundle()

View File

@ -1,6 +0,0 @@
# NeoVim Portable
## Requirements
- Base packages: `sudo apt install neovim git direnv ripgrep curl fzf`
- Link or copy the generated `nvim_bundle` to `~/.config/nvim` on the target machine

View File

@ -7,7 +7,7 @@
... ...
}: let }: let
# create a module that only contains the options, type can be home or system # create a module that only contains the options, type can be home or system
toModule = type: name: {options.systemmodules.${name} = import ../../${type}/modules/${name}/options.nix {inherit lib mylib;};}; toModule = type: name: {options.modules.${name} = import ../../${type}/modules/${name}/options.nix {inherit lib mylib;};};
# evaluate a single module # evaluate a single module
evalModule = type: name: (lib.evalModules {modules = [(toModule type name)];}); evalModule = type: name: (lib.evalModules {modules = [(toModule type name)];});

View File

@ -1,3 +1,4 @@
# Taken from pull/422785
{ {
lib, lib,
stdenv, stdenv,
@ -46,15 +47,7 @@ stdenv.mkDerivation rec {
++ extraPkgs pkgs; ++ extraPkgs pkgs;
multiPkgs = pkgs: multiPkgs = pkgs:
with pkgs; let with pkgs;
libxml2-legacy = libxml2.overrideAttrs (previousAttrs: rec {
version = "2.13.8";
src = fetchurl {
url = "mirror://gnome/sources/libxml2/${lib.versions.majorMinor version}/libxml2-${version}.tar.xz";
hash = "sha256-J3KUyzMRmrcbK8gfL0Rem8lDW4k60VuyzSsOhZoO6Eo=";
};
});
in
[ [
# Unity Hub ldd dependencies # Unity Hub ldd dependencies
cups cups
@ -101,7 +94,7 @@ stdenv.mkDerivation rec {
xorg.libXcursor xorg.libXcursor
glib glib
gdk-pixbuf gdk-pixbuf
libxml2-legacy libxml2
zlib zlib
clang clang
git # for git-based packages in unity package manager git # for git-based packages in unity package manager

View File

@ -7,7 +7,5 @@
monolisa = pkgs.callPackage ./monolisa {}; monolisa = pkgs.callPackage ./monolisa {};
msty = pkgs.callPackage ./msty {}; msty = pkgs.callPackage ./msty {};
unityhub = pkgs.callPackage ./unityhub {};
tidal-dl-ng = pkgs.callPackage ./tidal-dl-ng {}; tidal-dl-ng = pkgs.callPackage ./tidal-dl-ng {};
tiddl = pkgs.callPackage ./tiddl {};
} }

View File

@ -6,100 +6,90 @@
pkgs, pkgs,
}: let }: let
# #
# Custom Dependencies # Dependencies
# #
pythonPkgs = pkgs.python313Packages.overrideScope (self: super: { requests_2_32_4 = pkgs.python3Packages.requests.overridePythonAttrs (old: {
typer = super.typer.overridePythonAttrs (old: { version = "2.32.4";
version = "0.20.1"; src = pkgs.python3Packages.fetchPypi {
src = super.fetchPypi { inherit (old) pname;
inherit (old) pname; version = "2.32.4";
version = "0.20.1"; sha256 = "sha256-J9AxZoLIopg00yZIIAJLYqNpQgg9Usry8UwFkTNtNCI=";
# sha256 = "sha256-Gq9klAMXk+SHb7C6z6apErVRz0PB5jyADfixqGZyDDc="; # v0.20.0 };
sha256 = "sha256-aFhesbASA2icQZm8RA1r5hbwhR6fDrQeSneIRcWg/Vs="; # v0.20.1 patches =
}; builtins.filter (
}); p: !pkgs.lib.strings.hasInfix "CVE-2024-47081" (toString p)
)
rich = super.rich.overridePythonAttrs (old: { old.patches;
version = "14.2.0";
src = super.fetchPypi {
inherit (old) pname;
version = "14.2.0";
sha256 = "sha256-c/9Qx8DBx3yCQweSg/Tts3bw9kQkM67LjOfm0LktH+Q=";
};
doCheck = false;
});
}); });
# typer_0_20_0 = pkgs.python313Packages.typer.overridePythonAttrs (old: { pycryptodome_3_23_0 = pkgs.python3Packages.pycryptodome.overridePythonAttrs (old: {
# version = "0.20.0"; version = "3.23.0";
# src = pkgs.python313Packages.fetchPypi { src = pkgs.python3Packages.fetchPypi {
# inherit (old) pname; inherit (old) pname;
# version = "0.20.0"; version = "3.23.0";
# sha256 = "sha256-Gq9klAMXk+SHb7C6z6apErVRz0PB5jyADfixqGZyDDc="; sha256 = "sha256-RHcAplcYLWAzi6sJ/bJ1GPiFauzYCuTGvd22f/XaRO8=";
# }; };
# }); });
#
# rich_14_2_0 = pkgs.python313Packages.rich.overridePythonAttrs (old: {
# version = "14.2.0";
# src = pkgs.python313Packages.fetchPypi {
# inherit (old) pname;
# version = "14.2.0";
# sha256 = "sha256-c/9Qx8DBx3yCQweSg/Tts3bw9kQkM67LjOfm0LktH+Q=";
# };
# doCheck = false;
# });
tidalDlNg = pythonPkgs.buildPythonApplication rec { pathvalidate_3_3_1 = pkgs.python3Packages.pathvalidate.overridePythonAttrs (old: {
pname = "tidal_dl_ng_for_dj"; version = "3.3.1";
version = "0.33.2"; src = pkgs.python3Packages.fetchPypi {
inherit (old) pname;
version = "3.3.1";
sha256 = "sha256-sYwHISv+rWJDRbuOHWFBzc8Vo5c2mU6guUA1rSsboXc=";
};
});
typer_0_16_0 = pkgs.python3Packages.typer.overridePythonAttrs (old: {
version = "0.16.0";
src = pkgs.python3Packages.fetchPypi {
inherit (old) pname;
version = "0.16.0";
sha256 = "sha256-rzd/+u4dvjeulEDLTo8RaG6lzk6brgG4SufGO4fx3Ts=";
};
});
tidalDlNg = pkgs.python3Packages.buildPythonApplication rec {
pname = "tidal-dl-ng";
version = "0.26.2";
format = "pyproject"; format = "pyproject";
# The official repo was deleted src = pkgs.fetchFromGitHub {
# src = pkgs.fetchFromGitHub { owner = "exislow";
# owner = "exislow"; repo = "tidal-dl-ng";
# repo = "tidal-dl-ng"; rev = "v${version}";
# rev = "v${version}"; sha256 = "sha256-9C7IpLKeR08/nMbePltwGrzIgXfdaVfyOeFQnfCwMKg=";
# sha256 = "sha256-PUT0anx1yivgXwW21jah7Rv1/BabOT+KPoW446NFNyg=";
# };
# Package now also deleted from PyPi
# src = pythonPkgs.fetchPypi {
# inherit pname version;
# sha256 = "sha256-rOMyxnT7uVnMbn678DFtqAu4+Uc5VFGcqGI0jxplnpc=";
# };
# TODO: Borked
# "For DJ"-Fork
src = pythonPkgs.fetchPypi {
inherit pname version;
sha256 = "sha256-605cgBqZV6L7sxWtEa4Ki+9hBqX4m3Rk+X5oY5bv/FQ=";
}; };
dontCheckRuntimeDeps = true; doCheck = false;
catchConflicts = false;
nativeBuildInputs = with pythonPkgs; [poetry-core setuptools]; nativeBuildInputs = with pkgs.python3Packages; [poetry-core setuptools];
# https://github.com/exislow/tidal-dl-ng/blob/master/pyproject.toml propagatedBuildInputs = with pkgs.python3Packages; [
propagatedBuildInputs = with pythonPkgs; [ requests_2_32_4
# Nixpkgs
requests
mutagen
dataclasses-json
pathvalidate
m3u8
coloredlogs coloredlogs
dataclasses-json
m3u8
mpegdash
mutagen
pathvalidate_3_3_1
pycryptodome_3_23_0
python-ffmpeg
rich
tidalapi
toml
typer_0_16_0
pyside6 pyside6
pyqtdarktheme pyqtdarktheme
toml
pycryptodome
tidalapi
python-ffmpeg
ansi2html
# Custom Deps
typer
rich
]; ];
# pythonOutputDistPhase = ''
# echo "⚠Skipping pythonOutputDistPhase"
# '';
# pythonCatchConflictsPhase = ''
# echo "🛑 Skipping pythonCatchConflictsPhase"
# '';
}; };
# #
@ -128,7 +118,7 @@
tidal-dl-ng-gui-desktopfile = pkgs.stdenv.mkDerivation { tidal-dl-ng-gui-desktopfile = pkgs.stdenv.mkDerivation {
pname = "tdng"; pname = "tdng";
version = "0.33.2"; version = "0.26.2";
dontUnpack = true; dontUnpack = true;
nativeBuildInputs = [pkgs.makeWrapper]; nativeBuildInputs = [pkgs.makeWrapper];

View File

@ -1,60 +0,0 @@
{
lib,
stdenv,
pkgs,
}: let
pythonPkgs = pkgs.python314Packages.overrideScope (self: super: {
typer = super.typer.overridePythonAttrs (old: {
version = "0.20.1";
src = pkgs.fetchPypi {
pname = "typer";
version = "0.20.0";
sha256 = "sha256-Gq9klAMXk+SHb7C6z6apErVRz0PB5jyADfixqGZyDDc=";
};
});
aiofiles = super.aiofiles.overridePythonAttrs (old: {
version = "25.1.0";
src = pkgs.fetchFromGitHub {
owner = "Tinche";
repo = "aiofiles";
tag = "v25.1.0";
hash = "sha256-NBmzoUb2una3+eWqR1HraVPibaRb9I51aYwskrjxskQ=";
};
# Build system changed in this version
build-system = with pythonPkgs; [
hatchling
hatch-vcs
];
});
});
in
pythonPkgs.buildPythonApplication rec {
pname = "tiddl";
version = "3.2.0";
format = "pyproject";
src = pythonPkgs.fetchPypi {
inherit pname version;
sha256 = "sha256-uLkGyIScYPqFgQdPAOYJDJG0jp+nDAwIl2kFkaJZFco=";
};
dontCheckRuntimeDeps = true;
build-system = with pythonPkgs; [
poetry-core
setuptools
];
propagatedBuildInputs = with pythonPkgs; [
# Nixpkgs
aiofiles
aiohttp
m3u8
mutagen
pydantic
requests
requests-cache
typer
];
}

1320
flake.lock generated

File diff suppressed because it is too large Load Diff

138
flake.nix
View File

@ -12,9 +12,6 @@
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
hardware.url = "github:nixos/nixos-hardware"; hardware.url = "github:nixos/nixos-hardware";
# NOTE: Update this after May and November
nixpkgs-stable.url = "github:nixos/nixpkgs/nixos-25.05";
# Home Manager # Home Manager
home-manager.url = "github:nix-community/home-manager"; home-manager.url = "github:nix-community/home-manager";
home-manager.inputs.nixpkgs.follows = "nixpkgs"; home-manager.inputs.nixpkgs.follows = "nixpkgs";
@ -31,72 +28,21 @@
sops-nix.url = "github:Mic92/sops-nix"; sops-nix.url = "github:Mic92/sops-nix";
sops-nix.inputs.nixpkgs.follows = "nixpkgs"; sops-nix.inputs.nixpkgs.follows = "nixpkgs";
# Secure boot
lanzaboote.url = "github:nix-community/lanzaboote/v0.4.3";
lanzaboote.inputs.nixpkgs.follows = "nixpkgs";
# Nix User Repository (e.g. Firefox addons) # Nix User Repository (e.g. Firefox addons)
nur.url = "github:nix-community/NUR"; nur.url = "github:nix-community/NUR";
nur.inputs.nixpkgs.follows = "nixpkgs"; nur.inputs.nixpkgs.follows = "nixpkgs";
# Firefox theme
textfox.url = "github:adriankarlen/textfox";
textfox.inputs.nixpkgs.follows = "nixpkgs";
# Nix Package Search - nps # Nix Package Search - nps
nps.url = "github:OleMussmann/nps"; nps.url = "github:OleMussmann/nps";
nps.inputs.nixpkgs.follows = "nixpkgs"; nps.inputs.nixpkgs.follows = "nixpkgs";
# Run unpatched binaries on NixOS # Run unpatched binaries on NixOS
nix-alien.url = "github:thiagokokada/nix-alien"; nix-alien.url = "github:thiagokokada/nix-alien";
# Don't follow nixpkgs: nix-alien.inputs.nixpkgs.follows = "nixpkgs";
# https://github.com/thiagokokada/nix-alien#user-content-nixos-installation-with-flakes
# nix-alien.inputs.nixpkgs.follows = "nixpkgs";
# Niri
niri.url = "github:sodiboo/niri-flake";
niri.inputs.nixpkgs.follows = "nixpkgs";
# Quickshell
quickshell.url = "github:quickshell-mirror/quickshell";
quickshell.inputs.nixpkgs.follows = "nixpkgs";
# Noctalia shell
noctalia.url = "github:noctalia-dev/noctalia-shell";
noctalia.inputs.nixpkgs.follows = "nixpkgs";
# noctalia.inputs.quickshell.follows = "quickshell";
# Lol
waifu-cursors.url = "github:kagurazakei/waifu-cursors";
# Caelestia shell
caelestia.url = "github:caelestia-dots/shell";
caelestia.inputs.nixpkgs.follows = "nixpkgs";
caelestia.inputs.quickshell.follows = "quickshell";
# caelestia-cli.url = "github:caelestia-dots/cli";
# caelestia-cli.inputs.nixpkgs.follows = "nixpkgs";
# DankMaterialShell
# dgop.url = "github:AvengeMedia/dgop";
# dgop.inputs.nixpkgs.follows = "nixpkgs";
# dms-cli.url = "github:AvengeMedia/danklinux";
# dms-cli.inputs.nixpkgs.follows = "nixpkgs";
dank-material-shell.url = "github:AvengeMedia/DankMaterialShell";
dank-material-shell.inputs.nixpkgs.follows = "nixpkgs";
# dank-material-shell.inputs.dgop.follows = "dgop";
danksearch.url = "github:AvengeMedia/danksearch";
danksearch.inputs.nixpkgs.follows = "nixpkgs";
# Hyprland (use flake so plugins are not built from source)
hyprland.url = "github:hyprwm/Hyprland";
hyprland.inputs.nixpkgs.follows = "nixpkgs";
# HyprPlugins
hyprland-plugins.url = "github:hyprwm/hyprland-plugins";
hyprland-plugins.inputs.nixpkgs.follows = "nixpkgs";
hyprland-plugins.inputs.hyprland.follows = "hyprland";
hypr-dynamic-cursors.url = "github:VirtCode/hypr-dynamic-cursors";
hypr-dynamic-cursors.inputs.nixpkgs.follows = "nixpkgs";
hypr-dynamic-cursors.inputs.hyprland.follows = "hyprland";
hyprspace.url = "github:KZDKM/Hyprspace";
# hyprspace.inputs.nixpkgs.follows = "nixpkgs";
hyprspace.inputs.hyprland.follows = "hyprland";
# NeoVim <3 # NeoVim <3
nixvim.url = "github:nix-community/nixvim"; nixvim.url = "github:nix-community/nixvim";
@ -106,10 +52,6 @@
# emacs-overlay.url = "github:nix-community/emacs-overlay"; # emacs-overlay.url = "github:nix-community/emacs-overlay";
# emacs-overlay.inputs.nixpkgs.follows = "nixpkgs"; # emacs-overlay.inputs.nixpkgs.follows = "nixpkgs";
# Firefox theme
textfox.url = "github:adriankarlen/textfox";
textfox.inputs.nixpkgs.follows = "nixpkgs";
# Declarative Flatpak # Declarative Flatpak
nix-flatpak.url = "github:gmodena/nix-flatpak/?ref=latest"; nix-flatpak.url = "github:gmodena/nix-flatpak/?ref=latest";
# nix-flatpak.inputs.nixpkgs.follows = "nixpkgs"; # nix-flatpak doesn't have this # nix-flatpak.inputs.nixpkgs.follows = "nixpkgs"; # nix-flatpak doesn't have this
@ -117,6 +59,16 @@
# Realtime audio # Realtime audio
# musnix.url = "github:musnix/musnix"; # musnix.url = "github:musnix/musnix";
# musnix.inputs.nixpkgs.follows = "nixpkgs"; # musnix.inputs.nixpkgs.follows = "nixpkgs";
# HyprPlugins
# hyprland-plugins.url = "github:hyprwm/hyprland-plugins";
# hyprland-plugins.inputs.nixpkgs.follows = "nixpkgs";
# hypr-dynamic-cursors.url = "github:VirtCode/hypr-dynamic-cursors";
# hypr-dynamic-cursors.inputs.nixpkgs.follows = "nixpkgs";
# Pinned versions
# v4l2loopback-pinned.url = "github:nixos/nixpkgs/4684fd6b0c01e4b7d99027a34c93c2e09ecafee2";
# unityhub-pinned.url = "github:huantianad/nixpkgs/9542b0bc7701e173a10e6977e57bbba68bb3051f";
}; };
# Outputs is a function that takes the inputs as arguments. # Outputs is a function that takes the inputs as arguments.
@ -150,25 +102,41 @@
# firefox = prev.firefox.override { ... }; # firefox = prev.firefox.override { ... };
# myBrowser = final.firefox; # myBrowser = final.firefox;
# } # }
overlays = let overlays = [
# Maintain additional stable pkgs.
# This is supposed to provide a backup for packages in case they
# stop building on the unstable branch.
# It should otherwise not be mixed with this configuration,
# so don't even pass it to the modules.
pkgs-stable = import inputs.nixpkgs-stable {
inherit system;
config.allowUnfree = true;
config.allowUnfreePredicate = pkg: true;
};
in [
inputs.devshell.overlays.default inputs.devshell.overlays.default
inputs.nur.overlays.default inputs.nur.overlays.default
inputs.niri.overlays.niri
# inputs.emacs-overlay.overlay # inputs.emacs-overlay.overlay
# All my own overlays (derivations + modifications) # Overriding specific packages from a different nixpkgs (e.g. a pull request)
(import ./overlays {inherit inputs nixpkgs pkgs-stable;}) # can be done like this. Note that this creates an additional nixpkgs instance.
# https://github.com/NixOS/nixpkgs/issues/418451
# (final: prev: {
# unityhub_pinned_3_13 = import inputs.unityhub-pinned {
# config.allowUnfree = true;
# localSystem = {inherit (prev) system;};
# };
# })
# TODO: Remove this after 0.15.1 hit nixpkgs
(final: prev: {
neovide = prev.neovide.overrideAttrs (finalAttrs: prevAttrs: {
version = "0.15.1";
src = prev.fetchFromGitHub {
owner = "neovide";
repo = "neovide";
tag = finalAttrs.version;
hash = "sha256-2iV3g6tcCkMF7sFG/GZDz3czPZNIDi6YLfrVzYO9jYI=";
};
cargoHash = "sha256-YlHAcUCRk6ROg5yXIumHfsiR/2TrsSzbuXz/IQK7sEo=";
cargoDeps = prev.rustPlatform.fetchCargoVendor {
inherit (finalAttrs) pname src version;
hash = finalAttrs.cargoHash;
};
});
})
# All my own overlays
(import ./overlays {inherit nixpkgs inputs;})
]; ];
}; };
@ -200,12 +168,8 @@
# HM modules are passed through home/modules/default.nix instead. # HM modules are passed through home/modules/default.nix instead.
commonModules = [ commonModules = [
inputs.sops-nix.nixosModules.sops inputs.sops-nix.nixosModules.sops
inputs.disko.nixosModules.disko
inputs.impermanence.nixosModules.impermanence inputs.impermanence.nixosModules.impermanence
inputs.lanzaboote.nixosModules.lanzaboote
# We need the niri module also on the headless hosts
# so nix can parse the config (although it is disabled...)
inputs.niri.nixosModules.niri # This also imports the HM module
]; ];
in { in {
# Local shell for NixFlake directory # Local shell for NixFlake directory
@ -231,9 +195,7 @@
username = "christoph"; username = "christoph";
headless = false; headless = false;
extraModules = extraModules =
[ []
inputs.disko.nixosModules.disko
]
++ commonModules; ++ commonModules;
}; };
nixtop = mylib.nixos.mkNixosConfigWithHomeManagerModule { nixtop = mylib.nixos.mkNixosConfigWithHomeManagerModule {
@ -241,7 +203,9 @@
hostname = "nixtop"; hostname = "nixtop";
username = "christoph"; username = "christoph";
headless = false; headless = false;
extraModules = [] ++ commonModules; extraModules =
[]
++ commonModules;
}; };
servenix = mylib.nixos.mkNixosConfigWithHomeManagerModule { servenix = mylib.nixos.mkNixosConfigWithHomeManagerModule {
inherit system mylib publicKeys; inherit system mylib publicKeys;

File diff suppressed because it is too large Load Diff

View File

@ -8,8 +8,12 @@
username, username,
... ...
}: { }: {
imports = [
../../modules
];
config = { config = {
homemodules = { modules = {
btop.cuda = true; btop.cuda = true;
# This has been relocated here from the default config, # This has been relocated here from the default config,
@ -24,16 +28,16 @@
}; };
monitors = { monitors = {
"DP-1" = { "HDMI-A-1" = {
width = 3440; width = 2560;
height = 1440; height = 1440;
rate = 165; rate = 144;
x = 1920; x = 1920;
y = 0; y = 0;
scale = 1; scale = 1;
}; };
"DP-2" = { "DP-1" = {
width = 1920; width = 1920;
height = 1080; height = 1080;
rate = 60; rate = 60;
@ -44,8 +48,8 @@
}; };
workspaces = { workspaces = {
"DP-1" = [1 2 3 4 5 6 7 8 9]; "HDMI-A-1" = [1 2 3 4 5 6 7 8 9];
"DP-2" = [10]; "DP-1" = [10];
}; };
autostart = { autostart = {
@ -61,7 +65,7 @@
]; ];
}; };
waybar.monitor = "DP-1"; waybar.monitor = "HDMI-A-1";
}; };
home = let home = let
@ -87,7 +91,8 @@
# Add any extra libraries you want accessible to Rider here # Add any extra libraries you want accessible to Rider here
]; ];
rider-unity = pkgs.jetbrains.rider.overrideAttrs (attrs: { # TODO: Broken, jetbrains.jdk doesn't build (see nixpkgs #425328)
unity-rider = pkgs.jetbrains.rider.overrideAttrs (attrs: {
postInstall = postInstall =
'' ''
# Wrap rider with extra tools and libraries # Wrap rider with extra tools and libraries
@ -110,64 +115,49 @@
}); });
in { in {
packages = with pkgs; [ packages = with pkgs; [
# Intel FPGA design software # quartus-prime-lite # Intel FPGA design software
# quartus-prime-lite
# Don't want heavy IDE's on the laptop
# jetbrains.clion # jetbrains.clion
# jetbrains.rust-rover # jetbrains.rust-rover
# jetbrains.pycharm-professional # jetbrains.pycharm-professional
# jetbrains.idea-ultimate # jetbrains.idea-ultimate
# jetbrains.webstorm # jetbrains.webstorm
# jetbrains.rider
zed-editor
vscode
# Unity Stuff # Unity Stuff
# unityhub # TODO: Unity module
# rider-unity # unityhub # TODO: Wait for https://nixpk.gs/pr-tracker.html?pr=422785
# unity-rider
# dotnetCore # dotnetCore
# mono # mono
# steam-run-free # nix-alien doesn't seem to run unity apps, this does...
(blender.override {cudaSupport = true;}) blender
godot_4 godot_4
(obs-studio.override {cudaSupport = true;}) obs-studio
kdePackages.kdenlive kdePackages.kdenlive
# davinci-resolve
krita krita
makemkv makemkv
lrcget msty
# msty
# jellyfin-media-player # CVE, can't install
jellyfin-desktop
jellyfin-mpv-shim
# tidal-hifi
# tidal-dl-ng # TODO: Borked
tiddl
picard
handbrake
teamspeak6-client
steam-devices-udev-rules steam-devices-udev-rules
]; ];
file = lib.mkMerge [ file = lib.mkMerge [
# { {
# ".local/share/applications/jetbrains-rider.desktop".source = let # ".local/share/applications/jetbrains-rider.desktop".source = let
# desktopFile = pkgs.makeDesktopItem { # desktopFile = pkgs.makeDesktopItem {
# name = "jetbrains-rider"; # name = "jetbrains-rider";
# desktopName = "Rider"; # desktopName = "Rider";
# exec = "\"${rider-unity}/bin/rider\""; # exec = "\"${unity-rider}/bin/rider\"";
# icon = "rider"; # icon = "rider";
# type = "Application"; # type = "Application";
# # Don't show desktop icon in search or run launcher # # Don't show desktop icon in search or run launcher
# extraConfig.NoDisplay = "true"; # extraConfig.NoDisplay = "true";
# }; # };
# in "${desktopFile}/share/applications/jetbrains-rider.desktop"; # in "${desktopFile}/share/applications/jetbrains-rider.desktop";
#
# ".var/app/com.valvesoftware.Steam/config/MangoHud/MangoHud.conf".source = ".var/app/com.valvesoftware.Steam/config/MangoHud/MangoHud.conf".source = ../../../config/mangohud/MangoHud.conf;
# ../../../config/mangohud/MangoHud.conf; }
# }
(lib.optionalAttrs (mylib.modules.contains config.home.packages pkgs.makemkv) { (lib.optionalAttrs (mylib.modules.contains config.home.packages pkgs.makemkv) {
".MakeMKV/settings.conf".source = ".MakeMKV/settings.conf".source =
config.lib.file.mkOutOfStoreSymlink config.lib.file.mkOutOfStoreSymlink
@ -182,7 +172,7 @@
services = { services = {
ollama = { ollama = {
enable = false; enable = true;
acceleration = "cuda"; acceleration = "cuda";
# home = "/var/lib/ollama"; # home = "/var/lib/ollama";
@ -212,28 +202,21 @@
flatpak = { flatpak = {
packages = [ packages = [
# "com.valvesoftware.Steam" "com.valvesoftware.Steam"
# "com.valvesoftware.Steam.Utility.steamtinkerlaunch" "com.valvesoftware.Steam.Utility.steamtinkerlaunch"
# "net.davidotek.pupgui2" "net.davidotek.pupgui2"
# "org.freedesktop.Platform.VulkanLayer.gamescope/x86_64/24.08"
# "org.freedesktop.Platform.VulkanLayer.MangoHud/x86_64/24.08" "org.freedesktop.Platform.VulkanLayer.gamescope/x86_64/24.08"
"org.freedesktop.Platform.VulkanLayer.MangoHud/x86_64/24.08"
"org.prismlauncher.PrismLauncher" "org.prismlauncher.PrismLauncher"
"com.usebottles.bottles" "com.usebottles.bottles"
# "io.github.lawstorant.boxflat" "io.github.lawstorant.boxflat"
# "com.unity.UnityHub" "com.unity.UnityHub"
]; ];
overrides = { overrides = {
"org.prismlauncher.PrismLauncher".Context = {
filesystems = [
"${config.home.homeDirectory}/Downloads"
"/tmp" # To allow temporary world folder creation for datapack installation
];
};
"com.valvesoftware.Steam".Context = { "com.valvesoftware.Steam".Context = {
filesystems = [ filesystems = [
"${config.home.homeDirectory}/Games" "${config.home.homeDirectory}/Games"

View File

@ -1,7 +1,11 @@
# Here goes the stuff that will only be enabled on the laptop # Here goes the stuff that will only be enabled on the laptop
{...}: { {...}: {
imports = [
../../modules
];
config = { config = {
homemodules = { modules = {
hyprland = { hyprland = {
keyboard = { keyboard = {
layout = "us"; layout = "us";

View File

@ -6,8 +6,12 @@
username, username,
... ...
}: { }: {
imports = [
../../modules
];
config = { config = {
homemodules = { modules = {
btop.cuda = true; btop.cuda = true;
}; };

View File

@ -6,6 +6,10 @@
username, username,
... ...
}: { }: {
imports = [
../../modules
];
config = { config = {
home.packages = with pkgs; [ home.packages = with pkgs; [
docker-compose docker-compose

View File

@ -1,14 +0,0 @@
{
config,
nixosConfig,
lib,
mylib,
pkgs,
...
}: let
inherit (config.homemodules) TEMPLATE color;
in {
options.homemodules.TEMPLATE = import ./options.nix {inherit lib mylib;};
config = lib.mkIf TEMPLATE.enable {};
}

View File

@ -1,31 +0,0 @@
{
lib,
pkgs,
config,
hyprland,
}:
builtins.concatLists [
(lib.optionals hyprland.dunst.enable ["dunst"]) # Notifications
(lib.optionals hyprland.hyprpanel.enable ["hyprpanel"]) # Panel
(lib.optionals hyprland.caelestia.enable ["caelestia shell"]) # Panel/Shell # TODO: Crashes on startup
[
# Start clipboard management
"wl-paste -t text --watch clipman store --no-persist"
"wl-paste -p -t text --watch clipman store -P --histpath=\"~/.local/share/clipman-primary.json\""
"hyprctl setcursor ${config.home.pointerCursor.name} ${builtins.toString config.home.pointerCursor.size}"
"hyprsunset --identity"
# HACK: Hyprland doesn't set the xwayland/x11 keymap correctly
"setxkbmap -layout ${hyprland.keyboard.layout} -variant ${hyprland.keyboard.variant} -option ${hyprland.keyboard.option} -model pc104"
# HACK: Flatpak doesn't find applications in the system PATH
"systemctl --user import-environment PATH && systemctl --user restart xdg-desktop-portal.service"
# Provide a polkit authentication UI.
# This is used for example when running systemd commands without root.
# "systemctl --user start hyprpolkitagent.service"
# "${pkgs.kdePackages.polkit-kde-agent-1}/libexec/polkit-kde-authentication-agent-1"
"${pkgs.polkit_gnome}/libexec/polkit-gnome-authentication-agent-1"
]
]

View File

@ -1,516 +0,0 @@
{
config,
hyprland,
color,
}: {
enable = hyprland.caelestia.enable;
systemd = {
enable = false; # Start from hyprland autostart
target = "graphical-session.target";
environment = [];
};
settings = {
appearance = {
anim = {durations = {scale = 1;};};
font = {
family = {
clock = "Rubik";
material = "Material Symbols Rounded";
mono = color.font;
sans = color.font;
};
size = {scale = 1;};
};
padding = {scale = 1;};
rounding = {scale = 1;};
spacing = {scale = 1;};
transparency = {
base = 0.85;
enabled = false;
layers = 0.4;
};
};
background = {
desktopClock = {enabled = false;};
enabled = true;
# Lags when visible on both monitors (different refresh rates?)
visualiser = {
autoHide = true;
blur = true;
enabled = false;
rounding = 1;
spacing = 1;
};
};
bar = {
clock = {showIcon = true;};
dragThreshold = 20;
entries = [
{
enabled = true;
id = "logo";
}
{
enabled = true;
id = "workspaces";
}
{
enabled = true;
id = "spacer";
}
{
enabled = true;
id = "activeWindow";
}
{
enabled = true;
id = "spacer";
}
{
enabled = true;
id = "clock";
}
{
enabled = true;
id = "tray";
}
{
enabled = true;
id = "statusIcons";
}
{
enabled = true;
id = "power";
}
];
persistent = true;
popouts = {
activeWindow = true;
statusIcons = true;
tray = true;
};
scrollActions = {
brightness = false;
volume = true;
workspaces = true;
};
showOnHover = true;
status = {
showAudio = true;
showBattery = false;
showBluetooth = true;
showKbLayout = false;
showLockStatus = true;
showMicrophone = false;
showNetwork = true;
};
tray = {
background = true;
compact = false;
iconSubs = [];
recolour = false;
};
workspaces = {
activeIndicator = true;
activeLabel = "󰮯";
activeTrail = true;
label = " ";
occupiedBg = false;
occupiedLabel = "󰮯";
perMonitorWorkspaces = false;
showWindows = false;
shown = 10;
# Pick them here: https://fonts.google.com/icons
specialWorkspaceIcons = [
{
icon = "music_note";
name = "rmpc";
}
{
icon = "memory";
name = "btop";
}
{
icon = "mark_chat_unread";
name = "ferdium";
}
{
icon = "network_intelligence";
name = "msty";
}
];
};
};
border = {
rounding = 25;
thickness = 10;
};
dashboard = {
dragThreshold = 50;
enabled = true;
mediaUpdateInterval = 500;
showOnHover = true;
};
general = {
apps = {
audio = ["kitty" "--title=NcpaMixer" "-e" "ncpamixer"];
explorer = ["kitty" "--title=Yazi" "-e" "yazi"];
playback = ["mpv"];
terminal = ["kitty"];
};
battery = {
criticalLevel = 3;
warnLevels = [
{
icon = "battery_android_frame_2";
level = 20;
message = "You might want to plug in a charger";
title = "Low battery";
}
{
icon = "battery_android_frame_1";
level = 10;
message = "You should probably plug in a charger <b>now</b>";
title = "Did you see the previous message?";
}
{
critical = true;
icon = "battery_android_alert";
level = 5;
message = "PLUG THE CHARGER RIGHT NOW!!";
title = "Critical battery level";
}
];
};
idle = {
inhibitWhenAudio = true;
lockBeforeSleep = true;
timeouts = [
{
idleAction = "lock";
timeout = 600;
}
{
# idleAction = "dpms off";
# returnAction = "dpms on";
idleAction = "echo 'idle'";
returnAction = "echo 'return'";
timeout = 10000;
}
{
# idleAction = ["systemctl" "suspend-then-hibernate"];
idleAction = ["echo" "'idle'"];
timeout = 20000;
}
];
};
};
launcher = {
actionPrefix = ">";
actions = [
{
command = ["autocomplete" "calc"];
dangerous = false;
description = "Do simple math equations (powered by Qalc)";
enabled = true;
icon = "calculate";
name = "Calculator";
}
{
command = ["autocomplete" "scheme"];
dangerous = false;
description = "Change the current colour scheme";
enabled = true;
icon = "palette";
name = "Scheme";
}
{
command = ["autocomplete" "wallpaper"];
dangerous = false;
description = "Change the current wallpaper";
enabled = true;
icon = "image";
name = "Wallpaper";
}
{
command = ["autocomplete" "variant"];
dangerous = false;
description = "Change the current scheme variant";
enabled = true;
icon = "colors";
name = "Variant";
}
{
command = ["autocomplete" "transparency"];
dangerous = false;
description = "Change shell transparency";
enabled = false;
icon = "opacity";
name = "Transparency";
}
{
command = ["caelestia" "wallpaper" "-r"];
dangerous = false;
description = "Switch to a random wallpaper";
enabled = false;
icon = "casino";
name = "Random";
}
{
command = ["setMode" "light"];
dangerous = false;
description = "Change the scheme to light mode";
enabled = true;
icon = "light_mode";
name = "Light";
}
{
command = ["setMode" "dark"];
dangerous = false;
description = "Change the scheme to dark mode";
enabled = true;
icon = "dark_mode";
name = "Dark";
}
{
command = ["systemctl" "poweroff"];
dangerous = true;
description = "Shutdown the system";
enabled = true;
icon = "power_settings_new";
name = "Shutdown";
}
{
command = ["systemctl" "reboot"];
dangerous = true;
description = "Reboot the system";
enabled = true;
icon = "cached";
name = "Reboot";
}
{
command = ["loginctl" "terminate-user" ""];
dangerous = true;
description = "Log out of the current session";
enabled = true;
icon = "exit_to_app";
name = "Logout";
}
{
command = ["loginctl" "lock-session"];
dangerous = false;
description = "Lock the current session";
enabled = true;
icon = "lock";
name = "Lock";
}
{
command = ["systemctl" "suspend-then-hibernate"];
dangerous = false;
description = "Suspend then hibernate";
enabled = false;
icon = "bedtime";
name = "Sleep";
}
];
dragThreshold = 50;
enableDangerousActions = true;
hiddenApps = [];
maxShown = 7;
maxWallpapers = 9;
showOnHover = false;
specialPrefix = "@";
useFuzzy = {
actions = false;
apps = false;
schemes = false;
variants = false;
wallpapers = false;
};
vimKeybinds = false;
};
lock = {recolourLogo = false;};
notifs = {
actionOnClick = false;
clearThreshold = 0.3;
defaultExpireTimeout = 5000;
expandThreshold = 20;
expire = true;
};
osd = {
enableBrightness = false;
enableMicrophone = true;
enabled = true;
hideDelay = 2000;
};
paths = {
mediaGif = "root:/assets/bongocat.gif";
sessionGif = "root:/assets/kurukuru.gif";
wallpaperDir = "~/NixFlake/wallpapers";
};
services = {
audioIncrement = 0.1;
defaultPlayer = "MPD";
gpuType = "";
maxVolume = 1;
playerAliases = [
{
from = "com.github.th_ch.youtube_music";
to = "YT Music";
}
];
smartScheme = true;
useFahrenheit = false;
useTwelveHourClock = false;
visualiserBars = 45;
weatherLocation = "Dortmund, Germany";
};
session = {
commands = {
hibernate = ["systemctl" "hibernate"];
logout = ["loginctl" "terminate-user" ""];
reboot = ["systemctl" "reboot"];
shutdown = ["systemctl" "poweroff"];
};
dragThreshold = 30;
enabled = true;
vimKeybinds = false;
};
sidebar = {
dragThreshold = 80;
enabled = true;
};
utilities = {
enabled = true;
maxToasts = 4;
toasts = {
audioInputChanged = true;
audioOutputChanged = true;
capsLockChanged = true;
chargingChanged = true;
configLoaded = true;
dndChanged = true;
gameModeChanged = true;
kbLayoutChanged = false;
nowPlaying = false;
numLockChanged = true;
vpnChanged = true;
};
vpn = {
enabled = false;
provider = [
{
displayName = "Wireguard (Your VPN)";
interface = "your-connection-name";
name = "wireguard";
}
];
};
};
};
cli = {
enable = hyprland.caelestia.enable;
settings = {
record = {extraArgs = [];};
theme = {
enableBtop = false;
enableDiscord = false;
enableFuzzel = false;
enableGtk = false;
enableHypr = false;
enableQt = false;
enableSpicetify = false;
enableTerm = false;
};
toggles = {
communication = {
discord = {
command = ["discord"];
enable = false;
match = [{class = "discord";}];
move = true;
};
whatsapp = {
enable = false;
match = [{class = "whatsapp";}];
move = true;
};
};
music = {
feishin = {
enable = false;
match = [{class = "feishin";}];
move = true;
};
spotify = {
command = ["spicetify" "watch" "-s"];
enable = false;
match = [{class = "Spotify";} {initialTitle = "Spotify";} {initialTitle = "Spotify Free";}];
move = true;
};
};
sysmon = {
btop = {
command = ["kitty" "--title" "Btop" "-e" "btop"];
enable = false;
match = [
{
class = "btop";
title = "Btop";
workspace = {name = "special:sysmon";};
}
];
};
};
todo = {
todoist = {
command = ["todoist"];
enable = false;
match = [{class = "Todoist";}];
move = true;
};
};
};
wallpaper = {postHook = "echo $WALLPAPER_PATH";};
};
};
}

View File

@ -1,180 +0,0 @@
{
inputs,
config,
lib,
mylib,
pkgs,
nixosConfig,
username,
...
}: let
inherit (config.homemodules) hyprland color;
# Autostart programs
always-exec = import ./autostart.nix {inherit lib pkgs config hyprland;};
# Keybindings
always-bind = import ./mappings.nix {inherit lib config hyprland;};
# Mousebindings
always-bindm = {
"$mainMod, mouse:272" = ["movewindow"];
"$mainMod, mouse:273" = ["resizewindow"];
};
in {
options.homemodules.hyprland = import ./options.nix {inherit lib mylib;};
config = lib.mkIf hyprland.enable {
assertions = [
{
assertion = nixosConfig.programs.hyprland.enable;
message = "Can't enable Hyprland module with Hyprland disabled!";
}
{
assertion = builtins.hasAttr "hyprlock" nixosConfig.security.pam.services;
message = "Can't enable Hyprland module without Hyprlock PAM service!";
}
{
assertion = hyprland.hyprpanel.enable != hyprland.caelestia.enable;
message = "Can't enable Hyprpanel and Caelestia at the same time!";
}
];
gtk = {
enable = true;
iconTheme.package = lib.mkDefault color.iconPackage;
iconTheme.name = color.iconTheme;
};
homemodules = {
hyprpanel.enable = hyprland.hyprpanel.enable;
};
home = {
pointerCursor = {
gtk.enable = lib.mkDefault true;
x11.enable = lib.mkDefault true;
package = lib.mkDefault color.cursorPackage;
name = color.cursor;
size = color.cursorSize;
};
packages = with pkgs; [
hyprpaper # Wallpaper setter
hyprpicker # Color picker
# hyprpolkitagent # Ugly polkit authentication GUI
hyprland-qt-support
hyprsunset # Blue light filter
wl-clipboard
clipman # Clipboard manager (wl-paste)
libnotify
inotify-tools # Includes inotifywait
ncpamixer # Audio control
slurp # Region selector for screensharing
grim # Grab images from compositor
# Deps for Qt5 and Qt6 apps (e.g., Nextcloud)
qt5.qtwayland
qt6.qtwayland
];
file = {
".config/hypr/keybindings.info".text = let
fixupHomeDir = key:
builtins.replaceStrings ["/home/${username}"] ["~"] key;
fixupNixStore = key: let
# The pattern has to match the entire string, otherwise it won't work
matches = builtins.match ".*/nix/store/(.*)/.*" key;
in
if (matches == null)
then key
else builtins.replaceStrings matches ["..."] key;
fixupNoMod = key:
builtins.replaceStrings ["<-"] ["<"] key;
mkBindHelpKey = key:
builtins.replaceStrings ["$mainMod" " " ","] ["${hyprland.keybindings.main-mod}" "-" ""] key;
mkBindHelpAction = action:
builtins.replaceStrings [","] [""] action;
mkBindHelp = key: action: "<${mkBindHelpKey key}>: ${mkBindHelpAction action}";
mkBindsHelp = key: actions:
actions
|> builtins.map (mkBindHelp key)
|> builtins.map fixupNoMod
|> builtins.map fixupNixStore
|> builtins.map fixupHomeDir;
in
(hyprland.keybindings.bindings // always-bind)
|> builtins.mapAttrs mkBindsHelp
|> builtins.attrValues
|> builtins.concatLists
|> builtins.concatStringsSep "\n";
};
};
programs = {
hyprlock = import ./hyprlock.nix {inherit config hyprland color;};
caelestia = import ./caelestia.nix {inherit config hyprland color;};
};
services = {
dunst = import ./dunst.nix {inherit pkgs config hyprland color;};
hypridle = import ./hypridle.nix {inherit config hyprland color;};
hyprpaper = import ./hyprpaper.nix {inherit config hyprland color;};
};
# Make sure the units only start when using Hyprland
systemd.user.services.dunst.Unit.After = lib.mkIf hyprland.dunst.enable (lib.mkForce ["hyprland-session.target"]);
systemd.user.services.dunst.Unit.PartOf = lib.mkIf hyprland.dunst.enable (lib.mkForce ["hyprland-session.target"]);
systemd.user.services.hypridle.Install.WantedBy = lib.mkIf (!hyprland.caelestia.enable) (lib.mkForce ["hyprland-session.target"]);
systemd.user.services.hypridle.Unit.After = lib.mkIf (!hyprland.caelestia.enable) (lib.mkForce ["hyprland-session.target"]);
systemd.user.services.hypridle.Unit.PartOf = lib.mkIf (!hyprland.caelestia.enable) (lib.mkForce ["hyprland-session.target"]);
systemd.user.services.hyprpaper.Install.WantedBy = lib.mkIf (!hyprland.caelestia.enable) (lib.mkForce ["hyprland-session.target"]);
systemd.user.services.hyprpaper.Unit.After = lib.mkIf (!hyprland.caelestia.enable) (lib.mkForce ["hyprland-session.target"]);
systemd.user.services.hyprpaper.Unit.PartOf = lib.mkIf (!hyprland.caelestia.enable) (lib.mkForce ["hyprland-session.target"]);
wayland.windowManager.hyprland = {
enable = true;
package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland;
portalPackage = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland;
systemd.enable = true; # Enable hyprland-session.target
systemd.variables = ["--all"]; # Import PATH into systemd
xwayland.enable = true;
plugins = builtins.concatLists [
(lib.optionals
hyprland.bars.enable
[inputs.hyprland-plugins.packages.${pkgs.stdenv.hostPlatform.system}.hyprbars])
(lib.optionals
hyprland.dynamicCursor.enable
[inputs.hypr-dynamic-cursors.packages.${pkgs.stdenv.hostPlatform.system}.hypr-dynamic-cursors])
(lib.optionals
hyprland.trails.enable
[inputs.hyprland-plugins.packages.${pkgs.stdenv.hostPlatform.system}.hyprtrails])
(lib.optionals
hyprland.hyprspace.enable
[inputs.hyprspace.packages.${pkgs.stdenv.hostPlatform.system}.Hyprspace])
];
settings = import ./settings.nix {
inherit
lib
config
hyprland
color
always-exec
always-bind
always-bindm
;
};
};
};
}

View File

@ -1,36 +0,0 @@
{
pkgs,
config,
hyprland,
color,
}: {
enable = hyprland.dunst.enable;
iconTheme.package = color.iconPackage;
iconTheme.name = color.iconTheme;
settings = {
global = {
monitor = config.homemodules.waybar.monitor;
font = "${color.font} 11";
offset = "10x10";
background = color.hexS.base;
foreground = color.hexS.text;
frame_width = 2;
corner_radius = 6;
separator_color = "frame";
};
urgency_low = {
frame_color = color.hexS.green;
};
urgency_normal = {
frame_color = color.hexS.green;
};
urgency_critical = {
frame_color = color.hexS.red;
};
};
}

View File

@ -1,28 +0,0 @@
{
config,
hyprland,
color,
}: {
enable = !hyprland.caelestia.enable;
settings = {
general = {
# DPMS - Display Powermanagement Signaling. "On" means the monitor is on.
after_sleep_cmd = "hyprctl dispatch dpms on";
ignore_dbus_inhibit = false;
lock_cmd = "hyprlock";
};
listener = [
{
timeout = 900;
on-timeout = "hyprlock";
}
{
timeout = 1200;
on-timeout = "hyprctl dispatch dpms off";
on-resume = "hyprctl dispatch dpms on";
}
];
};
}

View File

@ -1,74 +0,0 @@
{
config,
hyprland,
color,
}: {
enable = true;
settings = {
general = {
disable_loading_bar = true;
grace = 0; # Immediately lock
hide_cursor = true;
no_fade_in = false;
};
# The widgets start here.
background = [
{
path = "${config.paths.nixflake}/wallpapers/${color.wallpaper}.jpg";
blur_passes = 3;
blur_size = 10;
monitor = "";
}
];
input-field = [
# Password input
{
size = "200, 50";
position = "0, 0";
monitor = "";
dots_center = true;
fade_on_empty = false;
font_color = "rgb(${color.hex.accentText})";
font_family = "${color.font}";
inner_color = "rgb(${color.hex.accent})";
outer_color = "rgb(${color.hex.accent})";
outline_thickness = 2;
placeholder_text = "<span foreground='\#\#${color.hex.accentText}'>Password...</span>";
shadow_passes = 0;
rounding = 4;
halign = "center";
valign = "center";
}
];
label = [
# Date
{
position = "0, 300";
monitor = "";
text = ''cmd[update:1000] date -I'';
color = "rgba(${color.hex.text}AA)";
font_size = 22;
font_family = "${color.font}";
halign = "center";
valign = "center";
}
# Time
{
position = "0, 200";
monitor = "";
text = ''cmd[update:1000] date +"%-H:%M"'';
color = "rgba(${color.hex.text}AA)";
font_size = 95;
font_family = "${color.font} Extrabold";
halign = "center";
valign = "center";
}
];
};
}

View File

@ -1,28 +0,0 @@
{
config,
hyprland,
color,
}: {
enable = !hyprland.caelestia.enable;
settings = {
ipc = "on";
splash = false;
splash_offset = 2.0;
# Wallpapers have to be preloaded to be displayed
preload = let
mkPreload = name: "${config.paths.nixflake}/wallpapers/${name}.jpg";
in
color.wallpapers |> builtins.map mkPreload;
wallpaper = let
mkWallpaper = monitor:
"${monitor}, "
+ "${config.paths.nixflake}/wallpapers/${color.wallpaper}.jpg";
in
hyprland.monitors
|> builtins.attrNames
|> builtins.map mkWallpaper;
};
}

View File

@ -1,77 +0,0 @@
{
lib,
config,
hyprland,
}:
lib.mergeAttrsList [
{
# Hyprland control
"$mainMod, q" = ["killactive"];
"$mainMod, v" = ["togglefloating"];
"$mainMod, f" = ["fullscreen"];
"$mainMod, tab" = ["workspace, previous"];
# "$mainMod, g" = ["togglegroup"];
# "ALT, tab" = ["changegroupactive"];
# Move focus with mainMod + arrow keys
"$mainMod, h" = ["movefocus, l"];
"$mainMod, l" = ["movefocus, r"];
"$mainMod, k" = ["movefocus, u"];
"$mainMod, j" = ["movefocus, d"];
# Swap windows
"$mainMod CTRL, h" = ["movewindow, l"];
"$mainMod CTRL, l" = ["movewindow, r"];
"$mainMod CTRL, k" = ["movewindow, u"];
"$mainMod CTRL, d" = ["movewindow, d"];
# Reset workspaces to the defined configuration in hyprland.workspaces:
"CTRL ALT, r" = let
mkWBinding = m: w:
"moveworkspacetomonitor, "
+ "${builtins.toString w} ${builtins.toString m}";
mkWsBindings = m: ws: builtins.map (mkWBinding m) ws;
in
hyprland.workspaces
|> builtins.mapAttrs mkWsBindings
|> builtins.attrValues
|> builtins.concatLists;
}
# Switch to WS: "$mainMod, 1" = ["workspace, 1"];
(let
mkWBinding = w: k: {"$mainMod, ${k}" = ["workspace, ${w}"];};
in
hyprland.keybindings.ws-bindings
|> builtins.mapAttrs mkWBinding
|> builtins.attrValues
|> lib.mergeAttrsList)
# Toggle special WS: "$mainMod, x" = ["togglespecialworkspace, ferdium"];
(let
mkSpecialWBinding = w: k: {"$mainMod, ${k}" = ["togglespecialworkspace, ${w}"];};
in
hyprland.keybindings.special-ws-bindings
|> builtins.mapAttrs mkSpecialWBinding
|> builtins.attrValues
|> lib.mergeAttrsList)
# Move to WS: "$mainMod SHIFT, 1" = ["movetoworkspace, 1"];
(let
mkMoveWBinding = w: k: {"$mainMod SHIFT, ${k}" = ["movetoworkspace, ${w}"];};
in
(hyprland.keybindings.ws-bindings)
|> builtins.mapAttrs mkMoveWBinding
|> builtins.attrValues
|> lib.mergeAttrsList)
# Move to special WS: "$mainMod SHIFT, x" = ["movetoworkspace, special:ferdium"];
(let
mkSpecialMoveWBinding = w: k: {"$mainMod SHIFT, ${k}" = ["movetoworkspace, special:${w}"];};
in
hyprland.keybindings.special-ws-bindings
|> builtins.mapAttrs mkSpecialMoveWBinding
|> builtins.attrValues
|> lib.mergeAttrsList)
]

View File

@ -1,359 +0,0 @@
{
lib,
config,
hyprland,
color,
always-exec,
always-bind,
always-bindm,
}: {
"$mainMod" = "${hyprland.keybindings.main-mod}";
general = {
gaps_in = 5;
gaps_out = 10;
border_size = 2;
"col.active_border" = "rgb(${color.hex.accent})";
"col.inactive_border" = "rgb(${color.hex.base})";
};
group = {
groupbar = {
enabled = true;
render_titles = false;
font_size = 10;
gradients = false;
"col.active" = "rgb(${color.hex.accent})";
"col.inactive" = "rgb(${color.hex.base})";
};
"col.border_active" = "rgb(${color.hex.accent})";
"col.border_inactive" = "rgb(${color.hex.base})";
};
input = {
kb_layout = hyprland.keyboard.layout;
kb_variant = hyprland.keyboard.variant;
kb_options = hyprland.keyboard.option;
kb_model = "pc104";
kb_rules = "";
follow_mouse = true;
touchpad = {
natural_scroll = "no";
};
sensitivity = 0; # -1.0 - 1.0, 0 means no modification.
};
monitor = let
mkMonitor = name: conf:
"${name}, "
+ "${builtins.toString conf.width}x${builtins.toString conf.height}@"
+ "${builtins.toString conf.rate}, "
+ "${builtins.toString conf.x}x${builtins.toString conf.y}, "
+ "${builtins.toString conf.scale}";
in
hyprland.monitors
|> builtins.mapAttrs mkMonitor
|> builtins.attrValues;
workspace = let
mkWorkspace = monitor: workspace:
"${builtins.toString workspace}, "
+ "monitor:${builtins.toString monitor}";
mkWorkspaces = monitor: workspace-list:
builtins.map (mkWorkspace monitor) workspace-list;
in
hyprland.workspaces
|> builtins.mapAttrs mkWorkspaces
|> builtins.attrValues
|> builtins.concatLists;
bind = let
mkBind = key: action: "${key}, ${action}";
mkBinds = key: actions: builtins.map (mkBind key) actions;
in
(hyprland.keybindings.bindings // always-bind)
|> builtins.mapAttrs mkBinds
|> builtins.attrValues
|> builtins.concatLists;
bindm = let
mkBind = key: action: "${key}, ${action}";
mkBinds = key: actions: builtins.map (mkBind key) actions;
in
always-bindm
|> builtins.mapAttrs mkBinds
|> builtins.attrValues
|> builtins.concatLists;
exec-once = let
mkDelayedStart = str: ''hyprctl dispatch exec "sleep 5s && ${str}"'';
mkSpecialSilentStart = w: str: "[workspace special:${w} silent] ${str}";
mkSpecialSilentStarts = w: strs: builtins.map (mkSpecialSilentStart w) strs;
in
lib.mkMerge [
always-exec
hyprland.autostart.immediate
(hyprland.autostart.special-silent
|> builtins.mapAttrs mkSpecialSilentStarts
|> builtins.attrValues
|> builtins.concatLists)
(hyprland.autostart.delayed
|> builtins.map mkDelayedStart)
];
windowrule = let
mkWorkspaceRule = workspace: class:
"match:class ^(${class})$, "
+ "workspace ${workspace}";
mkWorkspaceRules = workspace: class-list:
builtins.map (mkWorkspaceRule workspace) class-list;
mkFloatingRule = attrs:
(lib.optionalString (builtins.hasAttr "class" attrs) "match:class ^(${attrs.class})$, ")
+ (lib.optionalString (builtins.hasAttr "title" attrs) "match:title ^(${attrs.title})$, ")
+ "float 1";
mkTranslucentRule = class:
"match:class ^(${class})$, "
+ "opacity ${hyprland.transparent-opacity} ${hyprland.transparent-opacity}";
in
lib.mkMerge [
(hyprland.workspacerules
|> builtins.mapAttrs mkWorkspaceRules
|> builtins.attrValues
|> builtins.concatLists)
(hyprland.floating
|> builtins.map mkFloatingRule)
(hyprland.transparent
|> builtins.map mkTranslucentRule)
hyprland.windowrules
];
dwindle = {
pseudotile = true;
preserve_split = true;
};
master = {
new_status = "master";
};
gesture = [
"3, horizontal, workspace" # 3 Fingers, horizontal, workspace swipe
];
misc = {
# Say no to the anime girl
disable_hyprland_logo = true;
force_default_wallpaper = 0;
# Say no to the "Application not responding" window
enable_anr_dialog = false;
disable_splash_rendering = true;
font_family = "${color.font}";
};
# Because those are not windows, but layers,
# we have to blur them explicitly
layerrule = [
"match:class rofi, blur 1"
# "match:class rofi, ignore_alpha 0.001" # Fix pixelated corners
# "match:class rofi, xray 0" # Render on top of other windows
# "match:class rofi, dim_around 1"
"match:class waybar, blur 1"
"match:class gtk4-layer-shell, blur 1"
"match:class bar-0, blur 1"
"match:class bar-1, blur 1"
];
decoration = {
rounding = 4;
shadow = {
enabled = false;
};
blur = {
enabled = true;
size = 10;
passes = 3;
new_optimizations = true;
ignore_opacity = true;
xray = true;
};
};
animations = {
enabled = true;
bezier = "myBezier, 0.05, 0.9, 0.1, 1.05";
animation = [
"windows, 1, 7, myBezier"
"windowsOut, 1, 7, default,popin 80%"
"border, 1, 10, default"
"borderangle, 1, 8, default"
"fade, 1, 7, default"
"workspaces, 1, 6, default"
];
};
plugin = lib.mergeAttrsList [
(lib.optionalAttrs hyprland.bars.enable {
hyprbars = {
enabled = true;
bar_height = 25;
bar_blur = true;
bar_color = "rgb(${color.hex.base})";
col.text = "rgb(${color.hex.text})";
bar_title_enabled = true;
bar_text_size = 12;
bar_text_font = color.font;
bar_text_align = "center";
bar_buttons_alignment = "left";
bar_part_of_window = true;
bar_precedence_over_border = false;
# example buttons (R -> L)
# hyprbars-button = color, size, on-click
hyprbars-button = [
"rgb(${color.hex.red}), 10, 󰖭, hyprctl dispatch killactive"
"rgb(${color.hex.green}), 10, , hyprctl dispatch fullscreen 1"
];
# cmd to run on double click of the bar
on_double_click = "hyprctl dispatch fullscreen 1";
};
})
(lib.optionalAttrs hyprland.dynamicCursor.enable {
dynamic-cursors = {
# enables the plugin
enabled = true;
# sets the cursor behaviour, supports these values:
# tilt - tilt the cursor based on x-velocity
# rotate - rotate the cursor based on movement direction
# stretch - stretch the cursor shape based on direction and velocity
# none - do not change the cursors behaviour
mode = "rotate";
# minimum angle difference in degrees after which the shape is changed
# smaller values are smoother, but more expensive for hw cursors
threshold = 2;
# for mode = rotate
rotate = {
# length in px of the simulated stick used to rotate the cursor
# most realistic if this is your actual cursor size
length = 20;
# clockwise offset applied to the angle in degrees
# this will apply to ALL shapes
offset = 0.0;
};
# for mode = tilt
tilt = {
# controls how powerful the tilt is, the lower, the more power
# this value controls at which speed (px/s) the full tilt is reached
# the full tilt being 60° in both directions
limit = 1000;
# relationship between speed and tilt, supports these values:
# linear - a linear function is used
# quadratic - a quadratic function is used (most realistic to actual air drag)
# negative_quadratic - negative version of the quadratic one, feels more aggressive
# see `activation` in `src/mode/utils.cpp` for how exactly the calculation is done
function = "negative_quadratic";
# time window (ms) over which the speed is calculated
# higher values will make slow motions smoother but more delayed
window = 100;
};
# configure shake to find
# magnifies the cursor if its is being shaken
shake = {
# enables shake to find
enabled = false;
# use nearest-neighbour (pixelated) scaling when shaking
# may look weird when effects are enabled
nearest = true;
# controls how soon a shake is detected
# lower values mean sooner
threshold = 3.0;
# magnification level immediately after shake start
base = 1.5;
# magnification increase per second when continuing to shake
speed = 0.0;
# how much the speed is influenced by the current shake intensitiy
influence = 0.0;
# maximal magnification the cursor can reach
# values below 1 disable the limit (e.g. 0)
limit = 0.0;
# time in millseconds the cursor will stay magnified after a shake has ended
timeout = 1000;
# show cursor behaviour `tilt`, `rotate`, etc. while shaking
effects = true;
# enable ipc events for shake
# see the `ipc` section below
ipc = false;
};
# use hyprcursor to get a higher resolution texture when the cursor is magnified
# see the `hyprcursor` section below
hyprcursor = {
# use nearest-neighbour (pixelated) scaling when magnifing beyond texture size
# this will also have effect without hyprcursor support being enabled
# 0 / false - never use pixelated scaling
# 1 / true - use pixelated when no highres image
# 2 - always use pixleated scaling
nearest = true;
# enable dedicated hyprcursor support
enabled = true;
# resolution in pixels to load the magnified shapes at
# be warned that loading a very high-resolution image will take a long time and might impact memory consumption
# -1 means we use [normal cursor size] * [shake:base option]
resolution = -1;
# shape to use when clientside cursors are being magnified
# see the shape-name property of shape rules for possible names
# specifying clientside will use the actual shape, but will be pixelated
fallback = "clientside";
};
};
})
(lib.optionalAttrs hyprland.trails.enable {
hyprtrails = {
color = "rgb(${color.hex.accent})";
};
})
(lib.optionalAttrs hyprland.hyprspace.enable {
overview = {};
})
];
}

View File

@ -1,10 +0,0 @@
{
lib,
mylib,
...
}:
with lib;
with mylib.modules; {
enable = mkEnableOption "Enable Hyprpanel";
systemd.enable = mkEnableOption "Start using systemd";
}

View File

@ -1,664 +0,0 @@
{
config,
color,
}: {
enable = true;
systemd = {
enable = false;
restartIfChanged = true;
};
# Deprecated
# enableClipboard = true;
# enableBrightnessControl = false;
# enableColorPicker = true;
# enableSystemSound = false;
enableSystemMonitoring = true;
enableVPN = true;
enableDynamicTheming = false;
enableAudioWavelength = true;
enableCalendarEvents = false;
niri = {
enableKeybinds = false;
enableSpawn = false;
};
# This is generated from the DMS settings dialog.
# Run: nix eval --impure --expr 'builtins.fromJSON (builtins.readFile ~/.config/DankMaterialShell/settings.json)'
settings = {
acLockTimeout = 0;
acMonitorTimeout = 0;
acProfileName = "";
acSuspendBehavior = 0;
acSuspendTimeout = 0;
activeDisplayProfile = {};
animationSpeed = 1;
appDrawerSectionViewModes = {};
appIdSubstitutions = [
{
pattern = "Spotify";
replacement = "spotify";
type = "exact";
}
{
pattern = "beepertexts";
replacement = "beeper";
type = "exact";
}
{
pattern = "home assistant desktop";
replacement = "homeassistant-desktop";
type = "exact";
}
{
pattern = "com.transmissionbt.transmission";
replacement = "transmission-gtk";
type = "contains";
}
{
pattern = "^steam_app_(\\d+)$";
replacement = "steam_icon_$1";
type = "regex";
}
];
appLauncherGridColumns = 4;
appLauncherViewMode = "list";
appPickerViewMode = "grid";
appsDockActiveColorMode = "primary";
appsDockColorizeActive = false;
appsDockEnlargeOnHover = false;
appsDockEnlargePercentage = 125;
appsDockHideIndicators = false;
appsDockIconSizePercentage = 100;
audioInputDevicePins = {};
audioOutputDevicePins = {};
audioScrollMode = "volume";
audioVisualizerEnabled = true;
audioWheelScrollAmount = 5;
barConfigs = [
{
autoHide = false;
autoHideDelay = 250;
borderColor = "surfaceText";
borderEnabled = false;
borderOpacity = 1;
borderThickness = 2;
bottomGap = 0;
centerWidgets = [
{
enabled = true;
id = "music";
mediaSize = 1;
}
];
enabled = true;
fontScale = 1.1;
gothCornerRadiusOverride = false;
gothCornerRadiusValue = 12;
gothCornersEnabled = false;
id = "default";
innerPadding = 4;
leftWidgets = [
{
enabled = true;
id = "launcherButton";
}
{
enabled = true;
id = "workspaceSwitcher";
}
{
enabled = true;
focusedWindowCompactMode = true;
id = "focusedWindow";
}
];
maximizeDetection = true;
name = "Main Bar";
noBackground = false;
openOnOverview = true;
popupGapsAuto = true;
popupGapsManual = 4;
position = 0;
rightWidgets = [
{
enabled = true;
id = "privacyIndicator";
}
{
enabled = true;
id = "cpuUsage";
minimumWidth = true;
}
{
enabled = true;
id = "memUsage";
minimumWidth = true;
}
{
enabled = true;
id = "diskUsage";
}
{
enabled = true;
id = "colorPicker";
}
{
enabled = true;
id = "clipboard";
}
{
enabled = true;
id = "vpn";
}
{
enabled = true;
id = "controlCenterButton";
}
{
enabled = true;
id = "systemTray";
}
{
clockCompactMode = true;
enabled = true;
id = "clock";
}
{
enabled = true;
id = "notificationButton";
}
];
screenPreferences = ["all"];
showOnLastDisplay = true;
spacing = 0;
squareCorners = true;
transparency = 1;
visible = true;
widgetOutlineColor = "primary";
widgetOutlineEnabled = false;
widgetOutlineOpacity = 1;
widgetOutlineThickness = 2;
widgetTransparency = 1;
}
];
barMaxVisibleApps = 0;
barMaxVisibleRunningApps = 0;
barShowOverflowBadge = true;
batteryChargeLimit = 100;
batteryLockTimeout = 0;
batteryMonitorTimeout = 0;
batteryProfileName = "";
batterySuspendBehavior = 0;
batterySuspendTimeout = 0;
bluetoothDevicePins = {};
blurWallpaperOnOverview = true;
blurredWallpaperLayer = true;
brightnessDevicePins = {};
browserPickerViewMode = "grid";
browserUsageHistory = {};
builtInPluginSettings = {dms_settings_search = {trigger = "?";};};
buttonColorMode = "primary";
centeringMode = "index";
clipboardEnterToPaste = false;
clockCompactMode = false;
clockDateFormat = "yyyy-MM-dd";
configVersion = 5;
controlCenterShowAudioIcon = true;
controlCenterShowAudioPercent = false;
controlCenterShowBatteryIcon = false;
controlCenterShowBluetoothIcon = true;
controlCenterShowBrightnessIcon = false;
controlCenterShowBrightnessPercent = false;
controlCenterShowMicIcon = true;
controlCenterShowMicPercent = false;
controlCenterShowNetworkIcon = true;
controlCenterShowPrinterIcon = false;
controlCenterShowScreenSharingIcon = true;
controlCenterShowVpnIcon = true;
controlCenterTileColorMode = "primary";
controlCenterWidgets = [
{
enabled = true;
id = "volumeSlider";
width = 50;
}
{
enabled = true;
id = "brightnessSlider";
width = 50;
}
{
enabled = true;
id = "wifi";
width = 50;
}
{
enabled = true;
id = "bluetooth";
width = 50;
}
{
enabled = true;
id = "audioOutput";
width = 50;
}
{
enabled = true;
id = "audioInput";
width = 50;
}
{
enabled = true;
id = "nightMode";
width = 50;
}
{
enabled = true;
id = "darkMode";
width = 50;
}
];
cornerRadius = 10;
currentThemeCategory = "registry";
currentThemeName = "custom";
cursorSettings = {
dwl = {cursorHideTimeout = 0;};
hyprland = {
hideOnKeyPress = false;
hideOnTouch = false;
inactiveTimeout = 0;
};
niri = {
hideAfterInactiveMs = 0;
hideWhenTyping = false;
};
size = 24;
theme = "System Default";
};
customAnimationDuration = 500;
customPowerActionHibernate = "";
customPowerActionLock = "";
customPowerActionLogout = "";
customPowerActionPowerOff = "";
customPowerActionReboot = "";
customPowerActionSuspend = "";
customThemeFile = "/home/christoph/NixFlake/config/dankmaterialshell/catppuccin-mauve.json";
dankLauncherV2BorderColor = "primary";
dankLauncherV2BorderEnabled = false;
dankLauncherV2BorderThickness = 2;
dankLauncherV2ShowFooter = true;
dankLauncherV2Size = "compact";
dankLauncherV2UnloadOnClose = false;
desktopClockColorMode = "primary";
desktopClockCustomColor = {
a = 1;
b = 1;
g = 1;
hslHue = -1;
hslLightness = 1;
hslSaturation = 0;
hsvHue = -1;
hsvSaturation = 0;
hsvValue = 1;
r = 1;
valid = true;
};
desktopClockDisplayPreferences = ["all"];
desktopClockEnabled = false;
desktopClockHeight = 180;
desktopClockShowAnalogNumbers = false;
desktopClockShowAnalogSeconds = true;
desktopClockShowDate = true;
desktopClockStyle = "analog";
desktopClockTransparency = 0.8;
desktopClockWidth = 280;
desktopClockX = -1;
desktopClockY = -1;
desktopWidgetGridSettings = {};
desktopWidgetGroups = [];
desktopWidgetInstances = [];
desktopWidgetPositions = {};
displayNameMode = "system";
displayProfileAutoSelect = false;
displayProfiles = {};
displayShowDisconnected = false;
displaySnapToEdge = true;
dockAutoHide = false;
dockBorderColor = "surfaceText";
dockBorderEnabled = false;
dockBorderOpacity = 1;
dockBorderThickness = 1;
dockBottomGap = 0;
dockGroupByApp = false;
dockIconSize = 40;
dockIndicatorStyle = "circle";
dockIsolateDisplays = false;
dockLauncherEnabled = false;
dockLauncherLogoBrightness = 0.5;
dockLauncherLogoColorOverride = "";
dockLauncherLogoContrast = 1;
dockLauncherLogoCustomPath = "";
dockLauncherLogoMode = "apps";
dockLauncherLogoSizeOffset = 0;
dockMargin = 0;
dockMaxVisibleApps = 0;
dockMaxVisibleRunningApps = 0;
dockOpenOnOverview = false;
dockPosition = 1;
dockShowOverflowBadge = true;
dockSmartAutoHide = false;
dockSpacing = 4;
dockTransparency = 1;
dwlShowAllTags = false;
enableFprint = false;
enableRippleEffects = true;
enabledGpuPciIds = [];
fadeToDpmsEnabled = true;
fadeToDpmsGracePeriod = 5;
fadeToLockEnabled = true;
fadeToLockGracePeriod = 5;
filePickerUsageHistory = {};
focusedWindowCompactMode = false;
fontFamily = "MonoLisa Normal";
fontScale = 1;
fontWeight = 500;
groupWorkspaceApps = true;
gtkThemingEnabled = false;
hideBrightnessSlider = false;
hyprlandLayoutBorderSize = -1;
hyprlandLayoutGapsOverride = -1;
hyprlandLayoutRadiusOverride = -1;
hyprlandOutputSettings = {};
iconTheme = "System Default";
keyboardLayoutNameCompactMode = false;
launchPrefix = "";
launcherLogoBrightness = 0.5;
launcherLogoColorInvertOnMode = false;
launcherLogoColorOverride = "";
launcherLogoContrast = 1;
launcherLogoCustomPath = "";
launcherLogoMode = "os";
launcherLogoSizeOffset = 0;
launcherPluginOrder = [];
launcherPluginVisibility = {};
lockAtStartup = false;
lockBeforeSuspend = false;
lockDateFormat = "yyyy-MM-dd";
lockScreenActiveMonitor = "all";
lockScreenInactiveColor = "#000000";
lockScreenNotificationMode = 0;
lockScreenPowerOffMonitorsOnLock = false;
lockScreenShowDate = true;
lockScreenShowMediaPlayer = true;
lockScreenShowPasswordField = true;
lockScreenShowPowerActions = true;
lockScreenShowProfileImage = true;
lockScreenShowSystemIcons = true;
lockScreenShowTime = true;
loginctlLockIntegration = true;
mangoLayoutBorderSize = -1;
mangoLayoutGapsOverride = -1;
mangoLayoutRadiusOverride = -1;
matugenScheme = "scheme-tonal-spot";
matugenTargetMonitor = "";
matugenTemplateAlacritty = true;
matugenTemplateDgop = true;
matugenTemplateEmacs = true;
matugenTemplateEquibop = true;
matugenTemplateFirefox = true;
matugenTemplateFoot = true;
matugenTemplateGhostty = true;
matugenTemplateGtk = true;
matugenTemplateHyprland = true;
matugenTemplateKcolorscheme = true;
matugenTemplateKitty = true;
matugenTemplateMangowc = true;
matugenTemplateNeovim = true;
matugenTemplateNiri = true;
matugenTemplatePywalfox = true;
matugenTemplateQt5ct = true;
matugenTemplateQt6ct = true;
matugenTemplateVesktop = true;
matugenTemplateVscode = true;
matugenTemplateWezterm = true;
matugenTemplateZenBrowser = true;
maxFprintTries = 15;
maxWorkspaceIcons = 3;
mediaSize = 1;
modalAnimationSpeed = 1;
modalCustomAnimationDuration = 150;
modalDarkenBackground = true;
monoFontFamily = "MonoLisa Normal";
networkPreference = "auto";
nightModeEnabled = false;
niriLayoutBorderSize = -1;
niriLayoutGapsOverride = -1;
niriLayoutRadiusOverride = -1;
niriOutputSettings = {};
niriOverviewOverlayEnabled = true;
notepadFontFamily = "";
notepadFontSize = 14;
notepadLastCustomTransparency = 0.7;
notepadShowLineNumbers = false;
notepadTransparencyOverride = -1;
notepadUseMonospace = true;
notificationAnimationSpeed = 1;
notificationCompactMode = false;
notificationCustomAnimationDuration = 400;
notificationHistoryEnabled = true;
notificationHistoryMaxAgeDays = 7;
notificationHistoryMaxCount = 50;
notificationHistorySaveCritical = true;
notificationHistorySaveLow = true;
notificationHistorySaveNormal = true;
notificationOverlayEnabled = false;
notificationPopupPosition = 0;
notificationPopupPrivacyMode = false;
notificationPopupShadowEnabled = true;
notificationRules = [];
notificationTimeoutCritical = 0;
notificationTimeoutLow = 5000;
notificationTimeoutNormal = 5000;
osdAlwaysShowValue = true;
osdAudioOutputEnabled = true;
osdBrightnessEnabled = true;
osdCapsLockEnabled = true;
osdIdleInhibitorEnabled = true;
osdMediaPlaybackEnabled = true;
osdMediaVolumeEnabled = true;
osdMicMuteEnabled = true;
osdPosition = 7;
osdPowerProfileEnabled = false;
osdVolumeEnabled = true;
padHours12Hour = false;
popoutAnimationSpeed = 1;
popoutCustomAnimationDuration = 150;
popupTransparency = 1;
powerActionConfirm = true;
powerActionHoldDuration = 0.5;
powerMenuActions = ["reboot" "logout" "poweroff" "lock" "restart"];
powerMenuDefaultAction = "poweroff";
powerMenuGridLayout = false;
privacyShowCameraIcon = false;
privacyShowMicIcon = false;
privacyShowScreenShareIcon = false;
qtThemingEnabled = false;
registryThemeVariants = {};
reverseScrolling = false;
runDmsMatugenTemplates = false;
runUserMatugenTemplates = false;
runningAppsCompactMode = true;
runningAppsCurrentMonitor = false;
runningAppsCurrentWorkspace = false;
runningAppsGroupByApp = false;
screenPreferences = {};
scrollTitleEnabled = true;
selectedGpuIndex = 0;
showBattery = false;
showCapsLockIndicator = false;
showClipboard = true;
showClock = true;
showControlCenterButton = true;
showCpuTemp = true;
showCpuUsage = true;
showDock = false;
showFocusedWindow = true;
showGpuTemp = false;
showLauncherButton = true;
showMemUsage = true;
showMusic = true;
showNotificationButton = true;
showOccupiedWorkspacesOnly = false;
showOnLastDisplay = {};
showPrivacyButton = false;
showSeconds = true;
showSystemTray = true;
showWeather = true;
showWorkspaceApps = false;
showWorkspaceIndex = false;
showWorkspaceName = false;
showWorkspacePadding = false;
showWorkspaceSwitcher = true;
sortAppsAlphabetically = false;
soundNewNotification = true;
soundPluggedIn = true;
soundVolumeChanged = true;
soundsEnabled = false;
spotlightCloseNiriOverview = true;
spotlightModalViewMode = "list";
spotlightSectionViewModes = {};
syncComponentAnimationSpeeds = true;
syncModeWithPortal = true;
systemMonitorColorMode = "primary";
systemMonitorCustomColor = {
a = 1;
b = 1;
g = 1;
hslHue = -1;
hslLightness = 1;
hslSaturation = 0;
hsvHue = -1;
hsvSaturation = 0;
hsvValue = 1;
r = 1;
valid = true;
};
systemMonitorDisplayPreferences = ["all"];
systemMonitorEnabled = false;
systemMonitorGpuPciId = "";
systemMonitorGraphInterval = 60;
systemMonitorHeight = 480;
systemMonitorLayoutMode = "auto";
systemMonitorShowCpu = true;
systemMonitorShowCpuGraph = true;
systemMonitorShowCpuTemp = true;
systemMonitorShowDisk = true;
systemMonitorShowGpuTemp = false;
systemMonitorShowHeader = true;
systemMonitorShowMemory = true;
systemMonitorShowMemoryGraph = true;
systemMonitorShowNetwork = true;
systemMonitorShowNetworkGraph = true;
systemMonitorShowTopProcesses = false;
systemMonitorTopProcessCount = 3;
systemMonitorTopProcessSortBy = "cpu";
systemMonitorTransparency = 0.8;
systemMonitorVariants = [];
systemMonitorWidth = 320;
systemMonitorX = -1;
systemMonitorY = -1;
terminalsAlwaysDark = false;
updaterCustomCommand = "";
updaterHideWidget = false;
updaterTerminalAdditionalParams = "";
updaterUseCustomCommand = false;
use24HourClock = true;
useAutoLocation = false;
useFahrenheit = false;
useSystemSoundTheme = false;
wallpaperFillMode = "Fill";
waveProgressEnabled = true;
weatherEnabled = true;
widgetBackgroundColor = "sc";
widgetColorMode = "default";
wifiNetworkPins = {};
windSpeedUnit = "kmh";
workspaceAppIconSizeOffset = 0;
workspaceColorMode = "default";
workspaceDragReorder = true;
workspaceFocusedBorderColor = "primary";
workspaceFocusedBorderEnabled = false;
workspaceFocusedBorderThickness = 2;
workspaceFollowFocus = false;
workspaceNameIcons = {};
workspaceOccupiedColorMode = "none";
workspaceScrolling = false;
workspaceUnfocusedColorMode = "default";
workspaceUrgentColorMode = "default";
};
session = {
# Settings
doNotDisturb = false;
isLightMode = false;
weatherHourlyDetailed = true;
# Night
nightModeAutoEnabled = true;
nightModeAutoMode = "time";
nightModeEnabled = true;
nightModeEndHour = 6;
nightModeEndMinute = 0;
nightModeHighTemperature = 6500;
nightModeLocationProvider = "";
nightModeStartHour = 22;
nightModeStartMinute = 0;
nightModeTemperature = 5500;
nightModeUseIPLocation = false;
# Hardware
nonNvidiaGpuTempEnabled = false;
nvidiaGpuTempEnabled = false;
selectedGpuIndex = 0;
wifiDeviceOverride = "";
enabledGpuPciIds = [];
lastBrightnessDevice = "";
# Wallpapers
perModeWallpaper = false;
perMonitorWallpaper = false;
wallpaperCyclingEnabled = false;
wallpaperCyclingInterval = 300;
wallpaperCyclingMode = "interval";
wallpaperCyclingTime = "06:00";
wallpaperPath = "/home/christoph/NixFlake/wallpapers/Windows.jpg";
wallpaperPathDark = "";
wallpaperPathLight = "";
wallpaperTransition = "iris bloom";
# Random shit
includedTransitions = ["fade" "wipe" "disc" "stripes" "iris bloom" "pixelate" "portal"];
launchPrefix = "";
latitude = 0;
longitude = 0;
pinnedApps = [];
hiddenTrayIds = [];
recentColors = [];
showThirdPartyPlugins = true;
# Ultra random shit
monitorCyclingSettings = {};
monitorWallpapers = {};
monitorWallpapersDark = {};
monitorWallpapersLight = {};
brightnessExponentValues = {};
brightnessExponentialDevices = {};
brightnessUserSetValues = {};
configVersion = 1;
};
}

View File

@ -1,598 +0,0 @@
{
config,
nixosConfig,
lib,
mylib,
inputs,
pkgs,
...
}: let
inherit (config.homemodules) niri color;
in {
options.homemodules.niri = import ./options.nix {inherit lib mylib;};
config = lib.mkIf niri.enable rec {
assertions = [
{
assertion = nixosConfig.programs.niri.enable;
message = "Can't enable Niri config with Niri disabled!";
}
{
assertion = !(programs.noctalia-shell.enable && programs.dank-material-shell.enable);
message = "Can't enable Noctalia and DankMaterialShell at the same time!";
}
];
gtk = {
enable = true;
iconTheme.package = color.iconPackage;
iconTheme.name = color.iconTheme;
};
# Disable niri polkit if we use DMS, as it has its own
systemd.user.services.niri-flake-polkit = lib.mkForce {};
home = {
sessionVariables = {
QT_QPA_PLATFORMTHEME = "gtk3"; # For Noctalia
GDK_BACKEND = "wayland"; # For screen sharing
};
pointerCursor = {
gtk.enable = true;
x11.enable = true;
package = color.cursorPackage;
name = color.cursor;
size = color.cursorSize;
};
packages = with pkgs; [
xwayland-satellite
ncpamixer # Audio control
nautilus # Fallback file chooser used by xdg-desktop-portal-gnome
# In case we fallback to the default config
alacritty
fuzzel
];
};
programs = {
# TODO: Those should be modules with their own options
noctalia-shell = import ./noctalia.nix {inherit color;};
dank-material-shell = import ./dankMaterialShell.nix {inherit config color;};
dsearch.enable = true;
# TODO: Extract options
niri = {
# enable = true; # Enabled in system module
settings = {
input = {
focus-follows-mouse = {
enable = true;
max-scroll-amount = "0%"; # Skip partial windows that would scroll the viewport on focus
};
keyboard = {
xkb = {
layout = "us";
variant = "altgr-intl";
options = "nodeadkeys";
};
};
touchpad = {
click-method = "clickfinger";
tap = true;
drag = true;
dwt = true;
natural-scroll = true;
scroll-method = "two-finger";
};
};
hotkey-overlay = {
hide-not-bound = true;
skip-at-startup = true;
};
prefer-no-csd = true; # Disable client-side decorations (e.g. window titlebars)
spawn-at-startup = [
# TODO: Depend on options
# {argv = ["noctalia-shell"];}
{argv = ["dms" "run"];}
{argv = ["kitty" "--hold" "fastfetch"];}
{argv = ["zeal"];}
{argv = ["protonvpn-app"];}
{argv = ["fcitx5"];}
{argv = ["jellyfin-mpv-shim"];}
{sh = "sleep 5s && nextcloud --background";}
{sh = "sleep 5s && keepassxc";}
];
workspaces = {
"1" = {open-on-output = "DP-1";};
"2" = {open-on-output = "DP-1";};
"3" = {open-on-output = "DP-1";};
"4" = {open-on-output = "DP-1";};
"5" = {open-on-output = "DP-1";};
"6" = {open-on-output = "DP-1";};
"7" = {open-on-output = "DP-1";};
"8" = {open-on-output = "DP-1";};
"9" = {open-on-output = "DP-1";};
"10" = {open-on-output = "DP-2";};
};
outputs = {
"DP-1" = {
focus-at-startup = true;
mode = {
width = 3440;
height = 1440;
refresh = 164.999;
};
position = {
x = 1920;
y = 0;
};
};
"DP-2" = {
focus-at-startup = false;
mode = {
width = 1920;
height = 1080;
refresh = 60.0;
};
position = {
x = 0;
y = 0;
};
};
};
cursor = {
hide-when-typing = true;
theme = color.cursor;
size = color.cursorSize;
};
layout = {
# This border is drawn INSIDE the window
border = {
enable = true;
width = 2;
active = {color = color.hex.accent;};
inactive = {color = color.hex.base;};
};
# This border is drawn OUTSIDE of the focused window
focus-ring = {
enable = false;
};
# Hint where a dragged window will be inserted
insert-hint = {
enable = true;
display = {color = color.hex.accentDim;};
};
always-center-single-column = true;
# Gaps between windows
gaps = 8;
# Gaps at screen borders
struts = {
# left = 8;
# right = 8;
top = 4; # Somehow the bar eclusivity doesn't work as expected
bottom = 2;
};
};
gestures = {
hot-corners = {enable = false;};
};
window-rules = [
# Rules for all windows
{
default-column-width.proportion = 0.5;
default-window-height.proportion = 1.0;
# Rounded corners
clip-to-geometry = true;
geometry-corner-radius = {
bottom-left = 8.0;
bottom-right = 8.0;
top-left = 8.0;
top-right = 8.0;
};
# open-floating = false;
# open-focused = false;
# open-fullscreen = false;
# open-maximized = false;
# open-on-output = "DP-1";
# open-on-workspace = "2";
# opacity = 0.8;
}
# Rules for specific windows
{
matches = [{app-id = "Zotero";}];
open-on-workspace = "2";
}
{
matches = [{app-id = "neovide";}];
open-on-workspace = "2";
open-maximized = true;
}
{
matches = [{app-id = "code-url-handler";}];
open-on-workspace = "2";
open-floating = true;
}
{
matches = [{app-id = "obsidian";}];
open-on-workspace = "3";
}
{
matches = [{app-id = "firefox";}];
open-on-workspace = "4";
open-maximized = true;
}
{
matches = [{app-id = "Google-chrome";}];
open-on-workspace = "4";
}
{
matches = [{app-id = "chromium-browser";}];
open-on-workspace = "4";
}
{
matches = [{app-id = "org.qutebrowser.qutebrowser";}];
open-on-workspace = "4";
}
{
matches = [{app-id = "steam";}];
open-on-workspace = "5";
}
{
matches = [{app-id = "steam_app_(.+)";}];
open-on-workspace = "6";
open-floating = true;
open-maximized = true;
}
{
matches = [{app-id = "signal";}];
open-on-workspace = "7";
open-maximized = true;
}
{
matches = [{app-id = "discord";}];
open-on-workspace = "9";
open-maximized = true;
}
];
layer-rules = [
{
# Set the overview wallpaper on the backdrop (Noctalia).
matches = [{namespace = "^noctalia-overview*";}];
place-within-backdrop = true;
}
{
# Set the overview wallpaper on the backdrop (DMS).
matches = [{namespace = "^dms:blurwallpaper$";}];
place-within-backdrop = true;
}
];
debug = {
# Allows notification actions and window activation from Noctalia.
honor-xdg-activation-with-invalid-serial = [];
};
# TODO: Only start hypr... stuff with hyprland, not systemd (hypridle, hyprpaper currently)
# TODO: Move values to config option and set in home/christoph/niri.nix
binds = with config.lib.niri.actions; {
# Applications
"Mod+T" = {
action = spawn "kitty";
hotkey-overlay = {title = "Spawn Kitty.";};
};
"Mod+E" = {
action = spawn "kitty" "--title=Yazi" "yazi";
hotkey-overlay = {title = "Spawn Yazi.";};
};
"Mod+B" = {
action = spawn "kitty" "--title=Btop" "btop";
hotkey-overlay = {title = "Spawn Btop.";};
};
"Mod+R" = {
action = spawn "kitty" "--title=Rmpc" "rmpc";
hotkey-overlay = {title = "Spawn Rmpc.";};
};
"Mod+N" = {
action = spawn "neovide";
hotkey-overlay = {title = "Spawn Neovide.";};
};
"Mod+Ctrl+N" = {
action = spawn "kitty" "--title=Navi" "navi";
hotkey-overlay = {title = "Call Navi for help.";};
};
"Mod+Shift+N" = {
action = spawn "neovide" "${config.paths.dotfiles}/navi/christoph.cheat";
hotkey-overlay = {title = "Edit the Navi cheats.";};
};
"Mod+Shift+F" = {
action = spawn "neovide" "${config.paths.dotfiles}/flake.nix";
hotkey-overlay = {title = "Edit the NixFlake.";};
};
# TODO: Enable with Noctalia option
# Noctalia
# "Mod+A" = {
# action = spawn "noctalia-shell" "ipc" "call" "launcher" "toggle";
# hotkey-overlay = {title = "Toggle the application launcher.";};
# };
# "Mod+Ctrl+L" = {
# action = spawn "noctalia-shell" "ipc" "call" "lockScreen" "lock";
# hotkey-overlay = {title = "Lock the screen.";};
# };
# "Mod+W" = {
# action = spawn "noctalia-shell" "ipc" "call" "wallpaper" "toggle";
# hotkey-overlay = {title = "Toggle the wallpaper chooser.";};
# };
# "Mod+Escape" = {
# action = spawn "noctalia-shell" "ipc" "call" "sessionMenu" "toggle";
# hotkey-overlay = {title = "Toggle the session menu.";};
# };
# TODO: Enable with DMS option
# DankMaterialShell
"Mod+A" = {
action = spawn "dms" "ipc" "call" "spotlight" "toggle";
hotkey-overlay = {title = "Toggle the application launcher.";};
};
"Mod+Ctrl+L" = {
action = spawn "dms" "ipc" "call" "lock" "lock";
hotkey-overlay = {title = "Lock the screen.";};
};
"Mod+Escape" = {
action = spawn "dms" "ipc" "call" "powermenu" "toggle";
hotkey-overlay = {title = "Toggle the session menu.";};
};
"Mod+C" = {
action = spawn "dms" "ipc" "call" "clipboard" "toggle";
hotkey-overlay = {title = "Show clipboard history.";};
};
# Screenshots
"Mod+S" = {
action.screenshot-window = {write-to-disk = true;};
hotkey-overlay = {title = "Take a screenshot of the current window.";};
};
"Mod+Shift+S" = {
action.screenshot = {show-pointer = true;};
hotkey-overlay = {title = "Take a screenshot of a region.";};
};
# Niri
"Mod+Shift+Slash" = {
action = show-hotkey-overlay;
hotkey-overlay = {hidden = true;};
};
# "Alt+Tab" = {
# action = "next-window";
# hotkey-overlay = {title = "Switch to next window.";};
# };
# "Alt+Shift+Tab" = {
# action = "previous-window";
# hotkey-overlay = {title = "Switch to previous window.";};
# };
# Audio
"XF86AudioRaiseVolume" = {
action = spawn "wpctl" "set-volume" "-l" "1.5" "@DEFAULT_AUDIO_SINK@" "5%+";
hotkey-overlay = {hidden = true;};
};
"XF86AudioLowerVolume" = {
action = spawn "wpctl" "set-volume" "-l" "1.5" "@DEFAULT_AUDIO_SINK@" "5%-";
hotkey-overlay = {hidden = true;};
};
"XF86AudioPlay" = {
action = spawn "playerctl" "play-pause";
hotkey-overlay = {hidden = true;};
};
"XF86AudioPrev" = {
action = spawn "playerctl" "previous";
hotkey-overlay = {hidden = true;};
};
"XF86AudioNext" = {
action = spawn "playerctl" "next";
hotkey-overlay = {hidden = true;};
};
# Niri windows
"Mod+Q" = {
action = close-window;
hotkey-overlay = {title = "Close the current window.";};
};
"Mod+F" = {
action = fullscreen-window;
hotkey-overlay = {title = "Toggle between fullscreen and tiled window.";};
};
"Mod+Equal" = {
action = set-column-width "+10%";
hotkey-overlay = {title = "Increase column width";};
};
"Mod+Minus" = {
action = set-column-width "-10%";
hotkey-overlay = {title = "Decrease column width";};
};
"Mod+Shift+M" = {
action = set-column-width "50%";
hotkey-overlay = {title = "Set column width to 50%";};
};
"Mod+M" = {
action = maximize-column;
hotkey-overlay = {title = "Maximize column.";};
};
"Mod+Comma" = {
action = reset-window-height;
hotkey-overlay = {title = "Reset window height.";};
};
"Mod+V" = {
action = toggle-window-floating;
hotkey-overlay = {title = "Toggle between floating and tiled window.";};
};
"Mod+O" = {
action = toggle-overview;
hotkey-overlay = {title = "Toggle overlay.";};
};
"Mod+H" = {
action = focus-column-or-monitor-left;
hotkey-overlay = {title = "Focus column on the left. Equivalent bindings for other directions.";};
};
"Mod+J" = {
action = focus-window-or-workspace-down;
hotkey-overlay = {hidden = true;};
};
"Mod+K" = {
action = focus-window-or-workspace-up;
hotkey-overlay = {hidden = true;};
};
"Mod+L" = {
action = focus-column-or-monitor-right;
hotkey-overlay = {hidden = true;};
};
"Mod+WheelScrollUp" = {
action = focus-column-left;
hotkey-overlay = {title = "Focus column on the left. Equivalent binding for other direction.";};
};
"Mod+WheelScrollDown" = {
action = focus-column-right;
hotkey-overlay = {hidden = true;};
};
"Mod+Shift+WheelScrollUp" = {
action = focus-workspace-up;
hotkey-overlay = {title = "Focus previous workspace. Equivalent binding for other direction.";};
};
"Mod+Shift+WheelScrollDown" = {
action = focus-workspace-down;
hotkey-overlay = {hidden = true;};
};
"Mod+Shift+H" = {
action = move-column-left-or-to-monitor-left;
hotkey-overlay = {title = "Move column to the left. Equivalent bindings for other directions.";};
};
"Mod+Shift+J" = {
action = move-window-down-or-to-workspace-down;
hotkey-overlay = {hidden = true;};
};
"Mod+Shift+K" = {
action = move-window-up-or-to-workspace-up;
hotkey-overlay = {hidden = true;};
};
"Mod+Shift+L" = {
action = move-column-right-or-to-monitor-right;
hotkey-overlay = {hidden = true;};
};
# Niri workspaces
"Mod+1" = {
action = focus-workspace 1;
hotkey-overlay = {title = "Focus workspace 1. Equivalent bindings for other workspaces.";};
};
"Mod+2" = {
action = focus-workspace 2;
hotkey-overlay = {hidden = true;};
};
"Mod+3" = {
action = focus-workspace 3;
hotkey-overlay = {hidden = true;};
};
"Mod+4" = {
action = focus-workspace 4;
hotkey-overlay = {hidden = true;};
};
"Mod+5" = {
action = focus-workspace 5;
hotkey-overlay = {hidden = true;};
};
"Mod+6" = {
action = focus-workspace 6;
hotkey-overlay = {hidden = true;};
};
"Mod+7" = {
action = focus-workspace 7;
hotkey-overlay = {hidden = true;};
};
"Mod+8" = {
action = focus-workspace 8;
hotkey-overlay = {hidden = true;};
};
"Mod+9" = {
action = focus-workspace 9;
hotkey-overlay = {hidden = true;};
};
"Mod+0" = {
action = focus-workspace 10;
hotkey-overlay = {hidden = true;};
};
"Mod+Shift+1" = {
action.move-window-to-workspace = 1;
hotkey-overlay = {title = "Move current window to workspace 1. Equivalent bindings for other workspaces.";};
};
"Mod+Shift+2" = {
action.move-window-to-workspace = 2;
hotkey-overlay = {hidden = true;};
};
"Mod+Shift+3" = {
action.move-window-to-workspace = 3;
hotkey-overlay = {hidden = true;};
};
"Mod+Shift+4" = {
action.move-window-to-workspace = 4;
hotkey-overlay = {hidden = true;};
};
"Mod+Shift+5" = {
action.move-window-to-workspace = 5;
hotkey-overlay = {hidden = true;};
};
"Mod+Shift+6" = {
action.move-window-to-workspace = 6;
hotkey-overlay = {hidden = true;};
};
"Mod+Shift+7" = {
action.move-window-to-workspace = 7;
hotkey-overlay = {hidden = true;};
};
"Mod+Shift+8" = {
action.move-window-to-workspace = 8;
hotkey-overlay = {hidden = true;};
};
"Mod+Shift+9" = {
action.move-window-to-workspace = 9;
hotkey-overlay = {hidden = true;};
};
"Mod+Shift+0" = {
action.move-window-to-workspace = 10;
hotkey-overlay = {hidden = true;};
};
};
};
};
};
};
}

View File

@ -1,265 +0,0 @@
{color}: {
enable = false;
settings = {
# configure noctalia here; defaults will
# be deep merged with these attributes.
colorSchemes.predefinedScheme = "Catppuccin";
general = {
avatarImage = ../../../config/face.jpeg;
radiusRatio = 0.2;
showScreenCorners = false;
forceBlackScreenCorners = false;
dimDesktop = true;
scaleRatio = 1;
screenRadiusRatio = 1;
animationSpeed = 1;
animationDisabled = false;
compactLockScreen = false;
lockOnSuspend = true;
enableShadows = true;
shadowDirection = "bottom_right";
shadowOffsetX = 2;
shadowOffsetY = 3;
language = "";
};
ui = {
fontDefault = color.font;
fontFixed = color.font;
tooltipsEnabled = true;
panelsAttachedToBar = true;
settingsPanelAttachTobar = true;
fontDefaultScale = 1;
fontFixedScale = 1;
settingsPanelAttachToBar = false;
};
location = {
name = "Dortmund, Germany";
monthBeforeDay = true;
weatherEnabled = true;
useFahrenheit = false;
use12hourFormat = false;
showWeekNumberInCalendar = false;
showCalendarEvents = true;
showCalendarWeather = true;
analogClockInCalendar = false;
firstDayOfWeek = -1;
};
screenRecorder = {
directory = "~/Videos/Recordings";
frameRate = 60;
audioCodec = "aac";
videoCodec = "h265";
quality = "very_high";
colorRange = "limited";
showCursor = true;
audioSource = "default_output";
videoSource = "portal";
};
wallpaper = {
enabled = true;
overviewEnabled = true;
directory = "~/NixFlake/wallpapers";
enableMultiMonitorDirectories = false;
recursiveSearch = false;
setWallpaperOnAllMonitors = true;
defaultWallpaper = ../../../wallpapers/Windows.jpg;
fillMode = "crop";
fillColor = "#000000";
randomEnabled = false;
randomIntervalSec = 300;
transitionDuration = 1500;
transitionType = "random";
transitionEdgeSmoothness = 0.05;
monitors = [];
panelPosition = "follow_bar";
};
appLauncher = {
enableClipboardHistory = true;
position = "center";
backgroundOpacity = 1;
pinnedExecs = [];
useApp2Unit = false;
sortByMostUsed = true;
terminalCommand = "kitty -e";
customLaunchPrefixEnabled = false;
customLaunchPrefix = "";
};
dock = {
enabled = false;
};
network = {
wifiEnabled = true;
bluetoothEnabled = true;
};
notifications = {
enabled = true;
monitors = [];
location = "top_right";
overlayLayer = true;
backgroundOpacity = 1;
respectExpireTimeout = false;
lowUrgencyDuration = 3;
normalUrgencyDuration = 8;
criticalUrgencyDuration = 15;
};
osd = {
enabled = true;
location = "top_right";
monitors = [];
autoHideMs = 2000;
overlayLayer = true;
};
audio = {
volumeStep = 5;
volumeOverdrive = true;
cavaFrameRate = 30;
visualizerType = "linear";
visualizerQuality = "high";
mprisBlacklist = [];
preferredPlayer = "";
externalMixer = "kitty --title=Ncpamixer ncpamixer";
};
nightLight = {
enabled = false;
forced = false;
autoSchedule = true;
nightTemp = "5000";
dayTemp = "6500";
manualSunrise = "06:30";
manualSunset = "21:30";
};
sessionMenu = {
countdownDuration = 10000;
enableCountdown = true;
position = "center";
powerOptions = [
{
action = "lock";
enabled = true;
}
{
action = "suspend";
enabled = false;
}
{
action = "reboot";
enabled = true;
}
{
action = "logout";
enabled = true;
}
{
action = "shutdown";
enabled = true;
}
];
showHeader = true;
};
bar = {
density = "default";
position = "top";
showCapsule = false;
outerCorners = false;
exclusive = true;
backgroundOpacity = 1;
monitors = [];
floating = false;
marginVertical = 0.25;
marginHorizontal = 0.25;
widgets = {
left = [
{
id = "SidePanelToggle";
useDistroLogo = true;
}
{
hideUnoccupied = false;
id = "Workspace";
labelMode = "none";
}
{
id = "ActiveWindow";
maxWidth = 250;
}
];
center = [
{
id = "MediaMini";
maxWidth = 250;
showAlbumArt = true;
}
{
id = "AudioVisualizer";
width = 100;
visualizerType = "mirrored";
}
];
right = [
# {
# id = "SystemMonitor";
# usePrimaryColor = true;
# showCpuUsage = true;
# showCpuTemp = false;
# showMemoryUsage = true;
# showMemoryAsPercent = false;
# showNetworkStats = true;
# showDiskUsage = true;
# diskPath = "/";
# }
{
id = "Volume";
# displayMode = "alwaysShow";
}
{
id = "Microphone";
# displayMode = "alwaysShow";
}
{
id = "Bluetooth";
# displayMode = "alwaysShow";
}
{
id = "WiFi";
# displayMode = "alwaysShow";
}
{
id = "VPN";
# displayMode = "alwaysShow";
}
{
id = "Tray";
drawerEnabled = false;
}
{
formatHorizontal = "yyyy-MM-dd HH:mm";
formatVertical = "HH mm";
id = "Clock";
useMonospacedFont = true;
usePrimaryColor = true;
}
{
id = "NotificationHistory";
}
];
};
};
};
}

View File

@ -1,7 +0,0 @@
{
lib,
mylib,
...
}: {
enable = lib.mkEnableOption "Niri";
}

View File

@ -0,0 +1,14 @@
{
config,
nixosConfig,
lib,
mylib,
pkgs,
...
}: let
inherit (config.modules) TEMPLATE color;
in {
options.modules.TEMPLATE = import ./options.nix {inherit lib mylib;};
config = lib.mkIf TEMPLATE.enable {};
}

View File

@ -6,9 +6,9 @@
pkgs, pkgs,
... ...
}: let }: let
inherit (config.homemodules) ags; inherit (config.modules) ags;
in { in {
options.homemodules.ags = import ./options.nix {inherit lib mylib;}; options.modules.ags = import ./options.nix {inherit lib mylib;};
config = lib.mkIf ags.enable { config = lib.mkIf ags.enable {
programs.ags = { programs.ags = {
@ -17,20 +17,20 @@ in {
# AGS libs go here # AGS libs go here
extraPackages = [ extraPackages = [
inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.apps inputs.ags.packages.${pkgs.system}.apps
inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.auth inputs.ags.packages.${pkgs.system}.auth
inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.battery inputs.ags.packages.${pkgs.system}.battery
inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.bluetooth inputs.ags.packages.${pkgs.system}.bluetooth
inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.cava inputs.ags.packages.${pkgs.system}.cava
# inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.greet # inputs.ags.packages.${pkgs.system}.greet
inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.hyprland inputs.ags.packages.${pkgs.system}.hyprland
inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.mpris inputs.ags.packages.${pkgs.system}.mpris
inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.network inputs.ags.packages.${pkgs.system}.network
inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.notifd inputs.ags.packages.${pkgs.system}.notifd
# inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.powerprofiles # inputs.ags.packages.${pkgs.system}.powerprofiles
# inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.river # inputs.ags.packages.${pkgs.system}.river
inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.tray inputs.ags.packages.${pkgs.system}.tray
inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.wireplumber inputs.ags.packages.${pkgs.system}.wireplumber
]; ];
# This should symlink but doesn't, it copies the files :/ # This should symlink but doesn't, it copies the files :/
@ -40,7 +40,7 @@ in {
# The ags module doesn't expose the "astal" cli tool or extraPackages # The ags module doesn't expose the "astal" cli tool or extraPackages
home.packages = home.packages =
[ [
inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.io inputs.ags.packages.${pkgs.system}.io
] ]
++ config.programs.ags.extraPackages; ++ config.programs.ags.extraPackages;
@ -68,7 +68,7 @@ in {
# ".config/ags".source = config.lib.file.mkOutOfStoreSymlink "${config.paths.nixflake}/home/modules/ags/config"; # ".config/ags".source = config.lib.file.mkOutOfStoreSymlink "${config.paths.nixflake}/home/modules/ags/config";
# NOTE: Don't symlink to ~/.config/ags/colors.scss, since that is already used by configDir # NOTE: Don't symlink to ~/.config/ags/colors.scss, since that is already used by configDir
".config/_colors.scss".text = with config.homemodules.color.hex; '' ".config/_colors.scss".text = with config.modules.color.hex; ''
$dark-rosewater: #${dark.rosewater}; $dark-rosewater: #${dark.rosewater};
$dark-flamingo: #${dark.flamingo}; $dark-flamingo: #${dark.flamingo};
$dark-pink: #${dark.pink}; $dark-pink: #${dark.pink};

View File

@ -5,9 +5,9 @@
... ...
}: }:
with mylib.modules; let with mylib.modules; let
cfg = config.homemodules.alacritty; cfg = config.modules.alacritty;
in { in {
options.homemodules.alacritty = import ./options.nix {inherit lib mylib;}; options.modules.alacritty = import ./options.nix {inherit lib mylib;};
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.alacritty = { programs.alacritty = {

View File

@ -8,14 +8,14 @@
}: }:
with lib; with lib;
with mylib.modules; let with mylib.modules; let
cfg = config.homemodules.audio; cfg = config.modules.audio;
cfgfp = config.homemodules.flatpak; cfgfp = config.modules.flatpak;
in { in {
imports = [ imports = [
../flatpak ../flatpak
]; ];
options.homemodules.audio = import ./options.nix {inherit lib mylib;}; options.modules.audio = import ./options.nix {inherit lib mylib;};
config = mkIf cfg.enable { config = mkIf cfg.enable {
assertions = [ assertions = [

View File

@ -12,13 +12,13 @@ with lib;
with mylib.modules; let with mylib.modules; let
# This is the current state of the option that this module defines # This is the current state of the option that this module defines
# We use it to determine if the config should be changed below # We use it to determine if the config should be changed below
cfg = config.homemodules.emacs; cfg = config.modules.emacs;
in { in {
imports = []; imports = [];
# Options is a vector of options this module defines # Options is a vector of options this module defines
# This module defines only the "emacs" option and suboptions "enable" and "doom" # This module defines only the "emacs" option and suboptions "enable" and "doom"
options.homemodules.emacs = import ./options.nix {inherit lib mylib;}; options.modules.emacs = import ./options.nix {inherit lib mylib;};
# Config is the merged set of all module configurations # Config is the merged set of all module configurations
# Here we define what happens to the config if the module is active (but only if the module is active) # Here we define what happens to the config if the module is active (but only if the module is active)

View File

@ -13,9 +13,9 @@
}: }:
with lib; with lib;
with mylib.modules; let with mylib.modules; let
cfg = config.homemodules.email; cfg = config.modules.email;
in { in {
options.homemodules.email = import ./options.nix {inherit lib mylib;}; options.modules.email = import ./options.nix {inherit lib mylib;};
# TODO: Add Maildir to nextcloud sync # TODO: Add Maildir to nextcloud sync
config = mkIf cfg.enable { config = mkIf cfg.enable {

View File

@ -12,9 +12,9 @@ with mylib.modules;
# It is important that every flatpak interaction is handled through this module # It is important that every flatpak interaction is handled through this module
# to prevent that anything is removed by a module although it is required by another one # to prevent that anything is removed by a module although it is required by another one
let let
cfg = config.homemodules.flatpak; cfg = config.modules.flatpak;
in { in {
options.homemodules.flatpak = import ./options.nix {inherit lib mylib;}; options.modules.flatpak = import ./options.nix {inherit lib mylib;};
config = mkIf cfg.enable { config = mkIf cfg.enable {
assertions = [ assertions = [
@ -81,7 +81,7 @@ with mylib.modules;
cp -f ${pkgs.lxgw-wenkai}/share/fonts/truetype/LXGWWenKaiMono-Regular.ttf ${config.home.homeDirectory}/.local/share/fonts/ cp -f ${pkgs.lxgw-wenkai}/share/fonts/truetype/LXGWWenKaiMono-Regular.ttf ${config.home.homeDirectory}/.local/share/fonts/
cp -f ${pkgs.nerdfonts.override {fonts = ["JetBrainsMono"];}}/share/fonts/truetype/NerdFonts/JetBrainsMonoNerdFontMono-Regular.ttf ${config.home.homeDirectory}/.local/share/fonts/ cp -f ${pkgs.nerdfonts.override {fonts = ["JetBrainsMono"];}}/share/fonts/truetype/NerdFonts/JetBrainsMonoNerdFontMono-Regular.ttf ${config.home.homeDirectory}/.local/share/fonts/
cp -f ${pkgs.noto-fonts}/share/fonts/noto/NotoSans[wdth,wght].ttf ${config.home.homeDirectory}/.local/share/fonts/ cp -f ${pkgs.noto-fonts}/share/fonts/noto/NotoSans[wdth,wght].ttf ${config.home.homeDirectory}/.local/share/fonts/
cp -f ${pkgs.noto-fonts-color-emoji}/share/fonts/noto/NotoColorEmoji.ttf ${config.home.homeDirectory}/.local/share/fonts/ cp -f ${pkgs.noto-fonts-emoji}/share/fonts/noto/NotoColorEmoji.ttf ${config.home.homeDirectory}/.local/share/fonts/
''; '';
}) })
(mkElse cfg.fontFix { (mkElse cfg.fontFix {

View File

@ -7,11 +7,11 @@
}: }:
with lib; with lib;
with mylib.modules; let with mylib.modules; let
cfg = config.homemodules.gaming; cfg = config.modules.gaming;
cfgfp = config.homemodules.flatpak; cfgfp = config.modules.flatpak;
in { in {
imports = [ imports = [
# NOTE: I don't know if this is the right approach or if I should use config.homemodules.flatpak # NOTE: I don't know if this is the right approach or if I should use config.modules.flatpak
../flatpak ../flatpak
]; ];
@ -19,7 +19,7 @@ in {
# TODO: SteamTinkerLaunch option # TODO: SteamTinkerLaunch option
# TODO: Dolphin + SteamRomManager option # TODO: Dolphin + SteamRomManager option
options.homemodules.gaming = import ./options.nix {inherit lib mylib;}; options.modules.gaming = import ./options.nix {inherit lib mylib;};
config = mkIf cfg.enable { config = mkIf cfg.enable {
assertions = [ assertions = [

View File

@ -10,9 +10,9 @@
}: }:
with lib; with lib;
with mylib.modules; let with mylib.modules; let
cfg = config.homemodules.helix; cfg = config.modules.helix;
in { in {
options.homemodules.helix = import ./options.nix {inherit lib mylib;}; options.modules.helix = import ./options.nix {inherit lib mylib;};
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.sessionVariables = { home.sessionVariables = {

View File

@ -9,9 +9,9 @@
# TODO: Remove this module, put protonmail into the email module # TODO: Remove this module, put protonmail into the email module
with lib; with lib;
with mylib.modules; let with mylib.modules; let
cfg = config.homemodules.misc; cfg = config.modules.misc;
in { in {
options.homemodules.misc = import ./options.nix {inherit lib mylib;}; options.modules.misc = import ./options.nix {inherit lib mylib;};
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = with pkgs; home.packages = with pkgs;

View File

@ -12,9 +12,9 @@
}: }:
with lib; with lib;
with mylib.modules; let with mylib.modules; let
cfg = config.homemodules.nextcloud; cfg = config.modules.nextcloud;
in { in {
options.homemodules.nextcloud = import ./options.nix {inherit lib mylib;}; options.modules.nextcloud = import ./options.nix {inherit lib mylib;};
config = mkIf cfg.enable { config = mkIf cfg.enable {
assertions = [ assertions = [

View File

@ -8,9 +8,9 @@
}: }:
with lib; with lib;
with mylib.modules; let with mylib.modules; let
cfg = config.homemodules.ranger; cfg = config.modules.ranger;
in { in {
options.homemodules.ranger = import ./options.nix {inherit lib mylib;}; options.modules.ranger = import ./options.nix {inherit lib mylib;};
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = with pkgs; home.packages = with pkgs;
@ -33,7 +33,7 @@ in {
python310Packages.pillow python310Packages.pillow
ffmpegthumbnailer ffmpegthumbnailer
imagemagick imagemagick
poppler-utils poppler_utils
]) ])
]; ];

View File

@ -9,9 +9,9 @@
}: }:
with lib; with lib;
with mylib.modules; let with mylib.modules; let
cfg = config.homemodules.vscode; cfg = config.modules.vscode;
in { in {
options.homemodules.vscode = import ./options.nix {inherit lib mylib;}; options.modules.vscode = import ./options.nix {inherit lib mylib;};
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.vscode = { programs.vscode = {

View File

@ -6,9 +6,9 @@
pkgs, pkgs,
... ...
}: let }: let
inherit (config.homemodules) beets; inherit (config.modules) beets;
in { in {
options.homemodules.beets = import ./options.nix {inherit lib mylib;}; options.modules.beets = import ./options.nix {inherit lib mylib;};
config = lib.mkIf beets.enable { config = lib.mkIf beets.enable {
programs.beets = { programs.beets = {
@ -50,8 +50,7 @@ in {
"edit" # edit metadata in text editor "edit" # edit metadata in text editor
"fetchart" # pickup local cover art or search online "fetchart" # pickup local cover art or search online
"fish" # beet fish generates ~/.config/fish/completions file "fish" # beet fish generates ~/.config/fish/completions file
# "lyrics" # fetch song lyrics "lyrics" # fetch song lyrics
"musicbrainz" # auto tagger data source
"replaygain" # write replaygain tags for automatic loudness adjustments "replaygain" # write replaygain tags for automatic loudness adjustments
]; ];
@ -60,10 +59,10 @@ in {
sources = "filesystem coverart itunes amazon albumart"; # sources are queried in this order sources = "filesystem coverart itunes amazon albumart"; # sources are queried in this order
}; };
# lyrics = { lyrics = {
# auto = "yes"; # only embeds lyrics into metadata, needed for jellyfin but useless for rmpc auto = "yes"; # only embeds lyrics into metadata, needed for jellyfin but useless for rmpc
# synced = "yes"; # prefer synced lyrics if provided synced = "yes"; # prefer synced lyrics if provided
# }; };
replaygain = { replaygain = {
auto = "yes"; # analyze on import automatically auto = "yes"; # analyze on import automatically

View File

@ -6,9 +6,9 @@
pkgs, pkgs,
... ...
}: let }: let
inherit (config.homemodules) btop color; inherit (config.modules) btop color;
in { in {
options.homemodules.btop = import ./options.nix {inherit lib mylib;}; options.modules.btop = import ./options.nix {inherit lib mylib;};
config = lib.mkIf btop.enable { config = lib.mkIf btop.enable {
programs.btop = { programs.btop = {
@ -34,10 +34,10 @@ in {
theme[hi_fg]=${color.hexS.accent} theme[hi_fg]=${color.hexS.accent}
# Background color of selected item in processes box # Background color of selected item in processes box
theme[selected_bg]=${color.hexS.accentDim} theme[selected_bg]=${color.hexS.surface1}
# Foreground color of selected item in processes box # Foreground color of selected item in processes box
theme[selected_fg]=${color.hexS.accentText} theme[selected_fg]=${color.hexS.accent}
# Color of inactive/disabled text # Color of inactive/disabled text
theme[inactive_fg]=${color.hexS.overlay0} theme[inactive_fg]=${color.hexS.overlay0}

View File

@ -5,9 +5,9 @@
pkgs, pkgs,
... ...
}: let }: let
inherit (config.homemodules) chromium; inherit (config.modules) chromium;
in { in {
options.homemodules.chromium = import ./options.nix {inherit lib mylib;}; options.modules.chromium = import ./options.nix {inherit lib mylib;};
config = lib.mkIf chromium.enable { config = lib.mkIf chromium.enable {
home.packages = with pkgs; home.packages = with pkgs;

View File

@ -5,9 +5,9 @@
pkgs, pkgs,
... ...
}: let }: let
inherit (config.homemodules) color; inherit (config.modules) color;
in { in {
options.homemodules.color = import ./options.nix {inherit lib mylib pkgs;}; options.modules.color = import ./options.nix {inherit lib mylib;};
config = { config = {
home.packages = let home.packages = let
@ -50,16 +50,13 @@ in {
|> builtins.concatStringsSep "\n") |> builtins.concatStringsSep "\n")
''echo ${lib.concatStrings (lib.replicate 20 "=")}'' ''echo ${lib.concatStrings (lib.replicate 20 "=")}''
]); ]);
in in [
[ applyColors
applyColors printNixColors
printNixColors ];
]
++ (lib.optionals color.installPackages [color.iconPackage color.cursorPackage])
++ (lib.optionals color.installPackages color.extraPackages);
# This module sets its own options to the values specified in a colorscheme file. # This module sets its own options to the values specified in a colorscheme file.
homemodules.color = let modules.color = let
scheme = import ./schemes/${color.scheme}.nix; scheme = import ./schemes/${color.scheme}.nix;
# Add the aliases # Add the aliases

View File

@ -1,7 +1,6 @@
{ {
lib, lib,
mylib, mylib,
pkgs,
... ...
}: let }: let
colorKeys = [ colorKeys = [
@ -51,54 +50,6 @@ in rec {
default = "JetBrainsMono Nerd Font Mono"; default = "JetBrainsMono Nerd Font Mono";
}; };
cursor = lib.mkOption {
type = lib.types.str;
description = "The cursor to use";
example = "Bibata-Modern-Classic";
default = "Bibata-Modern-Classic";
};
cursorSize = lib.mkOption {
type = lib.types.int;
description = "The cursor size";
example = 24;
default = 24;
};
cursorPackage = lib.mkOption {
type = lib.types.package;
description = "The cursor package";
example = pkgs.bibata-cursors;
default = pkgs.bibata-cursors;
};
iconTheme = lib.mkOption {
type = lib.types.str;
description = "The icon theme to use";
example = "Papirus";
default = "Papirus";
};
iconPackage = lib.mkOption {
type = lib.types.package;
description = "The icon theme package";
example = pkgs.papirus-icon-theme;
default = pkgs.papirus-icon-theme;
};
extraPackages = lib.mkOption {
type = lib.types.listOf lib.types.package;
description = "Extra packages to install";
example = ''
[
pkgs.bibata-cursors
]
'';
default = [];
};
installPackages = lib.mkEnableOption "Install cursor and icon themes";
# This option is set automatically # This option is set automatically
wallpapers = let wallpapers = let
# Collect all the available wallpapers. # Collect all the available wallpapers.

View File

@ -18,7 +18,6 @@
./lazygit ./lazygit
./mpd ./mpd
./neovim ./neovim
./niri
./nnn ./nnn
./paths ./paths
./qutebrowser ./qutebrowser
@ -30,14 +29,8 @@
# HM modules imported from the flake inputs # HM modules imported from the flake inputs
inputs.nix-flatpak.homeManagerModules.nix-flatpak inputs.nix-flatpak.homeManagerModules.nix-flatpak
inputs.nixvim.homeModules.nixvim inputs.nixvim.homeManagerModules.nixvim
inputs.textfox.homeManagerModules.default inputs.textfox.homeManagerModules.default
# inputs.niri.homeModules.niri # Imported by system module
inputs.noctalia.homeModules.default
inputs.caelestia.homeManagerModules.default
inputs.dank-material-shell.homeModules.dank-material-shell
inputs.dank-material-shell.homeModules.niri
inputs.danksearch.homeModules.default
# NOTE: Do NOT use this, use the system module (the HM module has to rely on fuse) # NOTE: Do NOT use this, use the system module (the HM module has to rely on fuse)
# inputs.impermanence.homeManagerModules.impermanence # inputs.impermanence.homeManagerModules.impermanence

View File

@ -5,18 +5,15 @@
pkgs, pkgs,
... ...
}: let }: let
inherit (config.homemodules) docs; inherit (config.modules) docs;
in { in {
options.homemodules.docs = import ./options.nix {inherit lib mylib;}; options.modules.docs = import ./options.nix {inherit lib mylib;};
config = lib.mkIf docs.enable { config = lib.mkIf docs.enable {
home = { home = {
packages = with pkgs; [ packages = with pkgs; [
texliveFull
inkscape inkscape
texliveFull # TODO: LaTeX packages
typst # TODO: Typst packages
]; ];
file = { file = {

View File

@ -5,9 +5,9 @@
pkgs, pkgs,
... ...
}: let }: let
inherit (config.homemodules) fcitx; inherit (config.modules) fcitx;
in { in {
options.homemodules.fcitx = import ./options.nix {inherit lib mylib;}; options.modules.fcitx = import ./options.nix {inherit lib mylib;};
config = lib.mkIf fcitx.enable { config = lib.mkIf fcitx.enable {
i18n.inputMethod = { i18n.inputMethod = {
@ -22,8 +22,8 @@ in {
# fcitx5-configtool # fcitx5-configtool
catppuccin-fcitx5 catppuccin-fcitx5
kdePackages.fcitx5-qt # QT5 libsForQt5.fcitx5-qt # QT5
kdePackages.fcitx5-chinese-addons libsForQt5.fcitx5-chinese-addons
qt6Packages.fcitx5-qt # QT6 qt6Packages.fcitx5-qt # QT6
qt6Packages.fcitx5-chinese-addons qt6Packages.fcitx5-chinese-addons

View File

@ -69,7 +69,6 @@ in [
(mkBm "Rust" "https://doc.rust-lang.org/stable/book/ch03-00-common-programming-concepts.html") (mkBm "Rust" "https://doc.rust-lang.org/stable/book/ch03-00-common-programming-concepts.html")
(mkBm "RustOS" "https://os.phil-opp.com/") (mkBm "RustOS" "https://os.phil-opp.com/")
(mkBm "Interpreters" "https://craftinginterpreters.com/contents.html") (mkBm "Interpreters" "https://craftinginterpreters.com/contents.html")
(mkBm "Godbolt" "https://godbolt.org")
]; ];
} }
{ {
@ -79,7 +78,6 @@ in [
(mkBm "DeepSeek Chat" "https://chat.deepseek.com/") (mkBm "DeepSeek Chat" "https://chat.deepseek.com/")
(mkBm "Claude Chat" "https://claude.ai/new") (mkBm "Claude Chat" "https://claude.ai/new")
(mkBm "ChatGPT" "https://chatgpt.com/") (mkBm "ChatGPT" "https://chatgpt.com/")
(mkBm "DeepWiki" "https://deepwiki.com/")
"separator" "separator"
(mkBm "Mistral API" "https://console.mistral.ai/usage") (mkBm "Mistral API" "https://console.mistral.ai/usage")
(mkBm "DeepSeek API" "https://platform.deepseek.com/usage") (mkBm "DeepSeek API" "https://platform.deepseek.com/usage")

View File

@ -6,15 +6,15 @@
hostname, hostname,
... ...
}: let }: let
inherit (config.homemodules) firefox color; inherit (config.modules) firefox color;
in { in {
options.homemodules.firefox = import ./options.nix {inherit lib mylib;}; options.modules.firefox = import ./options.nix {inherit lib mylib;};
config = lib.mkIf firefox.enable { config = lib.mkIf firefox.enable {
textfox = { textfox = {
enable = firefox.textfox; enable = firefox.textfox;
# useLegacyExtensions = false; useLegacyExtensions = false;
profiles = ["default"]; profile = "default";
config = { config = {
background = { background = {
@ -54,9 +54,7 @@ in {
}; };
}; };
home.packages = with pkgs; [ home.packages = with pkgs; [vdhcoapp];
# vdhcoapp # No longer required since VDH >= 10
];
home.sessionVariables = lib.mkMerge [ home.sessionVariables = lib.mkMerge [
{ {
@ -206,13 +204,6 @@ in {
definedAliases = ["@aw"]; definedAliases = ["@aw"];
}; };
nixpkgs-issues = {
name = "Nixpkgs Issues";
urls = [{template = "https://github.com/NixOS/nixpkgs/issues?q=is%3Aissue%20{searchTerms}";}];
iconMapObj."16" = "https://github.com/favicon.ico";
definedAliases = ["@i"];
};
github = { github = {
name = "GitHub"; name = "GitHub";
urls = [{template = "https://github.com/search?q={searchTerms}&type=repositories";}]; urls = [{template = "https://github.com/search?q={searchTerms}&type=repositories";}];
@ -244,11 +235,11 @@ in {
catppuccin-mocha-mauve catppuccin-mocha-mauve
# catppuccin-web-file-icons # catppuccin-web-file-icons
clearurls clearurls
# cookie-autodelete cookie-autodelete
# dark-background-light-text dark-background-light-text
display-_anchors # Easier linking to specific website parts display-_anchors # Easier linking to specific website parts
don-t-fuck-with-paste don-t-fuck-with-paste
# enhancer-for-youtube # Discontinued, use tweaks-for-youtube enhancer-for-youtube
fastforwardteam # skip URL shorteners fastforwardteam # skip URL shorteners
# faststream # replace video players with a faster one # faststream # replace video players with a faster one
frankerfacez # twitch emotes frankerfacez # twitch emotes
@ -256,11 +247,11 @@ in {
keepassxc-browser keepassxc-browser
localcdn localcdn
lovely-forks # Display notable forks on GitHub repos lovely-forks # Display notable forks on GitHub repos
# move-unloaded-tabs-for-tst # move tst tabs without them becoming active move-unloaded-tabs-for-tst # move tst tabs without them becoming active
native-mathml # native MathML instead of MathJax/MediaWiki native-mathml # native MathML instead of MathJax/MediaWiki
no-pdf-download # open pdf in browser without downloading no-pdf-download # open pdf in browser without downloading
open-in-freedium open-in-freedium
# plasma-integration # plasma-integration # TODO: Only when Plasma is used
privacy-badger privacy-badger
privacy-settings privacy-settings
protondb-for-steam protondb-for-steam
@ -276,12 +267,11 @@ in {
# sourcegraph # Code intelligence for GitHub/GitLap for 20+ languages # sourcegraph # Code intelligence for GitHub/GitLap for 20+ languages
sponsorblock sponsorblock
steam-database steam-database
# tab-session-manager tab-session-manager
# to-deepl # to-deepl
transparent-standalone-image transparent-standalone-image
# tree-style-tab tree-style-tab
# tst-fade-old-tabs tst-fade-old-tabs
tweaks-for-youtube
twitch-auto-points twitch-auto-points
ublacklist ublacklist
ublock-origin ublock-origin

View File

@ -7,9 +7,9 @@
nixosConfig, nixosConfig,
... ...
}: let }: let
inherit (config.homemodules) fish color; inherit (config.modules) fish color;
in { in {
options.homemodules.fish = import ./options.nix {inherit lib mylib;}; options.modules.fish = import ./options.nix {inherit lib mylib;};
config = lib.mkIf fish.enable { config = lib.mkIf fish.enable {
# https://github.com/catppuccin/fish/blob/main/themes/Catppuccin%20Mocha.theme # https://github.com/catppuccin/fish/blob/main/themes/Catppuccin%20Mocha.theme
@ -47,7 +47,7 @@ in {
generateCompletions = nixosConfig.programs.fish.generateCompletions; generateCompletions = nixosConfig.programs.fish.generateCompletions;
functions = lib.mergeAttrsList [ functions = lib.mergeAttrsList [
(lib.optionalAttrs config.homemodules.nnn.enable { (lib.optionalAttrs config.modules.nnn.enable {
nnncd = { nnncd = {
wraps = "nnn"; wraps = "nnn";
description = "support nnn quit and change directory"; description = "support nnn quit and change directory";
@ -101,7 +101,7 @@ in {
# Same as above but with args for bat # Same as above but with args for bat
batifyWithArgs = command: args: command + (lib.optionalString config.programs.bat.enable (" | bat " + args)); batifyWithArgs = command: args: command + (lib.optionalString config.programs.bat.enable (" | bat " + args));
# These can be used for my config.homemodules and for HM config.programs, # These can be used for my config.modules and for HM config.programs,
# as both of these add the package to home.packages # as both of these add the package to home.packages
hasHomePackage = package: (mylib.modules.contains config.home.packages package); hasHomePackage = package: (mylib.modules.contains config.home.packages package);
@ -167,15 +167,15 @@ in {
gcl = "git clone"; gcl = "git clone";
}) })
(lib.optionalAttrs config.homemodules.kitty.enable {ssh = "kitty +kitten ssh";}) (lib.optionalAttrs config.modules.kitty.enable {ssh = "kitty +kitten ssh";})
(abbrify pkgs.lazygit {lg = "lazygit";}) (abbrify pkgs.lazygit {lg = "lazygit";})
(abbrify pkgs.nix-search-tv {search = "nix-search-tv print --indexes 'nixos,home-manager,nixpkgs,nur' | fzf --preview 'nix-search-tv preview {}' --scheme history";}) (abbrify pkgs.nix-search-tv {search = "nix-search-tv print --indexes 'nixos,home-manager,nixpkgs,nur' | fzf --preview 'nix-search-tv preview {}' --scheme history";})
# Doesn't work with abbrify because I have nnn.override... # Doesn't work with abbrify because I have nnn.override...
(lib.optionalAttrs config.homemodules.nnn.enable {n = "nnncd -a";}) (lib.optionalAttrs config.modules.nnn.enable {n = "nnncd -a";})
(lib.optionalAttrs config.homemodules.nnn.enable {np = "nnncd -a -P p";}) (lib.optionalAttrs config.modules.nnn.enable {np = "nnncd -a -P p";})
(abbrify pkgs.ranger {r = "ranger --choosedir=$HOME/.rangerdir; set LASTDIR (cat $HOME/.rangerdir); cd $LASTDIR";}) (abbrify pkgs.ranger {r = "ranger --choosedir=$HOME/.rangerdir; set LASTDIR (cat $HOME/.rangerdir); cd $LASTDIR";})
@ -184,7 +184,7 @@ in {
# grep = rg; # grep = rg;
}) })
(lib.optionalAttrs config.homemodules.rmpc.enable {r = "rcmp";}) (lib.optionalAttrs config.modules.rmpc.enable {r = "rcmp";})
(abbrify pkgs.rsync rec { (abbrify pkgs.rsync rec {
rsync = "rsync -ahv --inplace --partial --info=progress2"; rsync = "rsync -ahv --inplace --partial --info=progress2";
@ -197,7 +197,7 @@ in {
programs.starship = { programs.starship = {
enable = true; enable = true;
enableFishIntegration = config.homemodules.fish.enable; enableFishIntegration = config.modules.fish.enable;
settings = { settings = {
# Other config here # Other config here
format = "$all"; # Remove this line to disable the default prompt format format = "$all"; # Remove this line to disable the default prompt format

View File

@ -6,34 +6,35 @@
pkgs, pkgs,
... ...
}: let }: let
inherit (config.homemodules) git; inherit (config.modules) git;
in { in {
options.homemodules.git = import ./options.nix {inherit lib mylib;}; options.modules.git = import ./options.nix {inherit lib mylib;};
config = lib.mkIf git.enable { config = lib.mkIf git.enable {
programs.diff-so-fancy = { programs.git = {
enable = true; enable = true;
enableGitIntegration = true;
settings = { # userEmail = "christoph.urlacher@protonmail.com";
# userName = "Christoph Urlacher";
userEmail = git.userEmail;
userName = git.userName;
signing = {
signByDefault = git.signCommits;
format = "ssh";
key = "~/.ssh/id_ed25519.pub";
};
lfs.enable = true;
diff-so-fancy = {
enable = true;
changeHunkIndicators = true; changeHunkIndicators = true;
markEmptyLines = false; markEmptyLines = false;
stripLeadingSymbols = true; stripLeadingSymbols = true;
}; };
};
programs.git = {
enable = true;
# settings.user.email = "christoph.urlacher@protonmail.com";
# settings.user.name = "Christoph Urlacher";
settings = {
user = {
email = git.userEmail;
name = git.userName;
};
extraConfig = {
core = { core = {
compression = 9; compression = 9;
# whitespace = "error"; # whitespace = "error";
@ -110,14 +111,6 @@ in {
}; };
}; };
}; };
signing = {
signByDefault = git.signCommits;
format = "ssh";
key = "~/.ssh/id_ed25519.pub";
};
lfs.enable = true;
}; };
}; };
} }

Some files were not shown because too many files have changed in this diff Show More