Compare commits

...

11 commits

Author SHA1 Message Date
38ef01db4a
Further module cleanup 2025-03-10 23:47:13 +01:00
71718f1981
make eww more reusable, tinker with doom emacs and agda 2025-03-09 19:59:58 +01:00
bffcdeca73
flake.lock: Update
Flake lock file updates:

• Updated input 'home-manager':
    'github:nix-community/home-manager/74f0a8546e3f2458c870cf90fc4b38ac1f498b17?narHash=sha256-Dd/GhJ9qKmUwuhgt/PAROG8J6YdU2ZjtJI9SQX5sVQI%3D' (2025-02-25)
  → 'github:nix-community/home-manager/2967de4d1146f1b6aa820eed85b823ea2ebfd0fa?narHash=sha256-KSOHzP9gnxaF9YdtwFOPwnFvJEikg/uAvZ6M6VA/FQc%3D' (2025-03-09)
• Updated input 'hyprland-contrib':
    'github:hyprwm/contrib/59178a657b7e09ddf82b9e79681f482b6c2f378b?narHash=sha256-kXdVW89VJoG%2BW6N1u0m8hgK2VIWUAweQVzehRZwdNSo%3D' (2025-02-13)
  → 'github:hyprwm/contrib/0e40ccfc2d6772f9b7d5e1b50c56fb5e468a18fb?narHash=sha256-inSG4OUSdCHXSJZhLNcCUA1s0Ebomr5%2Bv4x3FE/XQ3M%3D' (2025-03-06)
• Updated input 'unstable':
    'github:nixos/nixpkgs/0196c0175e9191c474c26ab5548db27ef5d34b05?narHash=sha256-WGaHVAjcrv%2BCun7zPlI41SerRtfknGQap281%2BAakSAw%3D' (2025-02-24)
  → 'github:nixos/nixpkgs/36fd87baa9083f34f7f5027900b62ee6d09b1f2f?narHash=sha256-Wh7esNh7G24qYleLvgOSY/7HlDUzWaL/n4qzlBePpiw%3D' (2025-03-07)
2025-03-09 18:52:50 +01:00
439704c6bd
flake.lock: Update
Flake lock file updates:

• Updated input 'home-manager':
    'github:nix-community/home-manager/18fa9f323d8adbb0b7b8b98a8488db308210ed93?narHash=sha256-4ATtQqBlgsGqkHTemta0ydY6f7JBRXz4Hf574NHQpkg%3D' (2025-02-01)
  → 'github:nix-community/home-manager/74f0a8546e3f2458c870cf90fc4b38ac1f498b17?narHash=sha256-Dd/GhJ9qKmUwuhgt/PAROG8J6YdU2ZjtJI9SQX5sVQI%3D' (2025-02-25)
• Updated input 'hyprland-contrib':
    'github:hyprwm/contrib/d449f6e1fc31084437ebc0c45057ee656f593efd?narHash=sha256-8ytokHHcKusbspRaiGP38s7fHU105JRvO9GRTzcRklg%3D' (2025-01-29)
  → 'github:hyprwm/contrib/59178a657b7e09ddf82b9e79681f482b6c2f378b?narHash=sha256-kXdVW89VJoG%2BW6N1u0m8hgK2VIWUAweQVzehRZwdNSo%3D' (2025-02-13)
• Updated input 'unstable':
    'github:nixos/nixpkgs/3a228057f5b619feb3186e986dbe76278d707b6e?narHash=sha256-xvTo0Aw0%2Bveek7hvEVLzErmJyQkEcRk6PSR4zsRQFEc%3D' (2025-02-01)
  → 'github:nixos/nixpkgs/0196c0175e9191c474c26ab5548db27ef5d34b05?narHash=sha256-WGaHVAjcrv%2BCun7zPlI41SerRtfknGQap281%2BAakSAw%3D' (2025-02-24)
2025-02-26 13:32:33 +01:00
5d211be17e
gunther hypr update 2025-02-26 13:32:19 +01:00
f403b17ed1
Fix security flaw and remove systemd-boot timeout for gunther 2025-02-16 22:47:33 +01:00
c7d63aaa53
remove artifact 2025-02-16 22:37:05 +01:00
45f3400d43
Merge branch 'main' into hypr-module 2025-02-16 22:36:38 +01:00
3f927caeda
minor 2025-02-09 15:54:57 +01:00
b61663d775
fix hyprpaper 2025-02-05 23:45:56 +01:00
40d38c7663
Started working on hyprland module 2025-02-05 23:43:14 +01:00
25 changed files with 469 additions and 531 deletions

View file

@ -50,6 +50,7 @@
boot.loader.efi.canTouchEfiVariables = true;
boot.loader.efi.efiSysMountPoint = "/boot";
boot.loader.systemd-boot.enable = true;
boot.loader.systemd-boot.editor = false;
boot.plymouth.enable = true;
# udev for brillo

View file

@ -7,11 +7,11 @@
]
},
"locked": {
"lastModified": 1738448366,
"narHash": "sha256-4ATtQqBlgsGqkHTemta0ydY6f7JBRXz4Hf574NHQpkg=",
"lastModified": 1741540808,
"narHash": "sha256-KSOHzP9gnxaF9YdtwFOPwnFvJEikg/uAvZ6M6VA/FQc=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "18fa9f323d8adbb0b7b8b98a8488db308210ed93",
"rev": "2967de4d1146f1b6aa820eed85b823ea2ebfd0fa",
"type": "github"
},
"original": {
@ -27,11 +27,11 @@
]
},
"locked": {
"lastModified": 1738176500,
"narHash": "sha256-8ytokHHcKusbspRaiGP38s7fHU105JRvO9GRTzcRklg=",
"lastModified": 1741279209,
"narHash": "sha256-inSG4OUSdCHXSJZhLNcCUA1s0Ebomr5+v4x3FE/XQ3M=",
"owner": "hyprwm",
"repo": "contrib",
"rev": "d449f6e1fc31084437ebc0c45057ee656f593efd",
"rev": "0e40ccfc2d6772f9b7d5e1b50c56fb5e468a18fb",
"type": "github"
},
"original": {
@ -49,11 +49,11 @@
},
"unstable": {
"locked": {
"lastModified": 1738410390,
"narHash": "sha256-xvTo0Aw0+veek7hvEVLzErmJyQkEcRk6PSR4zsRQFEc=",
"lastModified": 1741379970,
"narHash": "sha256-Wh7esNh7G24qYleLvgOSY/7HlDUzWaL/n4qzlBePpiw=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "3a228057f5b619feb3186e986dbe76278d707b6e",
"rev": "36fd87baa9083f34f7f5027900b62ee6d09b1f2f",
"type": "github"
},
"original": {

View file

@ -21,9 +21,6 @@
# Docker
virtualisation.docker.enable = true;
services.emacs.package = pkgs.emacs29-pgtk;
services.emacs.enable = true;
# optimize power usage
powerManagement.enable = true;
@ -39,6 +36,7 @@
kernelPackages = pkgs.linuxPackages_latest;
# systemd-boot
loader.timeout = null;
loader.efi.canTouchEfiVariables = true;
loader.efi.efiSysMountPoint = "/boot";
loader.systemd-boot = {
@ -54,6 +52,7 @@
enable = true;
sortKey = "z_edk2";
};
editor = false;
};
# plymouth
@ -186,9 +185,6 @@
qpdfview
swww
# greeter
greetd.gtkgreet
# deps for hyprland / eww
socat

View file

@ -78,7 +78,6 @@
;;
;; You can also try 'gd' (or 'C-c c d') to jump to their definition and see how
;; they are implemented.
(envrc-global-mode)
(setq +latex-viewers '(pdf-tools))
(eval-after-load "tex"
'(add-to-list 'TeX-command-list
@ -87,7 +86,6 @@
(pdf-tools-install)
(evil-global-set-key 'normal (kbd "SPC t t") #'treemacs)
;; The following is a hack to use the right agda version for my thesis...
;; (load-file "/nix/store/38cw6va0dhln7gknwsz7ghazlcldjgdc-Agda-2.6.3-data/share/ghc-9.2.8/x86_64-linux-ghc-9.2.8/Agda-2.6.3/emacs-mode/agda2.el")
;;(load-file (let ((coding-system-for-read 'utf-8))
;; (shell-command-to-string "agda-mode locate")))
(load-file "/nix/store/p2b07qnkw664ni99is80ja4hvynllhw8-Agda-2.7.0.1-data/share/ghc-9.6.6/x86_64-linux-ghc-9.6.6/Agda-2.7.0.1/emacs-mode/agda2.el")
(add-to-list 'auto-mode-alist '("\\.lagda.md\\'" . agda2-mode))
(envrc-global-mode)

View file

@ -114,7 +114,7 @@
;;tty ; improve the terminal Emacs experience
:lang
(agda +local) ; types of types of types of types...
;;(agda +local) ; types of types of types of types...
;;beancount ; mind the GAAP
;;(cc +lsp) ; C > C++ == 1
;;clojure ; java with a lisp

View file

@ -1,39 +0,0 @@
# 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, ... }:
{
imports =
[ (modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod" ];
boot.initrd.kernelModules = [ "amdgpu" ];
boot.kernelModules = [ "kvm-intel" ];
boot.kernelPackages = pkgs.linuxPackages_latest;
fileSystems."/" =
{ device = "/dev/disk/by-uuid/8dce9c4c-8b94-4b1e-af4f-3fa5450f2b74";
fsType = "ext4";
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/3DD6-C061";
fsType = "vfat";
options = [ "fmask=0077" "dmask=0077" ];
};
swapDevices = [ ];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's
# still possible to use this option, but it's recommended to use it in conjunction
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
networking.useDHCP = lib.mkDefault true;
# networking.interfaces.enp6s0.useDHCP = lib.mkDefault true;
# networking.interfaces.wlp5s0.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

View file

@ -1,111 +0,0 @@
* {
bg-col: #24273a;
bg-col-light: #24273a;
border-col: #24273a;
selected-col: #24273a;
blue: #8aadf4;
fg-col: #cad3f5;
fg-col2: #ed8796;
grey: #6e738d;
width: 600;
font: "JetBrainsMono Nerd Font 14";
}
element-text, element-icon , mode-switcher {
background-color: inherit;
text-color: inherit;
}
window {
height: 360px;
border: 3px;
border-color: @border-col;
background-color: @bg-col;
}
mainbox {
background-color: @bg-col;
}
inputbar {
children: [prompt,entry];
background-color: @bg-col;
border-radius: 5px;
padding: 2px;
}
prompt {
background-color: @blue;
padding: 6px;
text-color: @bg-col;
border-radius: 3px;
margin: 20px 0px 0px 20px;
}
textbox-prompt-colon {
expand: false;
str: ":";
}
entry {
padding: 6px;
margin: 20px 0px 0px 10px;
text-color: @fg-col;
background-color: @bg-col;
}
listview {
border: 0px 0px 0px;
padding: 6px 0px 0px;
margin: 10px 0px 0px 20px;
columns: 2;
lines: 5;
background-color: @bg-col;
}
element {
padding: 5px;
background-color: @bg-col;
text-color: @fg-col ;
}
element-icon {
size: 25px;
}
element selected {
background-color: @selected-col ;
text-color: @fg-col2 ;
}
mode-switcher {
spacing: 0;
}
button {
padding: 10px;
background-color: @bg-col-light;
text-color: @grey;
vertical-align: 0.5;
horizontal-align: 0.5;
}
button selected {
background-color: @bg-col;
text-color: @blue;
}
message {
background-color: @bg-col-light;
margin: 2px;
padding: 2px;
border-radius: 5px;
}
textbox {
padding: 6px;
margin: 20px 0px 0px 20px;
text-color: @blue;
background-color: @bg-col-light;
}

View file

@ -1,187 +0,0 @@
{ pkgs, ... }:
{
services.hyprpaper.enable = true;
# hyprland setup
wayland.windowManager.hyprland = {
enable = true;
xwayland.enable = true;
settings = {
ecosystem = {
no_donation_nag = true;
};
workspace = [
"1, monitor:HDMI-A-1, default:true, persistent:true"
"2, monitor:DP-1 , default:true, persistent:true"
"special:scratchpad , on-created-empty:foot"
];
monitor = [
"DP-1 , 2560x1440@144, 1920x0, 1"
"HDMI-A-1, 1920x1080@75 , 0x0 , 1"
];
input = {
kb_layout = "de";
kb_variant = "us";
follow_mouse = 1;
};
"$mod" = "SUPER";
"$modd" = "SUPER_SHIFT";
general = {
gaps_in = 8;
gaps_out = 15;
border_size = 3;
resize_on_border = true;
layout = "dwindle";
"col.active_border" = "rgba(cba6f7ff) rgba(89b4faff) rgba(94e2d5ff) 10deg";
"col.inactive_border" = "0xff45475a";
"col.nogroup_border" = "0xff89dceb";
"col.nogroup_border_active" = "0xfff9e2af";
};
decoration = {
blur = {
new_optimizations = true;
size = 1;
passes = 1;
};
shadow = {
enabled = true;
range = 100;
render_power = 5;
color = "0x33000000";
color_inactive = "0x22000000";
};
rounding = 15;
};
animations = {
enabled = 1;
bezier = "overshot,0.13,0.99,0.29,1.1";
animation = [
"windows,1,4,overshot,slide"
"border,1,10,default"
"fade,1,10,default"
"workspaces,1,6,overshot,slidevert"
];
};
misc = {
disable_hyprland_logo = true;
};
bind = [
# opening programs
"$mod, Return, exec, foot"
"$mod, D, exec, tofi-drun | xargs hyprctl dispatch exec --"
"$mod, M, exit, "
"$mod, Q, killactive, "
# moving around
"$mod, left , movefocus, l"
"$mod, right, movefocus, r"
"$mod, down , movefocus, d"
"$mod, up , movefocus, u"
# moving windows
"$modd, left , movewindow, l"
"$modd, right, movewindow, r"
"$modd, down , movewindow, d"
"$modd, up , movewindow, u"
# workspaces
"$mod, 1, workspace, 1"
"$mod, 2, workspace, 2"
"$mod, 3, workspace, 3"
"$mod, 4, workspace, 4"
"$mod, 5, workspace, 5"
"$mod, 6, workspace, 6"
"$modd, 1, movetoworkspacesilent, 1"
"$modd, 2, movetoworkspacesilent, 2"
"$modd, 3, movetoworkspacesilent, 3"
"$modd, 4, movetoworkspacesilent, 4"
"$modd, 5, movetoworkspacesilent, 5"
"$modd, 6, movetoworkspacesilent, 6"
# fullscreen
"$mod, F11, fullscreen, 0"
# "$mod, m, fullscreen, 1" # maximize
# floating
"$mod, F, togglefloating, active"
# screenshot
", Print, exec, grimblast copysave area $HOME\"/screenshots/\"$(date +'%F-%T.png');"
# scratchpad
"$mod, C, togglespecialworkspace, scratchpad"
# status bar
"$mod, T, exec, eww open --toggle top-bar"
];
bindm = [
"$mod, mouse:272, movewindow"
];
bindle = [
", XF86AudioRaiseVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 1%+"
", XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 1%-"
", XF86AudioMute, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 0%"
];
exec-once = [
"bash ~/Git/nixos/gunther/hypr/start.sh"
"dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP"
];
};
};
# tell electron to use wayland
home.sessionVariables.NIXOS_OZONE_WL = "1";
# terminal
programs.foot = {
enable = true;
settings = {
main = {
font = "monospace:size=12";
dpi-aware = "yes";
};
colors = {
foreground = "cad3f5";
background = "24273a";
regular0 = "494d64";
regular1 = "ed8796";
regular3 = "eed49f";
regular4 = "8aadf4";
regular5 = "f5bde6";
regular6 = "8bd5ca";
regular7 = "b8c0e0";
bright0 = "5b6078";
bright1 = "ed8796";
bright3 = "eed49f";
bright4 = "8aadf4";
bright5 = "f5bde6";
bright6 = "8bd5ca";
bright7 = "a5adcb";
};
};
};
services.mako = {
enable = true;
extraConfig = ''
background-color=#24273a
text-color=#cad3f5
border-color=#8aadf4
progress-color=over #363a4f
sort=-time
layer=overlay
width=300
height=110
border-size=2
border-radius=15
max-icon-size=64
default-timeout=5000
ignore-timeout=1
[urgency=high]
border-color=#f5a97f
'';
};
}

View file

@ -1,5 +0,0 @@
preload = ~/Git/nixos/gunther/hypr/wallpaper.jpg
#
#set the default wallpaper(s) seen on inital workspace(s) --depending on the number of monitors used
wallpaper = monitor1,~/Git/nixos/gunther/hypr/wallpaper.jpg
wallpaper = monitor2,~/Git/nixos/gunther/hypr/wallpaper.jpg

View file

@ -2,29 +2,32 @@
{
imports = [
./../common
./hypr/hyprland.nix
./eww
./../modules/hyprland
];
/* The home.stateVersion option does not have a default and must be set */
home.stateVersion = "24.11";
home.username = "leonv";
home.homeDirectory = "/home/leonv";
modules.hyprland = {
enable = true;
hyprpaper = {
enable = true;
wallpaper = ./wallpaper.jpg;
};
monitor = [
"DP-1 , 2560x1440@144, 1920x0, 1"
"HDMI-A-1, 1920x1080@75 , 0x0 , 1"
];
workspace = [
"1, monitor:HDMI-A-1, default:true, persistent:true"
"2, monitor:DP-1 , default:true, persistent:true"
"special:scratchpad , on-created-empty:foot"
];
};
home.packages = with pkgs; [
go
# theme for gtk applications
orchis-theme
(catppuccin-gtk.override {
accents = [ "flamingo" ];
size = "compact";
tweaks = [ "rimless" "black" ];
variant = "macchiato";
})
# smt solver for liquid haskell
z3
# operating systems stuff
# operating systems stuff / C/C++
grub2
xorriso
qemu
@ -32,69 +35,33 @@
man-pages
man-pages-posix
cpplint
# stuff
swi-prolog
jq
vlc
openvpn
signal-desktop
discord-canary
firefox-wayland
google-chrome
thunderbird
gimp
qpdfview
wget
fontforge
gparted
eza
ripgrep
fd
zoom-us
obsidian
zotero
# development
jetbrains.idea-ultimate
gnumake
ghostscript
jdk11
gcc
gdb
gnumake
# prolog
swi-prolog
# go
go
# java
jetbrains.idea-ultimate
jdk11
# haskell
doxygen
haskell.compiler.ghc981
cabal-install
haskell-language-server
# script
ghostscript
python3
python3Packages.pygments
unifont
anki
pandoc
# hyprland
kitty
networkmanagerapplet
mako
libnotify
pavucontrol
hyprpaper
qimgv
playerctl
hyprpicker
wev
inputs.hyprland-contrib.packages.${pkgs.system}.grimblast
bluez
htop
file-roller
zip
unzip
# yubikey
yubico-pam
yubikey-manager
# proof assistants
unifont
(agda.withPackages [
agdaPackages.standard-library
agdaPackages.agda-categories
@ -105,90 +72,18 @@
# for emacs
texlab
shellcheck
emacs
];
# emacs
xdg.configHome = /home/leonv/.config;
xdg.configFile."doom/init.el".source = ./doom/init.el;
xdg.configFile."doom/config.el".source = ./doom/config.el;
xdg.configFile."doom/packages.el".source = ./doom/packages.el;
home.sessionPath = [ "$HOME/.config/emacs/bin" ];
programs.home-manager.enable = true;
programs.zsh = {
enable = true;
shellAliases = {
clean = "sudo nix-env --delete-generations old --profile /nix/var/nix/profiles/system && sudo /nix/var/nix/profiles/system/bin/switch-to-configuration switch && sudo nix-store --gc";
ls = "eza";
ll = "eza -l";
l = "eza -lah";
code = "codium";
alg = "code ~/Git/algprog/tex";
nixos = "code ~/Git/nixos";
};
initExtra = ''
function rebuild () {
sudo nixos-rebuild switch --flake /home/leonv/Git/nixos
sudo cp -r /home/leonv/Git/nixos /etc/
}
'';
oh-my-zsh.enable = true;
};
gtk = {
enable = true;
theme = {
name = "Catppuccin-Macchiato-Compact-Flamingo-Dark";
package = pkgs.catppuccin-gtk.override {
accents = [ "flamingo" ];
size = "compact";
tweaks = [ "rimless" "black" ];
variant = "macchiato";
};
};
iconTheme = {
name = "Dracula";
package = pkgs.dracula-icon-theme;
};
font = {
name = "NotoSans Nerd Font";
};
gtk3 = {
extraConfig.gtk-application-prefer-dark-theme = true;
};
};
home.sessionVariables.GTK_THEME = "Catppuccin-Macchiato-Compact-Flamingo-Dark";
home.sessionPath = [ "$HOME/.config/emacs/bin" ];
home.pointerCursor = {
gtk.enable = true;
package = pkgs.bibata-cursors;
name = "Bibata-Modern-Classic";
size = 24;
};
programs.tofi = {
enable = true;
settings = {
width = "100%";
height = "100%";
border-width = 0;
outline-width = 0;
padding-left = "35%";
padding-top = "35%";
result-spacing = 25;
num-results = 5;
font = "monospace";
background-color = "#000A";
};
};
dconf.settings = {
# GTK4 Setup
"org/gnome/desktop/interface" = {
gtk-theme = "Catppuccin-Macchiato-Compact-Flamingo-Dark";
color-scheme = "prefer-dark";
};
};
# for bluetooth headset functionality
services.mpris-proxy.enable = true;
}

View file

Before

Width:  |  Height:  |  Size: 576 KiB

After

Width:  |  Height:  |  Size: 576 KiB

View file

@ -0,0 +1,380 @@
{ config, pkgs, lib, inputs, ... }:
with lib;
with types;
let
cfg = config.modules.hyprland;
in
{
imports = [
./eww
];
options.modules.hyprland = {
enable = mkEnableOption "Hyprland Wrapper";
# eww
oled = mkOption {
type = bool;
description = ''Special theming for OLED monitors.'';
default = false;
};
# monitor setup
monitor = mkOption {
type = listOf str;
description = ''Monitor setup'';
example = ''[
"DP-1 , 2560x1440@144, 1920x0, 1"
"HDMI-A-1, 1920x1080@75 , 0x0 , 1"
];'';
};
# workspaces
workspace = mkOption {
type = listOf str;
description = ''Workspace setup'';
example = ''[
"1, monitor:HDMI-A-1, default:true, persistent:true"
"2, monitor:DP-1 , default:true, persistent:true"
"special:scratchpad , on-created-empty:foot"
];'';
};
# hyprpaper
hyprpaper = {
enable = mkEnableOption "Hyprpaper wrapper";
wallpaper = mkOption {
type = path;
default = [];
description = ''
Wallpaper to be set on every monitor
'';
example = ''
./wallpaper.jpg
'';
};
};
};
# TODO expose color scheme / add OLED mode!
# TODO start script
config = mkIf cfg.enable {
home.packages = with pkgs; [
# hyprland
jq
kitty
networkmanagerapplet
mako
libnotify
pavucontrol
hyprpaper
qimgv
playerctl
hyprpicker
wev
inputs.hyprland-contrib.packages.${pkgs.system}.grimblast
bluez
htop
file-roller
zip
unzip
# theme for gtk applications
orchis-theme
(catppuccin-gtk.override {
accents = [ "flamingo" ];
size = "compact";
tweaks = [ "rimless" "black" ];
variant = "macchiato";
})
# desktop apps
vlc
openvpn
signal-desktop
discord-canary
firefox-wayland
google-chrome
thunderbird
gimp
qpdfview
wget
fontforge
gparted
eza
ripgrep
fd
zoom-us
obsidian
zotero
# yubikey
yubico-pam
yubikey-manager
# notes
anki
pandoc
];
services.hyprpaper = mkIf cfg.hyprpaper.enable {
enable = true;
settings = {
preload = [ "${cfg.hyprpaper.wallpaper}" ];
wallpaper = [ ",${cfg.hyprpaper.wallpaper}" ];
};
};
# hyprland setup
wayland.windowManager.hyprland = {
enable = true;
xwayland.enable = true;
settings = {
ecosystem = {
no_donation_nag = true;
};
workspace = cfg.workspace;
monitor = cfg.monitor;
input = {
kb_layout = "de";
kb_variant = "us";
follow_mouse = 1;
};
"$mod" = "SUPER";
"$modd" = "SUPER_SHIFT";
general = {
gaps_in = 8;
gaps_out = 15;
border_size = 3;
resize_on_border = true;
layout = "dwindle";
"col.active_border" = "rgba(cba6f7ff) rgba(89b4faff) rgba(94e2d5ff) 10deg";
"col.inactive_border" = "0xff45475a";
"col.nogroup_border" = "0xff89dceb";
"col.nogroup_border_active" = "0xfff9e2af";
};
decoration = {
blur = {
new_optimizations = true;
size = 1;
passes = 1;
};
shadow = {
enabled = true;
range = 100;
render_power = 5;
color = "0x33000000";
color_inactive = "0x22000000";
};
rounding = 15;
};
animations = {
enabled = 1;
bezier = "overshot,0.13,0.99,0.29,1.1";
animation = [
"windows,1,4,overshot,slide"
"border,1,10,default"
"fade,1,10,default"
"workspaces,1,6,overshot,slidevert"
];
};
misc = {
disable_hyprland_logo = true;
};
bind = [
# opening programs
"$mod, Return, exec, foot"
"$mod, D, exec, tofi-drun | xargs hyprctl dispatch exec --"
"$mod, M, exit, "
"$mod, Q, killactive, "
# moving around
"$mod, left , movefocus, l"
"$mod, right, movefocus, r"
"$mod, down , movefocus, d"
"$mod, up , movefocus, u"
# moving windows
"$modd, left , movewindow, l"
"$modd, right, movewindow, r"
"$modd, down , movewindow, d"
"$modd, up , movewindow, u"
# workspaces
"$mod, 1, workspace, 1"
"$mod, 2, workspace, 2"
"$mod, 3, workspace, 3"
"$mod, 4, workspace, 4"
"$mod, 5, workspace, 5"
"$mod, 6, workspace, 6"
"$modd, 1, movetoworkspacesilent, 1"
"$modd, 2, movetoworkspacesilent, 2"
"$modd, 3, movetoworkspacesilent, 3"
"$modd, 4, movetoworkspacesilent, 4"
"$modd, 5, movetoworkspacesilent, 5"
"$modd, 6, movetoworkspacesilent, 6"
# fullscreen
"$mod, F11, fullscreen, 0"
# "$mod, m, fullscreen, 1" # maximize
# floating
"$mod, F, togglefloating, active"
# screenshot
", Print, exec, grimblast copysave area $HOME\"/screenshots/\"$(date +'%F-%T.png');"
# scratchpad
"$mod, C, togglespecialworkspace, scratchpad"
# status bar
"$mod, T, exec, eww open --toggle top-bar --arg oled=${if cfg.oled then "true" else "false"}"
];
bindm = [
"$mod, mouse:272, movewindow"
];
bindle = [
", XF86AudioRaiseVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 1%+"
", XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 1%-"
", XF86AudioMute, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 0%"
];
exec-once = [
"bash ~/Git/nixos/modules/hyprland/start.sh"
"dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP"
"${if cfg.oled then "" else "eww open --toggle top-bar --arg oled=false"}"
];
};
};
# tell electron to use wayland
home.sessionVariables.NIXOS_OZONE_WL = "1";
# tofi for dmenu functionality
programs.tofi = {
enable = true;
settings = {
width = "100%";
height = "100%";
border-width = 0;
outline-width = 0;
padding-left = "35%";
padding-top = "35%";
result-spacing = 25;
num-results = 5;
font = "monospace";
background-color = "#000A";
};
};
# zsh
programs.zsh = {
enable = true;
shellAliases = {
clean = "sudo nix-env --delete-generations old --profile /nix/var/nix/profiles/system && sudo /nix/var/nix/profiles/system/bin/switch-to-configuration switch && sudo nix-store --gc";
ls = "eza";
ll = "eza -l";
l = "eza -lah";
code = "codium";
};
initExtra = ''
function rebuild () {
sudo nixos-rebuild switch --flake /home/leonv/Git/nixos
sudo cp -r /home/leonv/Git/nixos /etc/
}
'';
oh-my-zsh.enable = true;
};
# terminal
programs.foot = {
enable = true;
settings = {
main = {
font = "monospace:size=12";
dpi-aware = "yes";
};
colors = {
foreground = "cad3f5";
background = "24273a";
regular0 = "494d64";
regular1 = "ed8796";
regular3 = "eed49f";
regular4 = "8aadf4";
regular5 = "f5bde6";
regular6 = "8bd5ca";
regular7 = "b8c0e0";
bright0 = "5b6078";
bright1 = "ed8796";
bright3 = "eed49f";
bright4 = "8aadf4";
bright5 = "f5bde6";
bright6 = "8bd5ca";
bright7 = "a5adcb";
};
};
};
# GTK
gtk = {
enable = true;
theme = {
name = "Catppuccin-Macchiato-Compact-Flamingo-Dark";
package = pkgs.catppuccin-gtk.override {
accents = [ "flamingo" ];
size = "compact";
tweaks = [ "rimless" "black" ];
variant = "macchiato";
};
};
iconTheme = {
name = "Dracula";
package = pkgs.dracula-icon-theme;
};
font = {
name = "NotoSans Nerd Font";
};
gtk3 = {
extraConfig.gtk-application-prefer-dark-theme = true;
};
};
home.sessionVariables.GTK_THEME = "Catppuccin-Macchiato-Compact-Flamingo-Dark";
home.pointerCursor = {
gtk.enable = true;
package = pkgs.bibata-cursors;
name = "Bibata-Modern-Classic";
size = 24;
};
dconf.settings = {
# GTK4 Setup
"org/gnome/desktop/interface" = {
gtk-theme = "Catppuccin-Macchiato-Compact-Flamingo-Dark";
color-scheme = "prefer-dark";
};
};
services.mako = {
enable = true;
extraConfig = ''
background-color=#24273a
text-color=#cad3f5
border-color=#8aadf4
progress-color=over #363a4f
sort=-time
layer=overlay
width=300
height=110
border-size=2
border-radius=15
max-icon-size=64
default-timeout=5000
ignore-timeout=1
[urgency=high]
border-color=#f5a97f
'';
};
};
}

View file

@ -1,25 +1,7 @@
; inspired by https://github.com/saimoomedits/eww-widgets/tree/main
(include "./widgets/workspaces/eww.yuck")
(include "./widgets/window-title/eww.yuck")
(include "./widgets/resources/eww.yuck")
(defwindow top-bar
:monitor 0
:geometry (geometry :x "0%"
:y "10px"
:width "98.8%"
:height "30px"
:anchor "top center")
:stacking "fg"
:exclusive true
(centerbox
:class "bar"
(left)
(center)
(right)
)
)
(include "widgets/workspaces/eww.yuck")
(include "widgets/window-title/eww.yuck")
(include "widgets/resources/eww.yuck")
(defwidget left []
(box
@ -52,3 +34,32 @@
(bluetooth)
(datetime)
))
(defwidget top-bar-oled []
(centerbox
:class "oled"
(left)
(right)
)
)
(defwidget top-bar-non-oled []
(centerbox
:class "non-oled"
(left)
(center)
(right)
)
)
(defwindow top-bar [oled]
:monitor 0
:geometry (geometry :x "0%"
:y "10px"
:width "98.8%"
:height "30px"
:anchor "top center")
:stacking "fg"
:exclusive true
(literal :content {oled ? "(top-bar-oled)" : "(top-bar-non-oled)"})
)

View file

@ -1,5 +1,6 @@
{ pkgs, ... }:
{
# TODO choose oled or non-oled depending on some set variable
programs.eww = {
enable = true;
configDir = ./config;

2
gunther/hypr/start.sh → modules/hyprland/start.sh Executable file → Normal file
View file

@ -2,8 +2,6 @@
# init nmapplet
nm-applet --indicator &
swww init
swww img /home/leonv/Git/nixos/gunther/hypr/wallpaper.jpg
# notification
mako &

@ -1 +1 @@
Subproject commit 578d833ffdd619673b3ed4af21e3701a78c52166
Subproject commit bd0a4cd7f8944ba16d516bd09ab6143ad5e230f3