fibe fixed my dude

This commit is contained in:
2026-01-15 18:31:30 +00:00
parent c5774e4231
commit 69e6a5a1a5
29 changed files with 483 additions and 717 deletions

View File

@@ -1,4 +1,5 @@
{ config,
{
config,
lib,
pkgs,
inputs,

View File

@@ -1,7 +1,7 @@
{
pkgs,
config,
lib,
pkgs,
...
}:
{

View File

@@ -8,6 +8,9 @@
...
}:
let
isLaptop = systemName == "laptop";
isPc = systemName == "pc";
hypr-package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland;
hypr-portal =
inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland;
@@ -35,9 +38,7 @@ in
];
settings = {
##########################################################################
# Monitors
##########################################################################
# ─── Monitors ────────────────────────────────────────────────────────────────
source = [
"./dms/outputs.conf"
#"./dms/cursor.conf"
@@ -86,9 +87,7 @@ in
# transform = 0;
# };
##########################################################################
# Autostart
##########################################################################
# ─── Autostart ───────────────────────────────────────────────────────────────
# Autostart necessary processes (like notifications daemons, status bars, etc.)
# Or execute your favorite apps at launch like this:
@@ -113,9 +112,7 @@ in
# ++ lib.optional (systemName == "pc")
# "swaybg -o HDMI-A-1 -i ${../assets/Wallpapers/138.png} -o DP-1 -i ${../assets/Wallpapers/138.png}";
##########################################################################
# Plugins
##########################################################################
# ─── Plugins ─────────────────────────────────────────────────────────────────
plugin = {
split-monitor-workspaces = {
@@ -129,18 +126,14 @@ in
};
};
##########################################################################
# Environment
##########################################################################
# ─── Environment ─────────────────────────────────────────────────────────────
env = [
"XCURSOR_SIZE, 24"
"HYPRCURSOR_SIZE, 24"
];
##########################################################################
# General / Render / Decoration / Animations
##########################################################################
# ─── General / Render / Decoration / Animations ─────────────────────────────
# https://wiki.hyprland.org/Configuring/Variables/
# https://wiki.hyprland.org/Configuring/Variables/#general
@@ -218,9 +211,7 @@ in
];
};
##########################################################################
# Layouts
##########################################################################
# ─── Layouts ─────────────────────────────────────────────────────────────────
# See https://wiki.hyprland.org/Configuring/Dwindle-Layout/ for more
dwindle = {
@@ -236,9 +227,7 @@ in
new_on_top = true;
};
##########################################################################
# Misc / Input / Gestures / Devices
##########################################################################
# ─── Misc / Input / Gestures / Devices ───────────────────────────────────────
# https://wiki.hyprland.org/Configuring/Variables/#misc
misc = {
@@ -251,8 +240,8 @@ in
# https://wiki.hyprland.org/Configuring/Variables/#input
input = {
kb_layout = lib.mkMerge [
(lib.mkIf (systemName == "laptop") "ie")
(lib.mkIf (systemName == "pc") "us")
(lib.mkIf isLaptop "ie")
(lib.mkIf isPc "us")
];
repeat_rate = 40;
repeat_delay = 500;
@@ -281,9 +270,7 @@ in
sensitivity = -0.5;
};
##########################################################################
# Binds
##########################################################################
# ─── Binds ───────────────────────────────────────────────────────────────────
bind = [
# Launcher / apps
@@ -394,9 +381,7 @@ in
binds = [ ];
##########################################################################
# Rules (windows / workspaces)
##########################################################################
# ─── Rules (windows / workspaces) ────────────────────────────────────────────
# See https://wiki.hyprland.org/Configuring/Window-Rules/ for more
# See https://wiki.hyprland.org/Configuring/Workspace-Rules/ for workspace rules

View File

@@ -7,6 +7,10 @@
...
}:
let
isLaptop = systemName == "laptop";
isPc = systemName == "pc";
in
{
services = {
hypridle = {
@@ -24,19 +28,19 @@
on-timeout = "loginctl lock-session";
}
]
++ lib.optional (systemName == "laptop") {
++ lib.optional isLaptop {
timeout = 700;
on-timeout = "hyprctl dispatch dpms off"; # Turns off all displays
on-resume = "hyprctl dispatch dpms on"; # Turns displays back on
on-timeout = "hyprctl dispatch dpms off";
on-resume = "hyprctl dispatch dpms on";
}
++ lib.optional (systemName == "laptop") {
++ lib.optional isLaptop {
timeout = 800;
on-timeout = "systemctl suspend-then-hibernate";
}
++ lib.optional (systemName == "pc") {
timeout = 700; # Adjust timeout as needed (in seconds)
on-timeout = "hyprctl dispatch dpms off"; # Turns off all displays
on-resume = "hyprctl dispatch dpms on"; # Turns displays back on
++ lib.optional isPc {
timeout = 700;
on-timeout = "hyprctl dispatch dpms off";
on-resume = "hyprctl dispatch dpms on";
};
};
};

View File

@@ -162,7 +162,7 @@
# You can change how the focus ring looks.
focus-ring = {
#omment this line to disable the focus ring.
# Uncomment this line to disable the focus ring.
# off
# How many logical pixels the ring extends out from the windows.

View File

@@ -1,11 +1,16 @@
{
pkgs,
lib,
config,
lib,
pkgs,
window_manager,
systemName,
...
}:
let
isLaptop = systemName == "laptop";
isPc = systemName == "pc";
in
{
wayland.windowManager.river = {
enable = window_manager == "river" || window_manager == "all";
@@ -26,21 +31,19 @@
editor="emacs"
riverctl input "pointer-2362-8197-ASUP1204:00_093A:2005_Touchpad" tap enabled
riverctl keyboard-layout -options "grp:ctrl_space_toggle" ${
if systemName == "laptop" then "ie,us" else "us"
riverctl keyboard-layout -options "grp:ctrl_space_toggle" ${
if isLaptop
then "ie,us"
else "us"
}
#riverctl spawn 'export XDG_CURRENT_DESKTOP=river'
#riverctl spawn 'systemctl --user restart xdg-desktop-portal'
riverctl spawn 'dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP'
riverctl spawn 'swaybg ${
# Handle laptop case
lib.optionalString (systemName == "laptop") "-o eDP-1 -i ${../assets/Wallpapers/138.png}"
lib.optionalString isLaptop "-o eDP-1 -i ${../assets/Wallpapers/138.png}"
}${
# Handle PC case (appends to laptop case if needed, but conditions should be mutually exclusive)
lib.optionalString (
systemName == "pc"
) "-o HDMI-A-1 -i ${../assets/Wallpapers/138.png} -o DP-1 -i ${../assets/Wallpapers/138.png}"
lib.optionalString isPc "-o HDMI-A-1 -i ${../assets/Wallpapers/138.png} -o DP-1 -i ${../assets/Wallpapers/138.png}"
}'
#riverctl spawn '/home/mrfluffy/.config/script/mic-gain-fix.sh'
riverctl spawn 'waybar &'
@@ -57,12 +60,9 @@
riverctl set-cursor-warp on-focus-change
#riverctl xcursor-theme oreo_spark_pink_cursors
riverctl spawn '${
# Handle laptop case
lib.optionalString (systemName == "laptop") "wlr-randr --output eDP-1 --mode 1920x1080@60"
lib.optionalString isLaptop "wlr-randr --output eDP-1 --mode 1920x1080@60"
}${
# Handle PC case (appends to laptop case if needed, but conditions should be mutually exclusive)
lib.optionalString (systemName == "pc")
"wlr-randr --output DP-1 --mode 2560x1440@144 --pos 1920,0 --output HDMI-A-1 --mode 1920x1080@60 --pos 0,0"
lib.optionalString isPc "wlr-randr --output DP-1 --mode 2560x1440@144 --pos 1920,0 --output HDMI-A-1 --mode 1920x1080@60 --pos 0,0"
}'
# This is the example configuration file for river.

View File

@@ -1,5 +1,6 @@
{
config,
lib,
pkgs,
inputs,
window_manager,
@@ -16,14 +17,12 @@
#tags button.occupied {
color: inherit;
background-color: #6a548d
background-color: #6a548d;
}
#tags button.focused {
color: #f8f8f2;
background-color: #aa86e1 ;
background-color: #aa86e1;
}
#tags button.urgent {
@@ -119,17 +118,16 @@
spacing = 4; # Gaps between modules (4px)
# Choose the order of the modules
modules-left =
if window_manager == "river" then
[
"river/tags"
"custom/media"
]
else if window_manager == "hyprland" then
[
"hyprland/workspaces"
]
else
[ ];
if window_manager == "river"
then [
"river/tags"
"custom/media"
]
else if window_manager == "hyprland"
then [
"hyprland/workspaces"
]
else [ ];
modules-center = [
];

View File

@@ -38,40 +38,40 @@
defaultApplications =
let
browser = [ "firefox.desktop" ];
browser = [ "firefox.desktop" ];
fileManager = [ "pcmanfm.desktop" ];
editor = [ "emacs.desktop" ];
player = [ "mpv.desktop" ];
viewer = [ "imv-dir.desktop" ];
reader = [ "org.pwmt.zathura.desktop" ];
editor = [ "emacs.desktop" ];
player = [ "mpv.desktop" ];
viewer = [ "imv-dir.desktop" ];
reader = [ "org.pwmt.zathura.desktop" ];
in {
# Documents
"application/pdf" = reader;
"application/pdf" = reader;
"application/epub" = reader;
# Text / markup
"text/plain" = editor;
"text/plain" = editor;
"application/x-wine-extension-ini" = editor;
"text/html" = browser;
"text/xml" = browser;
"text/html" = browser;
"text/xml" = browser;
# Web / XML-ish
"application/json" = browser;
"application/xml" = browser;
"application/xhtml+xml" = browser;
"application/xhtml_xml" = browser;
"application/rdf+xml" = browser;
"application/rss+xml" = browser;
"application/x-extension-htm" = browser;
"application/x-extension-html" = browser;
"application/json" = browser;
"application/xml" = browser;
"application/xhtml+xml" = browser;
"application/xhtml_xml" = browser;
"application/rdf+xml" = browser;
"application/rss+xml" = browser;
"application/x-extension-htm" = browser;
"application/x-extension-html" = browser;
"application/x-extension-shtml" = browser;
"application/x-extension-xht" = browser;
"application/x-extension-xht" = browser;
"application/x-extension-xhtml" = browser;
# URL schemes
"x-scheme-handler/about" = browser;
"x-scheme-handler/ftp" = browser;
"x-scheme-handler/http" = browser;
"x-scheme-handler/ftp" = browser;
"x-scheme-handler/http" = browser;
"x-scheme-handler/https" = browser;
# Files / directories
@@ -80,20 +80,20 @@
# Audio
"audio/mpeg" = player;
"audio/aac" = player;
"audio/aac" = player;
"audio/flac" = player;
"audio/wav" = player;
"audio/wav" = player;
# Video
"video/mp4" = player;
"video/vnd.mpegurl" = player;
"video/x-matroska" = player;
"video/mp4" = player;
"video/vnd.mpegurl" = player;
"video/x-matroska" = player;
"application/x-mpegURL" = player;
# Images
"image/gif" = viewer;
"image/gif" = viewer;
"image/jpeg" = viewer;
"image/png" = viewer;
"image/png" = viewer;
"image/webp" = viewer;
};
};
@@ -102,13 +102,13 @@
enable = true;
createDirectories = true;
download = "${config.home.homeDirectory}/Downloads";
documents = "${config.home.homeDirectory}/Documents";
desktop = "${config.home.homeDirectory}/Desktop";
videos = "${config.home.homeDirectory}/Videos";
pictures = "${config.home.homeDirectory}/Pictures";
music = "${config.home.homeDirectory}/Music";
templates = "${config.home.homeDirectory}/.local/share/templates";
download = "${config.home.homeDirectory}/Downloads";
documents = "${config.home.homeDirectory}/Documents";
desktop = "${config.home.homeDirectory}/Desktop";
videos = "${config.home.homeDirectory}/Videos";
pictures = "${config.home.homeDirectory}/Pictures";
music = "${config.home.homeDirectory}/Music";
templates = "${config.home.homeDirectory}/.local/share/templates";
publicShare = "${config.home.homeDirectory}/.local/share/public";
};

View File

@@ -1,13 +1,13 @@
{
pkgs,
lib,
config,
lib,
pkgs,
...
}:
{
programs.zsh = {
enable = true;
dotDir = "${config.xdg.configHome}/zsh";
enable = true;
dotDir = "${config.xdg.configHome}/zsh";
plugins = [
# pkgs.zsh-autosuggestions
@@ -15,7 +15,7 @@
];
autosuggestion = {
enable = true;
enable = true;
highlight = "fg=#64677a,bold,underline";
};
@@ -24,51 +24,51 @@
};
sessionVariables = {
LD_LIBRARY_PATH = "/run/current-system/sw/share/nix-ld/lib";
HISTSIZE = 3000;
SAVEHIST = 3000;
CARGO_HOME = "$XDG_DATA_HOME/cargo";
GNUPGHOME = "$XDG_DATA_HOME/gnupg";
GOPATH = "$XDG_DATA_HOME/go";
GRADLE_USER_HOME = "$XDG_DATA_HOME/gradle";
IPYTHONDIR = "$XDG_CONFIG_HOME/ipython";
JUPYTER_CONFIG_DIR = "$XDG_CONFIG_HOME/jupyter";
LESSHISTFILE = "$XDG_CACHE_HOME/less/history";
NUGET_PACKAGES = "$XDG_CACHE_HOME/NuGetPackages";
PYTHONSTARTUP = "$XDG_CONFIG_HOME/python/pythonrc";
KERAS_HOME = "$XDG_STATE_HOME/keras";
RUSTUP_HOME = "$XDG_DATA_HOME/rustup";
XCOMPOSECACHE = "$XDG_CACHE_HOME/X11/xcompose";
SSB_HOME = "$XDG_DATA_HOME/zoom";
HISTFILE = "$XDG_STATE_HOME/zsh/history";
LD_LIBRARY_PATH = "/run/current-system/sw/share/nix-ld/lib";
HISTSIZE = 3000;
SAVEHIST = 3000;
CARGO_HOME = "$XDG_DATA_HOME/cargo";
GNUPGHOME = "$XDG_DATA_HOME/gnupg";
GOPATH = "$XDG_DATA_HOME/go";
GRADLE_USER_HOME = "$XDG_DATA_HOME/gradle";
IPYTHONDIR = "$XDG_CONFIG_HOME/ipython";
JUPYTER_CONFIG_DIR = "$XDG_CONFIG_HOME/jupyter";
LESSHISTFILE = "$XDG_CACHE_HOME/less/history";
NUGET_PACKAGES = "$XDG_CACHE_HOME/NuGetPackages";
PYTHONSTARTUP = "$XDG_CONFIG_HOME/python/pythonrc";
KERAS_HOME = "$XDG_STATE_HOME/keras";
RUSTUP_HOME = "$XDG_DATA_HOME/rustup";
XCOMPOSECACHE = "$XDG_CACHE_HOME/X11/xcompose";
SSB_HOME = "$XDG_DATA_HOME/zoom";
HISTFILE = "$XDG_STATE_HOME/zsh/history";
};
shellAliases = {
ns = "nh os switch --specialisation 00-main-system";
ns = "nh os switch --specialisation 00-main-system";
nu = "(cd ~/nixos-dots && nix flake update --commit-lock-file) && echo 'flake.lock updated'";
ne = "emacsclient -c ~/nixos-dots/configuration.nix";
ne = "emacsclient -c ~/nixos-dots/configuration.nix";
ls = "exa -lag --icons";
upload = "~/.config/script/upload.sh";
record = "~/.config/script/record.sh";
speak = "~/.config/script/wisper.sh";
vim = "nvim";
cat = "bat";
anime = "~/repos/ani-cli/ani-cli";
hentai = "~/repos/and-scripts/fap-cli";
manga = "manga-cli";
yt = "~/repos/ytfzf/ytfzf --thumb-viewer='kitty' -t";
cd = "z";
rm = "rip";
df = "duf";
time = "hyperfine";
kami = "~/Documents/Rust/kami/target/release/kami";
calc = "cpc";
pdf = "mupdf";
emacs = "emacs";
river = "dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=river && river";
cp = "xcp";
wget = "wget --hsts-file=$XDG_DATA_HOME/wget-hsts";
ls = "exa -lag --icons";
upload = "~/.config/script/upload.sh";
record = "~/.config/script/record.sh";
speak = "~/.config/script/wisper.sh";
vim = "nvim";
cat = "bat";
anime = "~/repos/ani-cli/ani-cli";
hentai = "~/repos/and-scripts/fap-cli";
manga = "manga-cli";
yt = "~/repos/ytfzf/ytfzf --thumb-viewer='kitty' -t";
cd = "z";
rm = "rip";
df = "duf";
time = "hyperfine";
kami = "~/Documents/Rust/kami/target/release/kami";
calc = "cpc";
pdf = "mupdf";
emacs = "emacs";
river = "dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=river && river";
cp = "xcp";
wget = "wget --hsts-file=$XDG_DATA_HOME/wget-hsts";
};
initContent = ''