Compare commits

..

10 commits

Author SHA1 Message Date
danny
98b4f598f8 chore: update flake & niri blur 2026-03-06 17:06:53 +08:00
danny
601dfb9217 feat: add window manager options 2026-02-04 18:21:40 +08:00
danny
b4b7997ac5 chore: update flake 2026-01-24 15:10:26 +08:00
danny
25482857d4 chore: maintain 2026-01-20 13:41:53 +08:00
danny
2378a66114 feat: add pre-commit hook to check TODO|FIXME|FIX comment 2026-01-10 13:28:41 +08:00
danny
cf005ff872 feat: add formatter 2026-01-10 12:46:40 +08:00
danny
d036cf224a fix: nvf 2026-01-08 15:37:13 +08:00
danny
ea118b7995 feat: netbird 2026-01-08 14:21:53 +08:00
danny
53b83b3471 fix: yazi opener 2025-12-30 16:24:54 +08:00
danny
27482b20d7 feat: add wireguard watchdog 2025-12-30 15:11:46 +08:00
292 changed files with 4734 additions and 2255 deletions

1
.envrc Normal file
View file

@ -0,0 +1 @@
use flake

3
.gitignore vendored Normal file → Executable file
View file

@ -1 +1,4 @@
**/result
.direnv
.pre-commit-config.yaml

0
.sops.yaml Normal file → Executable file
View file

0
README.md Normal file → Executable file
View file

0
docs/fcitx.md Normal file → Executable file
View file

0
docs/hyprland.md Normal file → Executable file
View file

0
docs/yazi.md Normal file → Executable file
View file

1083
flake.lock generated Normal file → Executable file

File diff suppressed because it is too large Load diff

83
flake.nix Normal file → Executable file
View file

@ -41,7 +41,7 @@
neovim-nightly-overlay.url = "github:nix-community/neovim-nightly-overlay";
lanzaboote = {
url = "github:nix-community/lanzaboote/v0.4.2";
url = "github:nix-community/lanzaboote/v1.0.0";
inputs.nixpkgs.follows = "nixpkgs";
};
@ -112,12 +112,6 @@
inputs.nixpkgs.url = "github:nixos/nixpkgs/nixos-25.05";
};
actual-budget-server = {
url = "git+file:///home/danny/projects/actual-budget-flake";
# url = "github:dachxy/actual-budget-flake";
inputs.nixpkgs.follows = "nixpkgs";
};
mail-server = {
url = "github:dachxy/nix-mail-server";
inputs.nixpkgs.follows = "nixpkgs";
@ -131,7 +125,8 @@
nix-search-tv.url = "github:3timeslazy/nix-search-tv";
niri = {
url = "github:sodiboo/niri-flake";
# url = "github:sodiboo/niri-flake";
url = "github:dachxy/niri-flake"; # Wait for blur configurations
inputs.nixpkgs.follows = "nixpkgs";
};
@ -140,6 +135,8 @@
inputs.nixpkgs.follows = "nixpkgs";
};
git-hooks.url = "github:cachix/git-hooks.nix";
# ==== Shell ==== #
caelestia-shell = {
url = "github:caelestia-dots/shell";
@ -151,33 +148,39 @@
inputs.nixpkgs.follows = "nixpkgs";
};
mango = {
url = "github:DreamMaoMao/mango";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs =
{
self,
nixpkgs,
systems,
...
}@inputs:
let
inherit (builtins) mapAttrs;
forEachSystem = nixpkgs.lib.genAttrs (import systems);
hosts = {
dn-pre7780 = {
system = "x86_64-linux";
path = ./system/dev/dn-pre7780;
confPath = ./system/dev/dn-pre7780;
};
dn-server = {
system = "x86_64-linux";
path = ./system/dev/dn-server;
confPath = ./system/dev/dn-server;
};
dn-lap = {
system = "x86_64-linux";
path = ./system/dev/dn-lap;
confPath = ./system/dev/dn-lap;
};
skydrive-lap = {
system = "x86_64-linux";
path = ./system/dev/skydrive-lap;
confPath = ./system/dev/skydrive-lap;
};
};
in
@ -187,7 +190,7 @@
mapAttrs (
hostname: conf:
let
inherit (conf) path system;
inherit (conf) confPath system;
pkgs = import nixpkgs {
inherit system;
};
@ -234,15 +237,67 @@
inputs.attic.nixosModules.atticd
inputs.mail-server.nixosModules.default
inputs.niri.nixosModules.niri
inputs.mango.nixosModules.mango
inputs.lanzaboote.nixosModules.lanzaboote
./options
# ==== Private Configuration ==== #
(import path { inherit hostname; })
(import confPath { inherit hostname; })
];
}
) hosts
);
formatter = forEachSystem (
system:
let
pkgs = nixpkgs.legacyPackages.${system};
config = self.checks.${system}.pre-commit-check.config;
inherit (config) package configFile;
script = ''
${pkgs.lib.getExe package} run --all-files --config ${configFile}
'';
in
pkgs.writeShellScriptBin "pre-commit-run" script
);
checks = forEachSystem (
system:
let
pkgs = import nixpkgs { inherit system; };
in
{
pre-commit-check = inputs.git-hooks.lib.${system}.run {
src = ./.;
hooks = {
nixfmt.enable = true;
check-comment = {
enable = true;
name = "check comment";
entry = "${pkgs.callPackage ./githooks/check-comment.nix { }}";
files = "\\.nix$";
pass_filenames = false;
stages = [ "pre-commit" ];
};
};
};
}
);
devShells = forEachSystem (system: {
default =
let
pkgs = import nixpkgs { inherit system; };
inherit (self.checks.${system}.pre-commit-check) shellHook enabledPackages;
in
pkgs.mkShell {
inherit shellHook;
name = "nixos";
buildInputs = enabledPackages;
};
});
# ==== MicroVM Packages ==== #
# packages."${system}" = {
# vm-1 = self.nixosConfigurations.vm-1.config.microvm.declaredRunner;

View file

@ -0,0 +1,19 @@
{ pkgs, lib }:
pkgs.writeShellScript "check-comment" ''
FILES=$("${lib.getExe pkgs.git}" diff --cached --name-only --diff-filter=ACM | grep '\.nix$' | grep -v '^githooks/check-comment.nix$')
TODO_FOUND=0
for file in $FILES; do
if grep -nHE '#\s*(TODO|FIXME|FIX):' "$file"; then
TODO_FOUND=1
fi
done
if [ $TODO_FOUND -eq 1 ]; then
echo "Remove all the '#TODO|FIXME|FIX' before committing"
exit 1
fi
exit 0
''

0
helper/default.nix Normal file → Executable file
View file

0
home/config/.face Normal file → Executable file
View file

Before

Width:  |  Height:  |  Size: 1.3 MiB

After

Width:  |  Height:  |  Size: 1.3 MiB

Before After
Before After

0
home/config/firefox/autohide_toolbox.css Normal file → Executable file
View file

0
home/config/firefox/nightTab.json Normal file → Executable file
View file

0
home/config/fish/functions/fish_prompt.fish Normal file → Executable file
View file

0
home/config/gh/config.yaml Normal file → Executable file
View file

0
home/config/ghostty/shader/mnoise.glsl Normal file → Executable file
View file

0
home/config/rofi/apps.rasi Normal file → Executable file
View file

0
home/config/rofi/config.rasi Normal file → Executable file
View file

0
home/config/rofi/gruvbox-material.rasi Normal file → Executable file
View file

0
home/config/tmux.yaml Normal file → Executable file
View file

0
home/config/wlogout/icons/hibernate.svg Normal file → Executable file
View file

Before

Width:  |  Height:  |  Size: 307 B

After

Width:  |  Height:  |  Size: 307 B

Before After
Before After

0
home/config/wlogout/icons/lock.svg Normal file → Executable file
View file

Before

Width:  |  Height:  |  Size: 319 B

After

Width:  |  Height:  |  Size: 319 B

Before After
Before After

0
home/config/wlogout/icons/logout.svg Normal file → Executable file
View file

Before

Width:  |  Height:  |  Size: 365 B

After

Width:  |  Height:  |  Size: 365 B

Before After
Before After

0
home/config/wlogout/icons/reboot.svg Normal file → Executable file
View file

Before

Width:  |  Height:  |  Size: 398 B

After

Width:  |  Height:  |  Size: 398 B

Before After
Before After

0
home/config/wlogout/icons/shutdown.svg Normal file → Executable file
View file

Before

Width:  |  Height:  |  Size: 306 B

After

Width:  |  Height:  |  Size: 306 B

Before After
Before After

0
home/config/wlogout/icons/suspend.svg Normal file → Executable file
View file

Before

Width:  |  Height:  |  Size: 350 B

After

Width:  |  Height:  |  Size: 350 B

Before After
Before After

0
home/config/zen/zen-keyboard-shortcuts.json Normal file → Executable file
View file

1
home/options/default.nix Normal file → Executable file
View file

@ -4,5 +4,6 @@
./hyprlock.nix
./sunsetr.nix
./noctalia.nix
./wm.nix
];
}

0
home/options/hyprlock.nix Normal file → Executable file
View file

10
home/options/noctalia.nix Normal file → Executable file
View file

@ -1,17 +1,19 @@
{ config, lib, ... }:
let
inherit (lib)
mkOption
types
inherit (builtins)
elem
isList
filter
listToAttrs
concatMap
nameValuePair
attrNames
isAttrs
;
inherit (lib)
mkOption
types
nameValuePair
;
filterAttrsRecursive' =
pred: set:

0
home/options/ntfy-client.nix Normal file → Executable file
View file

9
home/options/sunsetr.nix Normal file → Executable file
View file

@ -1,4 +1,9 @@
{ config, lib, ... }:
{
config,
lib,
pkgs,
...
}:
let
inherit (lib)
mkIf
@ -11,7 +16,7 @@ in
{
options.services.sunsetr = {
enable = mkEnableOption "Enable sunsetr.";
package = mkPackageOption "sunsetr";
package = mkPackageOption pkgs "sunsetr" { };
};
config = mkIf cfg.enable {

455
home/options/wm.nix Normal file
View file

@ -0,0 +1,455 @@
{
lib,
config,
pkgs,
...
}:
let
inherit (lib)
mkOption
types
concatStringsSep
getExe
dropEnd
last
mkEnableOption
mapAttrs'
nameValuePair
splitString
;
inherit (builtins) length;
cfg = config.wm;
bindCfg = cfg.keybinds;
sep = bindCfg.separator;
mod = bindCfg.mod;
main-color = "#EBDBB2";
secondary-color = "#24273A";
mkHyprBind =
keys:
let
len = length keys;
prefix = if len > 1 then [ ] else [ "None" ];
finalKeys = prefix ++ keys;
in
(concatStringsSep "+" (dropEnd 1 finalKeys)) + ",${last finalKeys}";
mkBindOption =
keys:
let
hypr-key = mkHyprBind keys;
in
mkOption {
type = types.str;
default = if bindCfg.hypr-type then hypr-key else (concatStringsSep sep keys);
};
mkGradientColorOption =
{
from ? main-color,
to ? secondary-color,
angle ? 45,
}:
{
from = mkOption {
type = types.str;
default = from;
};
to = mkOption {
type = types.str;
default = to;
};
angle = mkOption {
type = types.int;
default = angle;
};
};
in
{
options.wm = {
exec-once = mkOption {
type = with types; nullOr lines;
default = null;
apply = v: if v != null then pkgs.writeShellScript "exec-once" v else null;
};
app = {
browser = {
package = mkOption {
type = with types; nullOr package;
default = null;
};
name = mkOption {
type = with types; nullOr package;
default = null;
};
};
terminal = {
package = mkOption {
type = with types; nullOr package;
default = null;
};
name = mkOption {
type = with types; nullOr str;
default = null;
};
run = mkOption {
type = with types; nullOr str;
default = "${getExe cfg.terminal.package} -e ";
};
};
file-browser = {
package = mkOption {
type = with types; nullOr package;
default = null;
};
name = mkOption {
type = with types; nullOr str;
default = null;
};
};
};
window = {
opacity = mkOption {
type = types.float;
default = 0.85;
};
};
input = {
keyboard = {
repeat-delay = mkOption {
type = types.int;
default = 250;
};
repeat-rate = mkOption {
type = types.int;
default = 35;
};
};
};
border = {
active = mkGradientColorOption { };
inactive = mkGradientColorOption {
from = secondary-color;
to = secondary-color;
};
radius = mkOption {
type = types.int;
default = 12;
};
};
keybinds = {
mod = mkOption {
type = types.str;
default = "Mod";
};
separator = mkOption {
type = types.str;
default = "+";
};
hypr-type = mkEnableOption "hyprland-like bind syntax" // {
default = false;
};
spawn = mkOption {
type = types.attrs;
default = {
"${mod}${sep}ENTER" = "${getExe cfg.app.terminal.package}";
"${mod}${sep}F" = "${getExe cfg.app.browser.package}";
};
apply =
binds:
let
hypr-binds = mapAttrs' (n: v: nameValuePair (mkHyprBind (splitString sep n)) v) binds;
in
if bindCfg.hypr-type then hypr-binds else binds;
};
spawn-repeat = mkOption {
type = types.attrs;
default = { };
apply =
binds:
let
hypr-binds = mapAttrs' (n: v: nameValuePair (mkHyprBind (splitString sep n)) v) binds;
in
if bindCfg.hypr-type then hypr-binds else binds;
};
# ==== Movement ==== #
switch-window-focus = mkBindOption [
mod
"TAB"
];
move-window-focus = {
left = mkBindOption [
mod
"H"
];
right = mkBindOption [
mod
"L"
];
up = mkBindOption [
mod
"K"
];
down = mkBindOption [
mod
"J"
];
};
move-monitor-focus = {
left = mkBindOption [
mod
"CTRL"
"H"
];
right = mkBindOption [
mod
"CTRL"
"L"
];
};
move-workspace-focus = {
# Workspace Focus
next = mkBindOption [
mod
"CTRL"
"J"
];
prev = mkBindOption [
mod
"CTRL"
"k"
];
};
move-window = {
left = mkBindOption [
mod
"SHIFT"
"H"
];
right = mkBindOption [
mod
"SHIFT"
"L"
];
up = mkBindOption [
mod
"SHIFT"
"K"
];
down = mkBindOption [
mod
"SHIFT"
"J"
];
};
consume-window = {
left = mkBindOption [
mod
"CTRL"
"SHIFT"
"H"
];
right = mkBindOption [
mod
"CTRL"
"SHIFT"
"L"
];
};
switch-layout = mkBindOption [
mod
"CTRL"
"ALT"
"SPACE"
];
# ==== Actions ==== #
center-window = mkBindOption [
mod
"C"
];
toggle-overview = mkBindOption [
mod
"O"
];
close-window = mkBindOption [
mod
"Q"
];
toggle-fullscreen = mkBindOption [
"F11"
];
# ==== Scrolling ==== #
move-workspace = {
down = mkBindOption [
mod
"CTRL"
"SHIFT"
"J"
];
up = mkBindOption [
mod
"CTRL"
"SHIFT"
"K"
];
};
switch-preset-column-width = mkBindOption [
mod
"W"
];
switch-preset-window-height = mkBindOption [
mod
"S"
];
expand-column-to-available-width = mkBindOption [
mod
"P"
];
maximize-column = mkBindOption [
mod
"M"
];
reset-window-height = mkBindOption [
mod
"CTRL"
"S"
];
# ==== Float ==== #
toggle-float = mkBindOption [
mod
"V"
];
switch-focus-between-floating-and-tiling = mkBindOption [
mod
"CTRL"
"V"
];
minimize = mkBindOption [
mod
"I"
];
restore-minimize = mkBindOption [
mod
"SHIFT"
"I"
];
toggle-scratchpad = mkBindOption [
mod
"Z"
];
# ==== Screenshot ==== #
screenshot = {
area = mkBindOption [
mod
"SHIFT"
"S"
];
window = mkBindOption [
"CTRL"
"SHIFT"
"S"
];
screen = mkBindOption [
mod
"CTRL"
"SHIFT"
"S"
];
};
toggle-control-center = mkBindOption [
mod
"SLASH"
];
toggle-launcher = mkBindOption [
"ALT"
"SPACE"
];
lock-screen = mkBindOption [
mod
"CTRL"
"M"
];
clipboard-history = mkBindOption [
mod
"COMMA"
];
emoji = mkBindOption [
mod
"PERIOD"
];
screen-recorder = mkBindOption [
mod
"F12"
];
notification-center = mkBindOption [
mod
"N"
];
toggle-dont-disturb = mkBindOption [
mod
"CTRL"
"N"
];
wallpaper-selector = mkBindOption [
mod
"CTRL"
"W"
];
wallpaper-random = mkBindOption [
mod
"CTRL"
"SLASH"
];
calculator = mkBindOption [
mod
"CTRL"
"C"
];
media = {
prev = mkBindOption [
mod
"CTRL"
"COMMA"
];
next = mkBindOption [
mod
"CTRL"
"PERIOD"
];
};
focus-workspace-prefix = mkBindOption [ mod ];
};
};
}

2
home/presets/basic.nix Normal file → Executable file
View file

@ -19,5 +19,7 @@
../user/wm-service.nix
../user/ghostty.nix
../user/podman.nix
../user/image-viewer.nix
../user/wm.nix
];
}

0
home/scripts/md2html.nix Normal file → Executable file
View file

106
home/scripts/memeSelector.nix Normal file → Executable file
View file

@ -3,68 +3,68 @@
url,
...
}:
pkgs.writers.writePython3Bin "memeSelector" {libraries = with pkgs.python3Packages; [requests];}
''
import requests
import xml.etree.ElementTree as ET
import urllib.parse
import sys
import os
import tempfile
import subprocess
pkgs.writers.writePython3Bin "memeSelector" { libraries = with pkgs.python3Packages; [ requests ]; }
''
import requests
import xml.etree.ElementTree as ET
import urllib.parse
import sys
import os
import tempfile
import subprocess
BASE_URL = "${url}"
headers = {"Depth": "1"}
resp = requests.request(
"PROPFIND",
BASE_URL,
headers=headers,
verify="${"" + ../../system/extra/ca.crt}"
)
BASE_URL = "${url}"
headers = {"Depth": "1"}
resp = requests.request(
"PROPFIND",
BASE_URL,
headers=headers,
verify="${"" + ../../system/extra/ca.crt}"
)
if resp.status_code not in (200, 207):
print(f"Error: Http {resp.status_code}")
sys.exit(1)
if resp.status_code not in (200, 207):
print(f"Error: Http {resp.status_code}")
sys.exit(1)
root = ET.fromstring(resp.text)
ns = {"d": "DAV:"}
root = ET.fromstring(resp.text)
ns = {"d": "DAV:"}
files = []
for href in root.findall(".//d:href", ns):
path = href.text
if not path:
continue
filename = urllib.parse.unquote(path.split("/")[-1])
files = []
for href in root.findall(".//d:href", ns):
path = href.text
if not path:
continue
filename = urllib.parse.unquote(path.split("/")[-1])
if filename and not filename.endswith("/"):
files.append(filename)
if filename and not filename.endswith("/"):
files.append(filename)
if not files:
print("No files found")
sys.exit(0)
if not files:
print("No files found")
sys.exit(0)
rofi = subprocess.run(
["rofi", "-i", "-dmenu", "-p", "Meme"],
input="\n".join(files).encode(),
stdout=subprocess.PIPE
)
rofi = subprocess.run(
["rofi", "-i", "-dmenu", "-p", "Meme"],
input="\n".join(files).encode(),
stdout=subprocess.PIPE
)
selected = rofi.stdout.decode().strip()
if not selected:
sys.exit(0)
selected = rofi.stdout.decode().strip()
if not selected:
sys.exit(0)
url = BASE_URL + urllib.parse.quote(selected)
tmpfile = os.path.join(tempfile.gettempdir(), selected)
url = BASE_URL + urllib.parse.quote(selected)
tmpfile = os.path.join(tempfile.gettempdir(), selected)
subprocess.run(["wget", "-q", "-O", tmpfile, url], check=True)
subprocess.run(["wget", "-q", "-O", tmpfile, url], check=True)
with open(tmpfile, "rb") as f:
subprocess.run("wl-copy", stdin=f)
with open(tmpfile, "rb") as f:
subprocess.run("wl-copy", stdin=f)
subprocess.run([
"notify-send",
"-i", tmpfile,
"Meme Copied: ",
f"{selected}"
])
''
subprocess.run([
"notify-send",
"-i", tmpfile,
"Meme Copied: ",
f"{selected}"
])
''

0
home/scripts/mkWall.nix Normal file → Executable file
View file

0
home/scripts/ntfy.nix Normal file → Executable file
View file

0
home/scripts/rbwSelector.nix Normal file → Executable file
View file

0
home/scripts/record.nix Normal file → Executable file
View file

11
home/scripts/remoteRebuild.nix Normal file → Executable file
View file

@ -13,11 +13,13 @@ let
--sudo --ask-sudo-password $@'';
in
pkgs.writeShellScriptBin "rRebuild" ''
NOTIFY="''\${NOTIFY:-0}"
TARGET=$1
BUILD=$2
shift
shift
set -euo pipefail
shift 2
${
if shouldNotify then
@ -25,6 +27,11 @@ pkgs.writeShellScriptBin "rRebuild" ''
export NTFY_TITLE="🎯 $TARGET built by 🏗 ''\${BUILD:-${hostName}}"
export NTFY_TAGS="gear"
if [ "$NOTIFY" -eq 0 ] ; then
${rebuildCommand}
exit 0
fi
if ${rebuildCommand}
then
ntfy pub system-build " Build success" > /dev/null 2>&1

0
home/scripts/rofiwall.nix Normal file → Executable file
View file

0
home/user/bitwarden.nix Normal file → Executable file
View file

0
home/user/config.nix Normal file → Executable file
View file

0
home/user/direnv.nix Normal file → Executable file
View file

0
home/user/environment.nix Normal file → Executable file
View file

0
home/user/firefox.nix Normal file → Executable file
View file

6
home/user/ghostty.nix Normal file → Executable file
View file

@ -1,12 +1,10 @@
{
inputs,
pkgs,
lib,
...
}:
let
inherit (pkgs.stdenv.hostPlatform) system;
inherit (lib) mkDefault;
ghosttyShaders = pkgs.fetchFromGitHub {
owner = "sahaj-b";
@ -28,9 +26,9 @@ in
"${ghosttyShaders}/ripple_cursor.glsl"
];
unfocused-split-opacity = 0.85;
unfocused-split-opacity = 0.65;
desktop-notifications = true;
background-opacity = mkDefault 0.6;
background-opacity = 0.5;
background-blur = 20;
wait-after-command = false;

0
home/user/git.nix Normal file → Executable file
View file

0
home/user/gtk.nix Normal file → Executable file
View file

0
home/user/hypr/bind.nix Normal file → Executable file
View file

0
home/user/hypr/input.nix Normal file → Executable file
View file

0
home/user/hypr/window.nix Normal file → Executable file
View file

0
home/user/hypr/windowrule.nix Normal file → Executable file
View file

0
home/user/hypr/workspace.nix Normal file → Executable file
View file

193
home/user/hyprland.nix Normal file → Executable file
View file

@ -1,118 +1,123 @@
{
osConfig,
config,
lib,
pkgs,
inputs,
...
}:
let
inherit (lib) mkIf;
inherit (pkgs.stdenv.hostPlatform) system;
terminal = "ghostty";
execOnceScript = pkgs.writeShellScript "hyprlandExecOnce" ''
# Fix nemo open in terminal
dconf write /org/cinnamon/desktop/applications/terminal/exec "''\'${terminal}''\'" &
dconf write /org/cinnamon/desktop/applications/terminal/exec-arg "''\'''\'" &
systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP QT_QPA_PLATFORMTHEME &
dbus-update-activation-environment --systemd HYPRLAND_INSTANCE_SIGNATURE
# Hint dark theme
gsettings set org.gnome.desktop.interface color-scheme "prefer-dark"
'';
mainMod = "SUPER";
wmCfg = config.wm;
bindCfg = wmCfg.keybinds;
mainMod = bindCfg.mod;
in
{
home.packages = with pkgs; [
hyprcursor
];
imports = [
(import ./hypr/bind.nix { inherit mainMod; })
./hypr/workspace.nix
./hypr/window.nix
./hypr/windowrule.nix
./hypr/input.nix
];
wayland.windowManager.hyprland = {
enable = true;
xwayland.enable = true;
systemd = {
enable = true;
variables = [ "--all" ];
};
package = null;
portalPackage = null;
plugins = (
with inputs.hyprland-plugins.packages.${system};
[
hyprwinwrap
]
);
settings = {
"$mainMod" = mainMod;
debug = {
disable_logs = true;
config = mkIf osConfig.programs.hyprland.enable {
wm = {
exec-once = /* bash */ ''
dbus-update-activation-environment --systemd HYPRLAND_INSTANCE_SIGNATURE
'';
keybinds = {
mod = "SUPER";
separator = ",";
hypr-type = true;
};
};
ecosystem.no_update_news = true;
home.packages = with pkgs; [
hyprcursor
];
bindm = [
# Move/resize windows with mainMod + LMB/RMB and dragging
''${mainMod}, mouse:272, movewindow''
''${mainMod}, mouse:273, resizewindow''
];
imports = [
(import ./hypr/bind.nix { inherit mainMod; })
./hypr/workspace.nix
./hypr/window.nix
./hypr/windowrule.nix
./hypr/input.nix
];
binde =
let
resizeStep = builtins.toString 20;
brightnessStep = builtins.toString 10;
volumeStep = builtins.toString 4;
in
wayland.windowManager.hyprland = {
enable = true;
xwayland.enable = true;
systemd = {
enable = true;
variables = [ "--all" ];
};
package = null;
portalPackage = null;
plugins = (
with inputs.hyprland-plugins.packages.${system};
[
'',XF86AudioRaiseVolume, exec, wpctl set-mute @DEFAULT_SINK@ 0 && wpctl set-volume @DEFAULT_SINK@ ${volumeStep}%+''
'',XF86AudioLowerVolume, exec, wpctl set-mute @DEFAULT_SINK@ 0 && wpctl set-volume @DEFAULT_SINK@ ${volumeStep}%-''
'',XF86MonBrightnessDown, exec, brightnessctl set ${brightnessStep}%-''
'',XF86MonBrightnessUp, exec, brightnessctl set ${brightnessStep}%+''
''${mainMod} CTRL, l, resizeactive, ${resizeStep} 0''
''${mainMod} CTRL, h, resizeactive, -${resizeStep} 0''
''${mainMod} CTRL, k, resizeactive, 0 -${resizeStep}''
''${mainMod} CTRL, j, resizeactive, 0 ${resizeStep}''
hyprwinwrap
]
);
settings = {
"$mainMod" = mainMod;
debug = {
disable_logs = true;
};
ecosystem.no_update_news = true;
bindm = [
# Move/resize windows with mainMod + LMB/RMB and dragging
"${mainMod}, mouse:272, movewindow"
"${mainMod}, mouse:273, resizewindow"
];
plugin = {
hyprwinrap = {
class = "kitty-bg";
binde =
let
resizeStep = toString 20;
brightnessStep = toString 10;
volumeStep = toString 4;
in
[
",XF86AudioRaiseVolume, exec, wpctl set-mute @DEFAULT_SINK@ 0 && wpctl set-volume @DEFAULT_SINK@ ${volumeStep}%+"
",XF86AudioLowerVolume, exec, wpctl set-mute @DEFAULT_SINK@ 0 && wpctl set-volume @DEFAULT_SINK@ ${volumeStep}%-"
",XF86MonBrightnessDown, exec, brightnessctl set ${brightnessStep}%-"
",XF86MonBrightnessUp, exec, brightnessctl set ${brightnessStep}%+"
"${mainMod} CTRL, l, resizeactive, ${resizeStep} 0"
"${mainMod} CTRL, h, resizeactive, -${resizeStep} 0"
"${mainMod} CTRL, k, resizeactive, 0 -${resizeStep}"
"${mainMod} CTRL, j, resizeactive, 0 ${resizeStep}"
];
plugin = {
hyprwinrap = {
class = "kitty-bg";
};
touch_gestures = {
sensitivity = 4.0;
workspace_swipe_fingers = 3;
workspace_swipe_edge = "d";
long_press_delay = 400;
resize_on_border_long_press = true;
edge_margin = 10;
emulate_touchpad_swipe = false;
};
};
touch_gestures = {
sensitivity = 4.0;
workspace_swipe_fingers = 3;
workspace_swipe_edge = "d";
long_press_delay = 400;
resize_on_border_long_press = true;
edge_margin = 10;
emulate_touchpad_swipe = false;
exec-once = [ "${wmCfg.exec-once}" ];
env = [
"XDG_CURRENT_DESKTOP, Hyprland"
"XDG_SESSION_DESKTOP, Hyprland"
"GDK_PIXBUF_MODULE_FILE, ${pkgs.librsvg}/lib/gdk-pixbuf-2.0/2.10.0/loaders.cache"
];
misc = {
disable_hyprland_logo = true;
force_default_wallpaper = 0;
disable_splash_rendering = true;
};
};
exec-once = [ "${execOnceScript}" ];
env = [
''XDG_CURRENT_DESKTOP, Hyprland''
''XDG_SESSION_DESKTOP, Hyprland''
''GDK_PIXBUF_MODULE_FILE, ${pkgs.librsvg}/lib/gdk-pixbuf-2.0/2.10.0/loaders.cache''
];
misc = {
disable_hyprland_logo = true;
force_default_wallpaper = 0;
disable_splash_rendering = true;
};
};
};
}

View file

@ -0,0 +1,43 @@
{ pkgs, ... }:
{
home.packages = with pkgs; [ loupe ];
xdg.mimeApps =
let
value = "org.gnome.Loupe.desktop";
associations = builtins.listToAttrs (
map
(name: {
inherit name value;
})
[
"image/png"
"image/jpeg"
"image/gif"
"image/bmp"
"image/webp"
"image/tiff"
"image/svg+xml"
"image/x-icon"
"image/avif"
"image/heif"
"image/heic"
"image/jxl"
"image/apng"
"image/x-raw"
"image/x-xbitmap"
"image/x-xpixmap"
"image/x-portable-bitmap"
"image/x-portable-graymap"
"image/x-portable-pixmap"
"image/x-tga"
"image/x-pcx"
]
);
in
{
associations.added = associations;
defaultApplications = associations;
};
}

0
home/user/internationalisation.nix Normal file → Executable file
View file

0
home/user/music-production.nix Normal file → Executable file
View file

30
home/user/nvf/default.nix Normal file → Executable file
View file

@ -1,13 +1,15 @@
{
osConfig,
config,
pkgs,
lib,
inputs,
...
}:
let
inherit (builtins) concatStringsSep;
inherit (lib.generators) mkLuaInline;
inherit (lib) concatStringsSep;
inherit (lib) optionalString;
suda-nvim = pkgs.vimUtils.buildVimPlugin {
name = "vim-suda";
@ -23,6 +25,8 @@ let
name = "marks-nvim";
src = inputs.marks-nvim;
};
yaziOpenDir = config.programs.nvf.settings.vim.utility.yazi-nvim.setupOpts.open_for_directories;
in
{
imports = [
@ -44,6 +48,9 @@ in
vim = {
enableLuaLoader = true;
vimAlias = true;
luaConfigPre = ''
${optionalString yaziOpenDir "vim.g.loaded_netrwPlugin = 1"}
'';
extraPackages = with pkgs; [
nixfmt
];
@ -363,11 +370,11 @@ in
formatter = {
conform-nvim = {
enable = true;
setupOpts = {
formatters_by_ft = {
nix = [ "nixfmt" ];
};
};
# setupOpts = {
# formatters_by_ft = {
# nix = [ "nixfmt" ];
# };
# };
};
};
@ -414,7 +421,10 @@ in
nix = {
enable = true;
extraDiagnostics.enable = false;
format.enable = false; # Manually configured in conform-nvim
format = {
type = [ "nixfmt" ];
enable = true;
};
lsp.servers = [ "nixd" ];
};
sql.enable = true;
@ -426,7 +436,10 @@ in
ts-error-translator.enable = true;
};
};
python.enable = true;
python = {
enable = true;
format.type = [ "ruff" ];
};
markdown = {
enable = true;
extensions = {
@ -535,6 +548,7 @@ in
yazi-nvim = {
enable = true;
setupOpts.open_for_directories = true;
mappings.openYaziDir = "<leader>-";
mappings.openYazi = "<leader>e";
};

0
home/user/nvf/extra-lsp.nix Normal file → Executable file
View file

81
home/user/nvf/plugins/leetcode/default.nix Normal file → Executable file
View file

@ -1,5 +1,6 @@
{
lib,
pkgs,
config,
osConfig,
...
@ -11,6 +12,17 @@ let
dataDir = "${config.home.homeDirectory}/${relativeDir}";
in
{
programs.nvf.settings.vim.extraPackages = with pkgs; [
imagemagick # for image.nvim
];
programs.nvf.settings.vim.utility.images.image-nvim = {
enable = true;
setupOpts = {
backend = "kitty";
};
};
programs.nvf.settings.vim.utility.leetcode-nvim = {
enable = true;
setupOpts = {
@ -18,7 +30,7 @@ in
lang = "rust";
plugins.non_standalone = true;
storage.home = mkLuaInline ''"${dataDir}"'';
injector = mkLuaInline ''
injector = mkLuaInline /* lua */ ''
{
['rust'] = {
before = { '#[allow(dead_code)]', 'fn main() {}', '#[allow(dead_code)]', 'struct Solution;' },
@ -26,42 +38,39 @@ in
}
'';
hooks."question_enter" = [
(mkLuaInline
# lua
''
function (question)
if question.lang ~= 'rust' then
return
end
local config = require("leetcode.config")
local problem_dir = config.user.storage.home .. "/Cargo.toml"
local content = [[
[package]
name = "leetcode"
edition = "2024"
[lib]
name = "%s"
path = "%s"
[dependencies]
rand = "0.8"
regex = "1"
itertools = "0.14.0"
]]
local file = io.open(problem_dir, "w")
if file then
local formatted = (content:gsub(" +", "")):format(question.q.frontend_id, question:path())
file:write(formatted)
file:close()
else
print("Failed to open file " .. problem_dir)
end
(mkLuaInline /* lua */ ''
function (question)
if question.lang ~= 'rust' then
return
end
''
)
local config = require("leetcode.config")
local problem_dir = config.user.storage.home .. "/Cargo.toml"
local content = [[
[package]
name = "leetcode"
edition = "2024"
[lib]
name = "%s"
path = "%s"
[dependencies]
rand = "0.8"
regex = "1"
itertools = "0.14.0"
]]
local file = io.open(problem_dir, "w")
if file then
local formatted = (content:gsub(" +", "")):format(question.q.frontend_id, question:path())
file:write(formatted)
file:close()
else
print("Failed to open file " .. problem_dir)
end
end
'')
];
};
};

0
home/user/nvf/plugins/lualine/default.nix Normal file → Executable file
View file

0
home/user/nvf/plugins/snacks-nvim/default.nix Normal file → Executable file
View file

0
home/user/nvf/plugins/snacks-nvim/keymaps.nix Normal file → Executable file
View file

0
home/user/packages.nix Normal file → Executable file
View file

0
home/user/podman.nix Normal file → Executable file
View file

2
home/user/shell.nix Normal file → Executable file
View file

@ -1,10 +1,12 @@
{
lib,
osConfig,
config,
pkgs,
...
}:
let
inherit (lib) mkForce;
remoteRebuld = import ../scripts/remoteRebuild.nix { inherit osConfig config pkgs; };
in
{

0
home/user/shellAlias.nix Normal file → Executable file
View file

0
home/user/shells/caelestia.nix Normal file → Executable file
View file

0
home/user/tmux.nix Normal file → Executable file
View file

0
home/user/virtualization.nix Normal file → Executable file
View file

0
home/user/vscode.nix Normal file → Executable file
View file

0
home/user/wallpaper-engine.nix Normal file → Executable file
View file

0
home/user/waybar.nix Normal file → Executable file
View file

0
home/user/wlogout.nix Normal file → Executable file
View file

0
home/user/wm-service.nix Normal file → Executable file
View file

93
home/user/wm.nix Normal file
View file

@ -0,0 +1,93 @@
{
pkgs,
lib,
config,
...
}:
let
inherit (lib) getExe getExe';
# ==== binary ==== #
rofi = getExe pkgs.rofi;
playerctl = getExe pkgs.playerctl;
wpctl = getExe' pkgs.wireplumber "wpctl";
brightnessctl = getExe pkgs.brightnessctl;
brightnessStep = toString 10;
volumeStep = toString 4;
rofiWall = import ../../home/scripts/rofiwall.nix { inherit config pkgs; };
rbwSelector = import ../../home/scripts/rbwSelector.nix { inherit pkgs; };
toggleWlogout = pkgs.writeShellScript "toggleWlogout" ''
if ${pkgs.busybox}/bin/pgrep wlogout > /dev/null; then
${pkgs.busybox}/bin/pkill wlogout
else
${getExe config.programs.wlogout.package} --protocol layer-shell
fi
'';
cfg = config.wm;
mod = cfg.keybinds.mod;
sep = cfg.keybinds.separator;
in
{
wm = {
exec-once = /* bash */ ''
# Fix nemo open in terminal
dconf write /org/cinnamon/desktop/applications/terminal/exec "''\'${cfg.app.terminal.name}''\'" &
dconf write /org/cinnamon/desktop/applications/terminal/exec-arg "''\'''\'" &
# Hint dark theme
dconf write /org/gnome/desktop/interface/color-scheme '"prefer-dark"' &
systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP QT_QPA_PLATFORMTHEME &
'';
app = {
terminal = {
package = config.programs.ghostty.package;
name = "ghostty";
run = "ghostty -e";
};
browser = {
package = config.programs.zen-browser.package;
name = "zen-twilight";
};
file-browser = {
package = config.programs.yazi.pacakge;
name = "yazi";
};
};
keybinds = {
spawn-repeat = {
# ==== Media ==== #
"XF86AudioPrev" = "${playerctl} previous";
"XF86AudioNext" = "${playerctl} next";
"${mod}${sep}CTRL${sep}COMMA" = "${playerctl} previous";
"${mod}${sep}CTRL${sep}PERIOD" = "${playerctl} next";
"XF86AudioPlay" = "${playerctl} play-pause";
"XF86AudioStop" = "${playerctl} stop";
"XF86AudioMute" = "${wpctl} set-mute @DEFAULT_SINK@ toggle";
"XF86AudioRaiseVolume" =
"${wpctl} set-mute @DEFAULT_SINK@ 0 && ${wpctl} set-volume @DEFAULT_SINK@ ${volumeStep}%+";
"XF86AudioLowerVolume" =
"${wpctl} set-mute @DEFAULT_SINK@ 0 && ${wpctl} set-volume @DEFAULT_SINK@ ${volumeStep}%-";
"XF86MonBrightnessDown" = "${brightnessctl} set ${brightnessStep}%-";
"XF86MonBrightnessUp" = "${brightnessctl} set ${brightnessStep}%+";
};
spawn = {
"${mod}${sep}Return" = "${getExe cfg.app.terminal.package}";
"${mod}${sep}F" = "${getExe cfg.app.browser.package}";
"${mod}${sep}E" = "${cfg.app.terminal.run} ${cfg.app.file-browser.name}";
"${mod}${sep}CTRL${sep}P" = "${rbwSelector}";
"${mod}${sep}CTRL${sep}M" = "${toggleWlogout}";
# Launcher
"${mod}${sep}CTRL${sep}W" = "${rofiWall}";
"ALT${sep}SPACE" = "${rofi} -config config/rofi/apps.rasi -show drun";
"${mod}${sep}PERIOD" = "${rofi} -modi emoji -show emoji";
"${mod}${sep}CTRL${sep}C" = "${rofi} -modi calc -show calc -no-show-match -no-sort";
};
};
};
}

18
home/user/yazi.nix Normal file → Executable file
View file

@ -7,7 +7,7 @@
}:
let
inherit (pkgs.stdenv.hostPlatform) system;
inherit (lib) getExe';
inherit (lib) getExe' getExe;
yaziPlugins = pkgs.fetchFromGitHub {
owner = "yazi-rs";
repo = "plugins";
@ -43,11 +43,11 @@ in
enableFishIntegration = true;
plugins = {
toggle-pane = ''${yaziPlugins}/toggle-pane.yazi'';
mount = ''${yaziPlugins}/mount.yazi'';
zoom = ''${yaziPlugins}/zoom'';
vcs-files = ''${yaziPlugins}/vcs-files'';
git = ''${yaziPlugins}/git'';
toggle-pane = "${yaziPlugins}/toggle-pane.yazi";
mount = "${yaziPlugins}/mount.yazi";
zoom = "${yaziPlugins}/zoom";
vcs-files = "${yaziPlugins}/vcs-files";
git = "${yaziPlugins}/git";
};
settings = {
@ -66,7 +66,7 @@ in
opener = {
edit = [
{
run = ''''\${EDITOR:=nvim} "$0"'';
run = ''''\${EDITOR:=nvim} "$1"'';
desc = "$EDITOR";
block = true;
}
@ -77,12 +77,12 @@ in
];
player = [
{ run = ''mpv --force-window "$0"''; }
{ run = ''${getExe pkgs.mpv} --force-window "$1"''; }
];
open = [
{
run = ''xdg-open "$0"'';
run = ''xdg-open "$1"'';
desc = "Open";
}
];

2
home/user/zellij.nix Normal file → Executable file
View file

@ -21,7 +21,7 @@ let
zellij-sessionizer-src = fetchurl {
url = "https://raw.githubusercontent.com/dachxy/zellij-sessionizer/refs/heads/main/zellij-sessionizer";
sha256 = "sha256:12kbni75x9g424bymky8cy84i354j654rfmz9bffnabbblccfbpn";
sha256 = "sha256:0p6s2mwcya448vgag42akwlfmzr9nw1vxh6gv5lmz1xmyrhkysjd";
};
zellij-sessionizer = pkgs.writeShellScriptBin "zellij-sessionizer" ''

14
home/user/zen-browser.nix Normal file → Executable file
View file

@ -14,7 +14,7 @@ let
owner = "JustAdumbPrsn";
repo = "zen-nebula";
rev = "main";
sha256 = "sha256-wtntRAkOGm6fr396kqzqk+GyPk+ytifXTqqOp0YIvlw=";
sha256 = "sha256-Eg9HsN+yDA8OdVcE9clS+FyUhVBH3ooN/odkZIVR/p4=";
};
patchedNebula =
@ -37,6 +37,7 @@ let
in
{
programs.zen-browser = {
suppressXdgMigrationWarning = true;
enable = true;
languagePacks = [
"en-US"
@ -135,14 +136,20 @@ in
};
};
home.file.".zen/${profileName}/zen-keyboard-shortcuts.json".source =
xdg.configFile."zen/${profileName}/zen-keyboard-shortcuts.json".source =
../config/zen/zen-keyboard-shortcuts.json;
home.file.".zen/${profileName}/chrome" = {
xdg.configFile."zen/${profileName}/chrome" = {
source = patchedNebula;
recursive = true;
};
systemd.user.tmpfiles.rules = [
''
L+ ${config.home.homeDirectory}/.zen - - - - ${config.home.homeDirectory}/.config/zen
''
];
xdg.mimeApps =
let
value =
@ -171,7 +178,6 @@ in
"application/xhtml+xml"
"application/json"
"application/pdf"
"text/plain"
"text/html"
]
);

1
options/default.nix Normal file → Executable file
View file

@ -1,5 +1,6 @@
{
imports = [
./systemconf.nix
./game/velocity.nix
];
}

152
options/game/velocity.nix Normal file
View file

@ -0,0 +1,152 @@
{
config,
lib,
pkgs,
...
}:
let
inherit (pkgs.writers) writeTOML;
inherit (lib)
mkIf
mkOption
mkEnableOption
mkPackageOption
types
getExe
;
cfg = config.services.velocity;
defaultSettings = {
config-version = "2.7";
motd = "<#09add3>A Velocity Server";
show-max-players = 500;
online-mode = true;
force-key-authentication = true;
prevent-client-proxy-connections = false;
player-info-forwarding-mode = "none";
forwarding-secret-file = "forwarding.secret";
announce-forge = false;
kick-existing-players = false;
ping-passthrough = "DISABLED";
sample-players-in-ping = false;
enable-player-address-logging = true;
servers = {
};
forced-hosts = {
};
advanced = {
compression-threshold = 256;
compression-level = -1;
login-ratelimit = 3000;
connection-timeout = 5000;
read-timeout = 30000;
haproxy-protocol = false;
tcp-fast-open = false;
bungee-plugin-message-channel = true;
show-ping-requests = false;
failover-on-unexpected-server-disconnect = true;
announce-proxy-commands = true;
log-command-executions = false;
log-player-connections = true;
accepts-transfers = false;
enable-reuse-port = false;
command-rate-limit = 50;
forward-commands-if-rate-limited = true;
kick-after-rate-limited-commands = 0;
tab-complete-rate-limit = 10;
kick-after-rate-limited-tab-completes = 0;
};
query = {
enabled = false;
port = 25565;
map = "Velocity";
show-plugins = false;
};
};
in
{
options.services.velocity = {
enable = mkEnableOption "Enable the minecraft proxy";
package = mkPackageOption pkgs "velocity" { };
user = mkOption {
type = types.str;
default = "velocity";
};
group = mkOption {
type = types.str;
default = "velocity";
};
host = mkOption {
type = types.str;
default = "0.0.0.0";
};
port = mkOption {
type = types.port;
default = 25565;
};
openFirewall = mkEnableOption "Open firewall for velocity" // {
default = true;
};
settings = mkOption {
type =
with types;
attrsOf (oneOf [
attrs
str
int
bool
]);
default = defaultSettings;
apply =
v:
defaultSettings
// {
bind = "${cfg.host}:${toString cfg.port}";
}
// v;
};
};
config = mkIf cfg.enable {
networking.firewall.allowedTCPPorts = mkIf cfg.openFirewall [ cfg.port ];
users.users.${cfg.user} = {
isSystemUser = true;
group = cfg.group;
};
users.groups.${cfg.group} = { };
systemd.services.velocity =
let
configFile = writeTOML "velocity.toml" cfg.settings;
in
{
wantedBy = [ "multi-user.target" ];
serviceConfig = {
User = cfg.user;
Group = cfg.group;
ExecStartPre =
let
configFilePath = "/var/lib/velocity/velocity.toml";
in
[
"${pkgs.coreutils}/bin/cp ${configFile} ${configFilePath}"
"${pkgs.coreutils}/bin/chmod 750 ${configFilePath}"
"${pkgs.coreutils}/bin/chown ${cfg.user}:${cfg.group} ${configFilePath}"
];
ExecStart = "${getExe cfg.package}";
StateDirectory = "velocity";
StateDirectoryMode = "0750";
WorkingDirectory = "/var/lib/velocity";
};
};
};
}

34
options/systemconf.nix Normal file → Executable file
View file

@ -1,4 +1,5 @@
{
self,
inputs,
config,
pkgs,
@ -63,7 +64,7 @@ in
domain = mkOption {
type = types.str;
default = "local";
description = ''Domain for system'';
description = "Domain for system";
};
username = mkOption {
@ -84,16 +85,15 @@ in
};
};
hyprland = {
enable = (mkEnableOption "Enable hyprland") // {
default = false;
};
};
niri = {
enable = (mkEnableOption "Enable niri") // {
default = false;
};
windowManager = mkOption {
type =
with types;
nullOr (enum [
"hyprland"
"niri"
"mango"
]);
default = null;
};
enableHomeManager = (mkEnableOption "Home manager") // {
@ -116,7 +116,9 @@ in
system.stateVersion = stateVersion;
programs.hyprland.enable = if (cfg.hyprland.enable && (!cfg.niri.enable)) then true else false;
programs.hyprland.enable = cfg.windowManager == "hyprland";
programs.niri.enable = cfg.windowManager == "niri";
programs.mango.enable = cfg.windowManager == "mango";
# ==== Home Manager ==== #
home-manager = mkIf cfg.enableHomeManager {
@ -124,10 +126,16 @@ in
useUserPackages = true;
useGlobalPkgs = true;
extraSpecialArgs = {
inherit helper inputs system;
inherit
helper
inputs
system
self
;
inherit (cfg) username hostname;
};
sharedModules = [
inputs.mango.hmModules.mango
inputs.hyprland.homeManagerModules.default
inputs.caelestia-shell.homeManagerModules.default
inputs.sops-nix.homeManagerModules.default

0
pkgs/assets/discord.svg Normal file → Executable file
View file

Before

Width:  |  Height:  |  Size: 474 B

After

Width:  |  Height:  |  Size: 474 B

Before After
Before After

0
pkgs/assets/peepoLeave.gif.base64 Normal file → Executable file
View file

0
pkgs/fonts/dfkai-sb/default.nix Normal file → Executable file
View file

0
pkgs/fonts/sf-pro-display-bold/default.nix Normal file → Executable file
View file

3
pkgs/overlays/default.nix Normal file → Executable file
View file

@ -1,5 +1,6 @@
[
(import ./vesktop.nix)
(import ./proton-dw-bin.nix)
# (import ./powerdns-admin.nix)
# (import ./stalwart-mail)
# (import ./stalwart)
]

0
pkgs/overlays/powerdns-admin.nix Normal file → Executable file
View file

View file

@ -0,0 +1,41 @@
final: prev: {
proton-dw-bin =
let
steamDisplayName = "Proton DW";
in
final.pkgs.stdenv.mkDerivation (finalAttrs: rec {
pname = "dwproton";
version = "10.0-16";
src = final.pkgs.fetchzip {
url = "https://dawn.wine/dawn-winery/dwproton/releases/download/${pname}-${finalAttrs.version}/${pname}-${finalAttrs.version}-x86_64.tar.xz";
hash = "sha256-9wDhtrB5IjFVZxyorAJUaivRwE85pzQ6/eDgHXCSEh8=";
};
dontUnpack = true;
dontConfigure = true;
dontBuild = true;
outputs = [
"out"
"steamcompattool"
];
installPhase = ''
runHook preInstall
echo "${finalAttrs.pname} should not be installed into environments. Please use programs.steam.extraCompatPackages instead." > $out
mkdir $steamcompattool
ln -s $src/* $steamcompattool
rm $steamcompattool/compatibilitytool.vdf
cp $src/compatibilitytool.vdf $steamcompattool
runHook postInstall
'';
preFixup = ''
substituteInPlace "$steamcompattool/compatibilitytool.vdf" \
--replace-fail "${finalAttrs.pname}-${finalAttrs.version}-x86_64" "${steamDisplayName}"
'';
});
}

View file

@ -1,5 +1,5 @@
final: prev: {
stalwart-mail = prev.stalwart-mail.overrideAttrs (oldAttrs: {
stalwart = prev.stalwart.overrideAttrs (oldAttrs: {
patches = [
./enable_root_ca.patch
];

0
pkgs/overlays/vesktop.nix Normal file → Executable file
View file

0
pkgs/patches/splash.patch Normal file → Executable file
View file

0
preview.png Normal file → Executable file
View file

Before

Width:  |  Height:  |  Size: 3.1 MiB

After

Width:  |  Height:  |  Size: 3.1 MiB

Before After
Before After

0
system/dev/dn-lap/common/boot.nix Normal file → Executable file
View file

0
system/dev/dn-lap/common/default.nix Normal file → Executable file
View file

43
system/dev/dn-lap/common/hardware-configuration.nix Normal file → Executable file
View file

@ -1,28 +1,42 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{
config,
lib,
pkgs,
modulesPath,
...
}:
{
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
boot.initrd.availableKernelModules = [ "xhci_pci" "thunderbolt" "nvme" "uas" "sd_mod" "rtsx_pci_sdmmc" ];
boot.initrd.availableKernelModules = [
"xhci_pci"
"thunderbolt"
"nvme"
"uas"
"sd_mod"
"rtsx_pci_sdmmc"
];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];
fileSystems."/" =
{
device = "/dev/disk/by-label/nixos";
fsType = "ext4";
};
fileSystems."/" = {
device = "/dev/disk/by-label/nixos";
fsType = "ext4";
};
fileSystems."/boot" =
{
device = "/dev/disk/by-label/BOOT";
fsType = "vfat";
options = [ "fmask=0077" "dmask=0077" ];
};
fileSystems."/boot" = {
device = "/dev/disk/by-label/BOOT";
fsType = "vfat";
options = [
"fmask=0077"
"dmask=0077"
];
};
swapDevices = [
{ device = "/dev/disk/by-label/swap"; }
@ -36,6 +50,5 @@
# networking.interfaces.wlp0s20f3.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode =
lib.mkDefault config.hardware.enableRedistributableFirmware;
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

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