format code

current_state
Christian Ott 1 year ago
parent 44e64ef028
commit 73e71df821
  1. 86
      configuration.nix
  2. 68
      disko.nix
  3. 29
      flake.nix
  4. 14
      greeter.nix
  5. 33
      hardware-configuration.nix
  6. 33
      home.nix
  7. 106
      hyperland/default.nix
  8. 7
      modules/dunst.nix
  9. 132
      modules/ranger.nix
  10. 1310
      modules/waybar.nix

@ -2,18 +2,27 @@
# your system. Help is available in the configuration.nix(5) man page, on # your system. Help is available in the configuration.nix(5) man page, on
# https://search.nixos.org/options and in the NixOS manual (`nixos-help`). # https://search.nixos.org/options and in the NixOS manual (`nixos-help`).
{ config, lib, pkgs, ronema, xdph, ... }: {
config,
lib,
pkgs,
ronema,
xdph,
...
}:
{ {
imports = imports = [
[ # Include the results of the hardware scan. # Include the results of the hardware scan.
./hardware-configuration.nix ./hardware-configuration.nix
"${builtins.fetchTarball { "${
builtins.fetchTarball {
url = "https://github.com/nix-community/disko/archive/refs/tags/v1.6.1.tar.gz"; url = "https://github.com/nix-community/disko/archive/refs/tags/v1.6.1.tar.gz";
sha256 = "1p9vsml07bm3riw703dv83ihlmgyc11qv882qa6bqzqdgn86y8z4"; sha256 = "1p9vsml07bm3riw703dv83ihlmgyc11qv882qa6bqzqdgn86y8z4";
}}/module.nix" }
./disko.nix }/module.nix"
]; ./disko.nix
];
boot.kernelPackages = pkgs.linuxPackages_latest; boot.kernelPackages = pkgs.linuxPackages_latest;
# Use the systemd-boot EFI boot loader. # Use the systemd-boot EFI boot loader.
@ -28,16 +37,16 @@
}; };
# Pick only one of the below networking options. # Pick only one of the below networking options.
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant. # networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
networking.networkmanager.enable = true; # Easiest to use and most distros use this by default. networking.networkmanager.enable = true; # Easiest to use and most distros use this by default.
networking.networkmanager.plugins = [ pkgs.networkmanager-openvpn ]; networking.networkmanager.plugins = [ pkgs.networkmanager-openvpn ];
networking.networkmanager.dns = "dnsmasq"; networking.networkmanager.dns = "dnsmasq";
environment.etc."NetworkManager/dnsmasq.d/00-cave.conf".text = '' environment.etc."NetworkManager/dnsmasq.d/00-cave.conf".text = ''
server=/.mibex.ch/172.31.13.27 server=/.mibex.ch/172.31.13.27
server=/huus/192.168.15.2 server=/huus/192.168.15.2
server=192.168.15.2 server=192.168.15.2
server=192.168.50.1 server=192.168.50.1
server=1.1.1.1 server=1.1.1.1
''; '';
# Set your time zone. # Set your time zone.
time.timeZone = "Europe/Zurich"; time.timeZone = "Europe/Zurich";
@ -55,16 +64,21 @@
# }; # };
# https://nixos.wiki/wiki/Fonts fonts with icons # https://nixos.wiki/wiki/Fonts fonts with icons
fonts.packages = with pkgs; fonts.packages = with pkgs; [
[ font-awesome
font-awesome (nerdfonts.override {
(nerdfonts.override {fonts = ["JetBrainsMono" "CascadiaCode" "FiraCode"];}) fonts = [
]; "JetBrainsMono"
"CascadiaCode"
"FiraCode"
];
})
];
fonts.fontconfig = { fonts.fontconfig = {
defaultFonts = { defaultFonts = {
monospace = ["CaskaydiaCove Nerd Font Mono"]; monospace = [ "CaskaydiaCove Nerd Font Mono" ];
sansSerif = ["CascadiaCode Nerd Font"]; sansSerif = [ "CascadiaCode Nerd Font" ];
serif = ["CascadiaCode Nerd Font"]; serif = [ "CascadiaCode Nerd Font" ];
}; };
}; };
@ -126,7 +140,11 @@
# Define a user account. Don't forget to set a password with ‘passwd’. # Define a user account. Don't forget to set a password with ‘passwd’.
users.users.chrigi = { users.users.chrigi = {
isNormalUser = true; isNormalUser = true;
extraGroups = [ "wheel" "networkmanager" "docker"]; extraGroups = [
"wheel"
"networkmanager"
"docker"
];
initialPassword = "password"; initialPassword = "password";
packages = with pkgs; [ packages = with pkgs; [
firefox firefox
@ -140,7 +158,7 @@
xdg.portal = { xdg.portal = {
enable = true; enable = true;
extraPortals = [ pkgs.xdg-desktop-portal-wlr ]; extraPortals = [ pkgs.xdg-desktop-portal-wlr ];
configPackages = [ pkgs.xdg-desktop-portal-wlr ]; configPackages = [ pkgs.xdg-desktop-portal-wlr ];
}; };
environment.sessionVariables = { environment.sessionVariables = {
@ -150,7 +168,7 @@
QT_QPA_PLATFORMTHEME = "qt5ct"; QT_QPA_PLATFORMTHEME = "qt5ct";
QT_WAYLAND_DISABLE_WINDOWDECORATION = "1"; QT_WAYLAND_DISABLE_WINDOWDECORATION = "1";
}; };
# List packages installed in system profile. To search, run: # List packages installed in system profile. To search, run:
# $ nix search wget # $ nix search wget
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
@ -176,15 +194,19 @@
}; };
programs._1password-gui = { programs._1password-gui = {
enable = true; enable = true;
polkitPolicyOwners = ["chrigi"]; polkitPolicyOwners = [ "chrigi" ];
}; };
security.polkit.enable = true; security.polkit.enable = true;
services.gnome.gnome-keyring.enable = true; services.gnome.gnome-keyring.enable = true;
security.pam.services.greetd.enableGnomeKeyring = true; security.pam.services.greetd.enableGnomeKeyring = true;
nix.gc = { automatic = true; dates = "weekly"; options = "--delete-older-than 7d"; }; nix.gc = {
automatic = true;
dates = "weekly";
options = "--delete-older-than 7d";
};
# Some programs need SUID wrappers, can be configured further or are # Some programs need SUID wrappers, can be configured further or are
# started in user sessions. # started in user sessions.
# programs.mtr.enable = true; # programs.mtr.enable = true;
@ -226,11 +248,13 @@
# #
# For more information, see `man configuration.nix` or https://nixos.org/manual/nixos/stable/options#opt-system.stateVersion . # For more information, see `man configuration.nix` or https://nixos.org/manual/nixos/stable/options#opt-system.stateVersion .
system.stateVersion = "23.11"; # Did you read the comment? system.stateVersion = "23.11"; # Did you read the comment?
nix = { nix = {
# package = pkgs.nix; # package = pkgs.nix;
settings.experimental-features = ["nix-command" "flakes"]; settings.experimental-features = [
"nix-command"
"flakes"
];
}; };
} }

@ -30,9 +30,17 @@
bypassWorkqueues = true; bypassWorkqueues = true;
keyFile = "/tmp/yk/yk_mini.key"; keyFile = "/tmp/yk/yk_mini.key";
}; };
additionalKeyFiles = [ "/tmp/yk/yk_the_big_one.key" "/tmp/yk/yk_on_key.key" "/tmp/yk/yk_round.key" ]; additionalKeyFiles = [
"/tmp/yk/yk_the_big_one.key"
"/tmp/yk/yk_on_key.key"
"/tmp/yk/yk_round.key"
];
# https://github.com/sgillespie/nixos-yubikey-luks # https://github.com/sgillespie/nixos-yubikey-luks
extraFormatArgs = [ "--cipher=aes-xts-plain64" "--key-size=512" "--hash=sha512" ]; extraFormatArgs = [
"--cipher=aes-xts-plain64"
"--key-size=512"
"--hash=sha512"
];
initrdUnlock = false; # we have to add it manually because of the yubikeys initrdUnlock = false; # we have to add it manually because of the yubikeys
content = { content = {
type = "btrfs"; type = "btrfs";
@ -41,23 +49,48 @@
"/root" = { "/root" = {
mountpoint = "/"; mountpoint = "/";
# https://unix.stackexchange.com/questions/752741/what-is-the-mount-option-space-cache-v2 # https://unix.stackexchange.com/questions/752741/what-is-the-mount-option-space-cache-v2
mountOptions = [ "compress=zstd" "noatime" "space_cache=v2" "commit=120"]; mountOptions = [
"compress=zstd"
"noatime"
"space_cache=v2"
"commit=120"
];
}; };
"/home" = { "/home" = {
mountpoint = "/home"; mountpoint = "/home";
mountOptions = [ "compress=zstd" "noatime" "space_cache=v2" "commit=120"]; mountOptions = [
"compress=zstd"
"noatime"
"space_cache=v2"
"commit=120"
];
}; };
"/nix" = { "/nix" = {
mountpoint = "/nix"; mountpoint = "/nix";
mountOptions = [ "compress=zstd" "noatime" "space_cache=v2" "commit=120"]; mountOptions = [
"compress=zstd"
"noatime"
"space_cache=v2"
"commit=120"
];
}; };
"/var" = { "/var" = {
mountpoint = "/var"; mountpoint = "/var";
mountOptions = [ "compress=zstd" "noatime" "space_cache=v2" "commit=120"]; mountOptions = [
"compress=zstd"
"noatime"
"space_cache=v2"
"commit=120"
];
}; };
"/docker-btrfs" = { "/docker-btrfs" = {
mountpoint = "/var/lib/docker/btrfs"; mountpoint = "/var/lib/docker/btrfs";
mountOptions = [ "compress=zstd" "noatime" "space_cache=v2" "commit=120"]; mountOptions = [
"compress=zstd"
"noatime"
"space_cache=v2"
"commit=120"
];
}; };
}; };
}; };
@ -85,14 +118,22 @@
content = { content = {
type = "luks"; type = "luks";
name = "crypted_backup"; name = "crypted_backup";
settings = { settings = {
allowDiscards = true; allowDiscards = true;
bypassWorkqueues = true; bypassWorkqueues = true;
keyFile = "/tmp/yk/yk_mini.key"; keyFile = "/tmp/yk/yk_mini.key";
}; };
additionalKeyFiles = [ "/tmp/yk/yk_the_big_one.key" "/tmp/yk/yk_on_key.key" "/tmp/yk/yk_round.key" ]; additionalKeyFiles = [
extraFormatArgs = [ "--cipher=aes-xts-plain64" "--key-size=512" "--hash=sha512" ]; "/tmp/yk/yk_the_big_one.key"
"/tmp/yk/yk_on_key.key"
"/tmp/yk/yk_round.key"
];
extraFormatArgs = [
"--cipher=aes-xts-plain64"
"--key-size=512"
"--hash=sha512"
];
initrdUnlock = false; # we have to add it manually because of the yubikeys initrdUnlock = false; # we have to add it manually because of the yubikeys
content = { content = {
type = "btrfs"; type = "btrfs";
@ -100,7 +141,12 @@
subvolumes = { subvolumes = {
"/backup" = { "/backup" = {
mountpoint = "/backup"; mountpoint = "/backup";
mountOptions = [ "compress=zstd" "noatime" "space_cache=v2" "commit=120"]; mountOptions = [
"compress=zstd"
"noatime"
"space_cache=v2"
"commit=120"
];
}; };
}; };
}; };

@ -10,7 +10,7 @@
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
home-manager = { home-manager = {
url = github:nix-community/home-manager; url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
ronema = { ronema = {
@ -19,17 +19,28 @@
}; };
}; };
outputs = { self, nixpkgs, nixos-hardware, home-manager, nix-colors, ronema, xdph, ... }@inputs: outputs =
{
self,
nixpkgs,
nixos-hardware,
home-manager,
nix-colors,
ronema,
xdph,
...
}@inputs:
let let
username = "chrigi"; username = "chrigi";
lib = nixpkgs.lib; lib = nixpkgs.lib;
system = "x86_64-linux"; system = "x86_64-linux";
pkgs = import nixpkgs { pkgs = import nixpkgs {
inherit system; inherit system;
config.allowUnfree = true; config.allowUnfree = true;
}; };
in { in
{
nixosConfigurations.nix-fw16 = lib.nixosSystem { nixosConfigurations.nix-fw16 = lib.nixosSystem {
specialArgs = { specialArgs = {
inherit pkgs ronema xdph; inherit pkgs ronema xdph;
@ -38,14 +49,16 @@
./configuration.nix ./configuration.nix
./greeter.nix ./greeter.nix
nixos-hardware.nixosModules.framework-16-7040-amd nixos-hardware.nixosModules.framework-16-7040-amd
home-manager.nixosModules.home-manager { home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true; home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true; home-manager.useUserPackages = true;
home-manager.users.${username} = import ./home.nix; home-manager.users.${username} = import ./home.nix;
home-manager.extraSpecialArgs = {inherit username nix-colors; }; home-manager.extraSpecialArgs = {
inherit username nix-colors;
};
} }
]; ];
}; };
}; };
} }

@ -1,6 +1,11 @@
{ config, pkgs, lib, ... }: {
config,
pkgs,
lib,
...
}:
let let
tuigreet = "${pkgs.greetd.tuigreet}/bin/tuigreet"; tuigreet = "${pkgs.greetd.tuigreet}/bin/tuigreet";
hyprland-session = "${pkgs.hyprland}/share/wayland-sessions"; hyprland-session = "${pkgs.hyprland}/share/wayland-sessions";
@ -16,7 +21,8 @@ let
terminal = true; terminal = true;
}; };
in { in
{
services.greetd = { services.greetd = {
enable = true; enable = true;
@ -29,4 +35,4 @@ in {
}; };
environment.systemPackages = with pkgs; [ greetd.tuigreet ]; environment.systemPackages = with pkgs; [ greetd.tuigreet ];
} }

@ -1,25 +1,36 @@
# Do not modify this file! It was generated by ‘nixos-generate-config’ # Do not modify this file! It was generated by ‘nixos-generate-config’
# and may be overwritten by future invocations. Please make changes # and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead. # to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }: {
config,
lib,
pkgs,
modulesPath,
...
}:
{ {
disabledModules = ["system/boot/luksroot.nix"]; disabledModules = [ "system/boot/luksroot.nix" ];
imports = imports = [
[ (modulesPath + "/installer/scan/not-detected.nix") (modulesPath + "/installer/scan/not-detected.nix")
./my-luksroot.nix ./my-luksroot.nix
]; ];
boot.initrd = { boot.initrd = {
kernelModules = ["vfat" "nls_cp437" "nls_iso8859-1" "usbhid"]; kernelModules = [
"vfat"
"nls_cp437"
"nls_iso8859-1"
"usbhid"
];
luks = { luks = {
yubikeySupport = true; yubikeySupport = true;
reusePassphrases = true; reusePassphrases = true;
devices."crypted_root" = { devices."crypted_root" = {
device = "/dev/disk/by-partlabel/disk-main-luks"; device = "/dev/disk/by-partlabel/disk-main-luks";
yubikey = { yubikey = {
slot = 2; slot = 2;
twoFactor = true; twoFactor = true;
@ -27,7 +38,7 @@
keyLength = 64; keyLength = 64;
saltLength = 16; saltLength = 16;
replaceKey = false; replaceKey = false;
storage = { storage = {
device = "/dev/disk/by-partlabel/disk-main-ESP"; device = "/dev/disk/by-partlabel/disk-main-ESP";
fsType = "vfat"; fsType = "vfat";
@ -37,7 +48,7 @@
}; };
devices."crypted_backup" = { devices."crypted_backup" = {
device = "/dev/disk/by-partlabel/disk-backup-luks"; device = "/dev/disk/by-partlabel/disk-backup-luks";
yubikey = { yubikey = {
slot = 2; slot = 2;
twoFactor = true; twoFactor = true;

@ -1,7 +1,13 @@
{ config, pkgs, nix-colors, username, ... }: {
config,
pkgs,
nix-colors,
username,
...
}:
{ {
imports = [ imports = [
nix-colors.homeManagerModules.default nix-colors.homeManagerModules.default
./modules/dunst.nix ./modules/dunst.nix
./modules/waybar.nix ./modules/waybar.nix
@ -14,7 +20,6 @@
home.username = "${username}"; home.username = "${username}";
home.homeDirectory = "/home/${username}"; home.homeDirectory = "/home/${username}";
# Packages that should be installed to the user profile. # Packages that should be installed to the user profile.
home.packages = with pkgs; [ home.packages = with pkgs; [
kitty kitty
@ -24,7 +29,7 @@
obsidian obsidian
jq jq
direnv direnv
okular okular
zip zip
@ -42,11 +47,16 @@
nextcloud-client nextcloud-client
font-awesome font-awesome
(nerdfonts.override {fonts = ["JetBrainsMono" "CascadiaCode" "FiraCode"];}) (nerdfonts.override {
fonts = [
"JetBrainsMono"
"CascadiaCode"
"FiraCode"
];
})
]; ];
programs.ssh = { programs.ssh = {
enable = true; enable = true;
extraConfig = '' extraConfig = ''
@ -62,7 +72,13 @@
programs.bash = { programs.bash = {
enable = true; enable = true;
historyIgnore = [ "l" "ls" "ll" "cd" "exit" ]; historyIgnore = [
"l"
"ls"
"ll"
"cd"
"exit"
];
historyControl = [ "erasedups" ]; historyControl = [ "erasedups" ];
shellAliases = { shellAliases = {
grep = "grep --color=auto"; grep = "grep --color=auto";
@ -81,7 +97,6 @@
''; '';
}; };
programs.starship = { programs.starship = {
enable = true; enable = true;
enableBashIntegration = true; enableBashIntegration = true;
@ -99,4 +114,4 @@
# Let home Manager install and manage itself. # Let home Manager install and manage itself.
# programs.home-manager.enable = true; # programs.home-manager.enable = true;
} }

@ -1,4 +1,9 @@
{ config, pkgs, username, ... }: {
config,
pkgs,
username,
...
}:
let let
volumeChange = pkgs.writeShellScript "volume-change" '' volumeChange = pkgs.writeShellScript "volume-change" ''
# FROM: https://github.com/jsimonrichard/nix-config/blob/master/modules/my-config/desktop/hyprland/home-manager/desktop/hyprland/keybinds.nix # FROM: https://github.com/jsimonrichard/nix-config/blob/master/modules/my-config/desktop/hyprland/home-manager/desktop/hyprland/keybinds.nix
@ -36,7 +41,7 @@ in
# (pkgs.waybar.overrideAttrs (oldAttrs: { # (pkgs.waybar.overrideAttrs (oldAttrs: {
# mesonFlags = oldAttrs.mesonFlags ++ [ "-Dexperimental=true" ]; # mesonFlags = oldAttrs.mesonFlags ++ [ "-Dexperimental=true" ];
# })) # }))
]; ];
services.hyprpaper = { services.hyprpaper = {
enable = true; enable = true;
@ -51,7 +56,7 @@ in
}; };
}; };
programs.hyprlock = { programs.hyprlock = {
enable = true; enable = true;
settings = { settings = {
background = { background = {
@ -62,7 +67,7 @@ in
blur_passes = 1; blur_passes = 1;
blur_size = 7; blur_size = 7;
noise = 0.0117; noise = 1.17e-2;
contrast = 0.8916; contrast = 0.8916;
brightness = 0.8172; brightness = 0.8172;
vibrancy = 0.1696; vibrancy = 0.1696;
@ -112,7 +117,7 @@ in
shadow_size = 10; shadow_size = 10;
} }
{ {
monitor = ""; monitor = "";
text = "$USER"; text = "$USER";
color = "rgba(200, 200, 200, 1.0)"; color = "rgba(200, 200, 200, 1.0)";
@ -177,10 +182,10 @@ in
wayland.windowManager.hyprland.enable = true; wayland.windowManager.hyprland.enable = true;
wayland.windowManager.hyprland.settings = { wayland.windowManager.hyprland.settings = {
monitor=[ monitor = [
"eDP-1,2560x1600@60.00Hz,0x0,1" "eDP-1,2560x1600@60.00Hz,0x0,1"
"DP-3,preferred,-3840x-560,1" "DP-3,preferred,-3840x-560,1"
"DP-2,preferred,auto,1.5" "DP-2,preferred,auto,1.5"
]; ];
"$mod" = "SUPER"; "$mod" = "SUPER";
@ -204,7 +209,6 @@ in
"$mod, mouse:273, resizewindow" "$mod, mouse:273, resizewindow"
]; ];
bind = bind =
[ [
"$mod, F, exec, firefox" "$mod, F, exec, firefox"
@ -222,52 +226,56 @@ in
++ ( ++ (
# workspaces # workspaces
# binds $mod + [shift +] {1..10} to [move to] workspace {1..10} # binds $mod + [shift +] {1..10} to [move to] workspace {1..10}
builtins.concatLists (builtins.genList ( builtins.concatLists (
x: let builtins.genList (
ws = let x:
c = (x + 1) / 10; let
in ws =
let
c = (x + 1) / 10;
in
builtins.toString (x + 1 - (c * 10)); builtins.toString (x + 1 - (c * 10));
in [ in
[
"$mod, ${ws}, workspace, ${toString (x + 1)}" "$mod, ${ws}, workspace, ${toString (x + 1)}"
"$mod SHIFT, ${ws}, movetoworkspace, ${toString (x + 1)}" "$mod SHIFT, ${ws}, movetoworkspace, ${toString (x + 1)}"
] ]
) ) 10
10) )
); );
windowrulev2= [ windowrulev2 = [
# https://jbmorley.co.uk/posts/2024-02-13-1password-and-hyprland/ # https://jbmorley.co.uk/posts/2024-02-13-1password-and-hyprland/
"float, title:(1Password)" "float, title:(1Password)"
"size 70% 70%, title:(1Password)" "size 70% 70%, title:(1Password)"
"center, title:(1Password)" "center, title:(1Password)"
"float,class:(.blueman-manager-wrapped)" "float,class:(.blueman-manager-wrapped)"
"size 25% 25%,class:(.blueman-manager-wrapped)" "size 25% 25%,class:(.blueman-manager-wrapped)"
"float,class:(org.kde.polkit-kde-authentication-agent-1)" "float,class:(org.kde.polkit-kde-authentication-agent-1)"
"opacity 0.80 0.70,class:^(org.kde.polkit-kde-authentication-agent-1)$" "opacity 0.80 0.70,class:^(org.kde.polkit-kde-authentication-agent-1)$"
"bordercolor rgba(ed8796FF), class:org.kde.polkit-kde-authentication-agent-1" "bordercolor rgba(ed8796FF), class:org.kde.polkit-kde-authentication-agent-1"
"dimaround, class:org.kde.polkit-kde-authentication-agent-1" "dimaround, class:org.kde.polkit-kde-authentication-agent-1"
"stayfocused, class:org.kde.polkit-kde-authentication-agent-1" "stayfocused, class:org.kde.polkit-kde-authentication-agent-1"
]; ];
# Bind flags # Bind flags
# l -> locked, will also work when an input inhibitor (e.g. a lockscreen) is active. # l -> locked, will also work when an input inhibitor (e.g. a lockscreen) is active.
# r -> release, will trigger on release of a key. # r -> release, will trigger on release of a key.
# e -> repeat, will repeat when held. # e -> repeat, will repeat when held.
# n -> non-consuming, key/mouse events will be passed to the active window in addition to triggering the dispatcher. # n -> non-consuming, key/mouse events will be passed to the active window in addition to triggering the dispatcher.
# m -> mouse, see below # m -> mouse, see below
# t -> transparent, cannot be shadowed by other binds. # t -> transparent, cannot be shadowed by other binds.
# i -> ignore mods, will ignore modifiers. # i -> ignore mods, will ignore modifiers.
binde = [ binde = [
", XF86AudioRaiseVolume, exec, ${volumeChange} set-volume @DEFAULT_AUDIO_SINK@ 5%+ --limit 1.3" ", XF86AudioRaiseVolume, exec, ${volumeChange} set-volume @DEFAULT_AUDIO_SINK@ 5%+ --limit 1.3"
"CTRL, XF86AudioRaiseVolume, exec, ${volumeChange} set-volume @DEFAULT_AUDIO_SOURCE@ 5%+ --limit 1" "CTRL, XF86AudioRaiseVolume, exec, ${volumeChange} set-volume @DEFAULT_AUDIO_SOURCE@ 5%+ --limit 1"
]; ];
bindle = [ bindle = [
", XF86AudioLowerVolume, exec, ${volumeChange} set-volume @DEFAULT_AUDIO_SINK@ 5%-" ", XF86AudioLowerVolume, exec, ${volumeChange} set-volume @DEFAULT_AUDIO_SINK@ 5%-"
"CTRL, XF86AudioLowerVolume, exec, ${volumeChange} set-volume @DEFAULT_AUDIO_SOURCE@ 5%-" "CTRL, XF86AudioLowerVolume, exec, ${volumeChange} set-volume @DEFAULT_AUDIO_SOURCE@ 5%-"
]; ];
bindl = [ bindl = [
", XF86AudioMute, exec, ${volumeChange} set-mute @DEFAULT_AUDIO_SINK@ toggle" ", XF86AudioMute, exec, ${volumeChange} set-mute @DEFAULT_AUDIO_SINK@ toggle"
]; ];
}; };
} }

@ -2,7 +2,8 @@
inputs, inputs,
config, config,
... ...
}:{ }:
{
services.dunst = { services.dunst = {
enable = true; enable = true;
settings = { settings = {
@ -54,7 +55,7 @@
title = "Dunst"; title = "Dunst";
class = "Dunst"; class = "Dunst";
corner_radius = 10; corner_radius = 10;
icon_corner_radius= 5; icon_corner_radius = 5;
notification_limit = 5; notification_limit = 5;
mouse_left_click = "close_current"; mouse_left_click = "close_current";
mouse_middle_click = "do_action"; mouse_middle_click = "do_action";
@ -97,4 +98,4 @@
}; };
}; };
}; };
} }

@ -1,70 +1,72 @@
{pkgs, ...}: { pkgs, ... }:
{ {
# stolen from: https://github.com/leoperegrino/.files/blob/d996b31a0b1843f05d0f27123196bfa6d0980caa/home-manager/modules/ranger.nix # stolen from: https://github.com/leoperegrino/.files/blob/d996b31a0b1843f05d0f27123196bfa6d0980caa/home-manager/modules/ranger.nix
programs.ranger = { programs.ranger = {
enable = true; enable = true;
extraPackages = [ extraPackages = [
pkgs.ueberzugpp pkgs.ueberzugpp
]; ];
extraConfig = "default_linemode devicons"; extraConfig = "default_linemode devicons";
plugins = [{ plugins = [
name = "devicons"; {
src = builtins.fetchGit { name = "devicons";
url = "https://github.com/alexanderjeurissen/ranger_devicons.git"; src = builtins.fetchGit {
rev = "a8d626485ca83719e1d8d5e32289cd96a097c861"; url = "https://github.com/alexanderjeurissen/ranger_devicons.git";
}; rev = "a8d626485ca83719e1d8d5e32289cd96a097c861";
}]; };
settings = { }
preview_images_method = "ueberzug"; ];
show_hidden = true; settings = {
use_preview_script = true; preview_images_method = "ueberzug";
preview_images = true; show_hidden = true;
preview_files = true; use_preview_script = true;
open_all_images = true; preview_images = true;
draw_borders = true; preview_files = true;
hidden_filter = ''^\.|\.(bak|swp)$|^lost\+found$|^__pycache__$''; open_all_images = true;
nested_ranger_warning = true; draw_borders = true;
colorscheme = "jungle"; hidden_filter = ''^\.|\.(bak|swp)$|^lost\+found$|^__pycache__$'';
}; nested_ranger_warning = true;
# mappings = { colorscheme = "jungle";
# "gu" = "cd ~/.local/share"; };
# "gs" = "cd ~/.local/state"; # mappings = {
# "gf" = "cd ~/.files"; # "gu" = "cd ~/.local/share";
# "gV" = "cd ~/.files/nvim/lua/user/"; # "gs" = "cd ~/.local/state";
# "gc" = "cd ~/.config"; # "gf" = "cd ~/.files";
# "gC" = "cd ~/.cache"; # "gV" = "cd ~/.files/nvim/lua/user/";
# "gb" = "cd ~/bin"; # "gc" = "cd ~/.config";
# "gD" = "cd ~/desktop"; # "gC" = "cd ~/.cache";
# "gd" = "cd ~/documents"; # "gb" = "cd ~/bin";
# "gm" = "cd ~/music"; # "gD" = "cd ~/desktop";
# "gp" = "cd ~/pictures"; # "gd" = "cd ~/documents";
# "gv" = "cd ~/videos"; # "gm" = "cd ~/music";
# "gU" = "cd /usr/share/"; # "gp" = "cd ~/pictures";
# "gr" = "cd /"; # "gv" = "cd ~/videos";
# "gt" = "cd /tmp"; # "gU" = "cd /usr/share/";
# "g/r" = "shell sudo ranger ."; # "gr" = "cd /";
# "gt" = "cd /tmp";
# "g/r" = "shell sudo ranger .";
# "ev" = ''shell "''${EDITOR}" -- %s''; # "ev" = ''shell "''${EDITOR}" -- %s'';
# "eV" = ''console shell "''${EDITOR}" --%space''; # "eV" = ''console shell "''${EDITOR}" --%space'';
# "et" = ''shell "''${EDITOR}" -p -- %s''; # "et" = ''shell "''${EDITOR}" -p -- %s'';
# "eT" = ''console shell "''${EDITOR}" -p -- %s%space''; # "eT" = ''console shell "''${EDITOR}" -p -- %s%space'';
# "es" = ''shell "''${EDITOR}" -O -- %s''; # "es" = ''shell "''${EDITOR}" -O -- %s'';
# "eS" = ''console shell "''${EDITOR}" -O -- %s%space''; # "eS" = ''console shell "''${EDITOR}" -O -- %s%space'';
# "EV" = ''shell sudo "''${EDITOR}" -- %s''; # "EV" = ''shell sudo "''${EDITOR}" -- %s'';
# "V" = ''shell setsid -f alacritty -e zsh -ic "''${EDITOR} -- %s"''; # "V" = ''shell setsid -f alacritty -e zsh -ic "''${EDITOR} -- %s"'';
# "B" = ''shell setsid -f alacritty -e zsh -ic "''${PAGER} -- %s"''; # "B" = ''shell setsid -f alacritty -e zsh -ic "''${PAGER} -- %s"'';
# "<c-o>" = "console touch%space"; # "<c-o>" = "console touch%space";
# "CC" = "get_cumulative_size"; # "CC" = "get_cumulative_size";
# "md" = "console mkdir%space"; # "md" = "console mkdir%space";
# "cW" = "bulkrename"; # "cW" = "bulkrename";
# "i" = ''shell "''${PAGER}" -- %f''; # "i" = ''shell "''${PAGER}" -- %f'';
# "v" = "mark_files all=True toggle=True"; # "v" = "mark_files all=True toggle=True";
# "n" = "tab_new"; # "n" = "tab_new";
# "b" = ''shell setsid -f "''${TERM}"''; # "b" = ''shell setsid -f "''${TERM}"'';
# "f" = "console scout -ftse%space"; # "f" = "console scout -ftse%space";
# "<c-j>" = "scroll_preview 1"; # "<c-j>" = "scroll_preview 1";
# "<c-k>" = "scroll_preview -1"; # "<c-k>" = "scroll_preview -1";
# }; # };
}; };
} }

File diff suppressed because it is too large Load Diff
Loading…
Cancel
Save

Powered by TurnKey Linux.