feat: format

This commit is contained in:
s-prechtl 2024-09-15 11:57:16 +02:00
parent 95f31e1d7a
commit 0844945c23
15 changed files with 1111 additions and 1080 deletions

View file

@ -10,7 +10,12 @@
}; };
}; };
outputs = { self, nixpkgs, ... }@inputs: { outputs = {
self,
nixpkgs,
...
} @ inputs: {
formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.alejandra;
nixosConfigurations.default = nixpkgs.lib.nixosSystem { nixosConfigurations.default = nixpkgs.lib.nixosSystem {
specialArgs = {inherit inputs;}; specialArgs = {inherit inputs;};
modules = [ modules = [

View file

@ -1,16 +1,17 @@
# Edit this configuration file to define what should be installed on # Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page # your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help). # and in the NixOS manual (accessible by running nixos-help).
{ config, pkgs, inputs, ... }:
{ {
imports = config,
[ pkgs,
../../modules/nixos/main-user.nix inputs,
./hardware-configuration.nix ...
inputs.home-manager.nixosModules.default }: {
]; imports = [
../../modules/nixos/main-user.nix
./hardware-configuration.nix
inputs.home-manager.nixosModules.default
];
# Bootloader. # Bootloader.
boot.loader.systemd-boot.enable = true; boot.loader.systemd-boot.enable = true;
@ -52,7 +53,7 @@
services.xserver.desktopManager.gnome.enable = true; services.xserver.desktopManager.gnome.enable = true;
services.pcscd.enable = true; services.pcscd.enable = true;
services.dbus.packages = [ pkgs.gcr ]; services.dbus.packages = [pkgs.gcr];
# Configure keymap in X11 # Configure keymap in X11
services.xserver.xkb = { services.xserver.xkb = {
@ -82,29 +83,28 @@
# Enable touchpad support (enabled default in most desktopManager). # Enable touchpad support (enabled default in most desktopManager).
# services.xserver.libinput.enable = true; # services.xserver.libinput.enable = true;
nix.settings.experimental-features = [ "nix-command" "flakes" ]; nix.settings.experimental-features = ["nix-command" "flakes"];
# 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.
main-user = { main-user = {
enable = true; enable = true;
username = "sprechtl"; username = "sprechtl";
}; };
home-manager = { home-manager = {
extraSpecialArgs = { inherit inputs; }; extraSpecialArgs = {inherit inputs;};
users = { users = {
"sprechtl" = import ./home.nix; "sprechtl" = import ./home.nix;
}; };
}; };
# Allow unfree packages # Allow unfree packages
nixpkgs.config.allowUnfree = true; nixpkgs.config.allowUnfree = true;
# 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; [
vim vim
wget wget
usbutils usbutils
alacritty alacritty
@ -136,7 +136,7 @@
wdisplays wdisplays
]; ];
programs = { programs = {
neovim = { neovim = {
enable = true; enable = true;
defaultEditor = true; defaultEditor = true;
@ -146,9 +146,9 @@
firefox.enable = true; firefox.enable = true;
hyprland.enable = true; hyprland.enable = true;
gnupg.agent = { gnupg.agent = {
enable = true; enable = true;
enableSSHSupport = true; enableSSHSupport = true;
pinentryPackage = pkgs.pinentry-qt; pinentryPackage = pkgs.pinentry-qt;
}; };
}; };
@ -160,7 +160,6 @@
# enableSSHSupport = true; # enableSSHSupport = true;
# }; # };
services.fprintd.enable = true; services.fprintd.enable = true;
# List services that you want to enable: # List services that you want to enable:
@ -182,5 +181,4 @@
# Before changing this value read the documentation for this option # Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "24.05"; # Did you read the comment? system.stateVersion = "24.05"; # Did you read the comment?
} }

View file

@ -1,32 +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, ... }:
{ {
imports = config,
[ (modulesPath + "/installer/scan/not-detected.nix") lib,
]; pkgs,
modulesPath,
...
}: {
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "thunderbolt" "usbhid" "usb_storage" "sd_mod" ]; boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "thunderbolt" "usbhid" "usb_storage" "sd_mod"];
boot.initrd.kernelModules = [ ]; boot.initrd.kernelModules = [];
boot.kernelModules = [ "kvm-amd" ]; boot.kernelModules = ["kvm-amd"];
boot.extraModulePackages = [ ]; boot.extraModulePackages = [];
fileSystems."/" = fileSystems."/" = {
{ device = "/dev/disk/by-uuid/ed1afa26-1c26-4da6-a4b4-b5cb6e0b2222"; device = "/dev/disk/by-uuid/ed1afa26-1c26-4da6-a4b4-b5cb6e0b2222";
fsType = "ext4"; fsType = "ext4";
}; };
fileSystems."/boot" = fileSystems."/boot" = {
{ device = "/dev/disk/by-uuid/1FDC-CD90"; device = "/dev/disk/by-uuid/1FDC-CD90";
fsType = "vfat"; fsType = "vfat";
options = [ "fmask=0077" "dmask=0077" ]; options = ["fmask=0077" "dmask=0077"];
}; };
swapDevices = swapDevices = [
[ { device = "/dev/disk/by-uuid/cee4a6a9-f044-4258-9d4b-35c67cc59e2c"; } {device = "/dev/disk/by-uuid/cee4a6a9-f044-4258-9d4b-35c67cc59e2c";}
]; ];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking # 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 # (the default) this is the recommended approach. When using systemd-networkd it's

View file

@ -1,17 +1,19 @@
{ config, pkgs, ... }:
{ {
config,
pkgs,
...
}: {
imports = [ imports = [
../../modules/home-manager/hyprland.nix ../../modules/home-manager/hyprland.nix
../../modules/home-manager/pass.nix ../../modules/home-manager/pass.nix
../../modules/home-manager/btop.nix ../../modules/home-manager/btop.nix
../../modules/home-manager/git.nix ../../modules/home-manager/git.nix
../../modules/home-manager/wofi.nix ../../modules/home-manager/wofi.nix
../../modules/home-manager/waybar.nix ../../modules/home-manager/waybar.nix
../../modules/home-manager/alacritty.nix ../../modules/home-manager/alacritty.nix
../../modules/home-manager/nextcloud.nix ../../modules/home-manager/nextcloud.nix
../../modules/home-manager/zsh.nix ../../modules/home-manager/zsh.nix
]; ];
home.username = "sprechtl"; home.username = "sprechtl";
home.homeDirectory = "/home/sprechtl"; home.homeDirectory = "/home/sprechtl";
@ -36,7 +38,6 @@
# '') # '')
]; ];
# Home Manager is pretty good at managing dotfiles. The primary way to manage # Home Manager is pretty good at managing dotfiles. The primary way to manage
# plain files is through 'home.file'. # plain files is through 'home.file'.
home.file = { home.file = {

View file

@ -1,42 +1,44 @@
{ config, pkgs, ... }:
{ {
programs.alacritty = { config,
enable = true; pkgs,
settings = { ...
colors = { }: {
bright = { programs.alacritty = {
black = "#928374"; enable = true;
blue = "#83a598"; settings = {
cyan = "#8ec07c"; colors = {
green = "#b8bb26"; bright = {
magenta = "#d3869b"; black = "#928374";
red = "#fb4934"; blue = "#83a598";
white = "#ebdbb2"; cyan = "#8ec07c";
yellow = "#fabd2f"; green = "#b8bb26";
}; magenta = "#d3869b";
normal = { red = "#fb4934";
black = "#282828"; white = "#ebdbb2";
blue = "#458588"; yellow = "#fabd2f";
cyan = "#689d6a"; };
green = "#98971a"; normal = {
magenta = "#b16286"; black = "#282828";
red = "#cc241d"; blue = "#458588";
white = "#a89984"; cyan = "#689d6a";
yellow = "#d79921"; green = "#98971a";
}; magenta = "#b16286";
primary = { red = "#cc241d";
background = "#282828"; white = "#a89984";
foreground = "#ebdbb2"; yellow = "#d79921";
}; };
}; primary = {
env = { background = "#282828";
TERM = "xterm-256color"; foreground = "#ebdbb2";
}; };
font = { };
size = 12.0; env = {
normal.family = "JetBrainsMono Nerd Font Mono"; TERM = "xterm-256color";
}; };
}; font = {
}; size = 12.0;
normal.family = "JetBrainsMono Nerd Font Mono";
};
};
};
} }

View file

@ -1,11 +1,13 @@
{ config, pkgs, ... }:
{ {
programs.btop = { config,
enable = true; pkgs,
settings = { ...
color_theme = "gruvbox_dark_v2"; }: {
vim_keys = true; programs.btop = {
}; enable = true;
}; settings = {
color_theme = "gruvbox_dark_v2";
vim_keys = true;
};
};
} }

View file

@ -1,14 +1,16 @@
{ config, pkgs, ... }:
{ {
programs.git = { config,
enable = true; pkgs,
delta.enable = true; ...
userEmail = "stefan@tague.at"; }: {
userName = "s-prechtl"; programs.git = {
extraConfig = { enable = true;
init.defaultBranch = "master"; delta.enable = true;
push.autoSetupRemote = true; userEmail = "stefan@tague.at";
}; userName = "s-prechtl";
}; extraConfig = {
init.defaultBranch = "master";
push.autoSetupRemote = true;
};
};
} }

View file

@ -1,156 +1,159 @@
{ config, pkgs, ... }:
{ {
config,
pkgs,
...
}: {
imports = [ imports = [
./hyprlock.nix ./hyprlock.nix
]; ];
wayland.windowManager.hyprland = { wayland.windowManager.hyprland = {
enable = true; enable = true;
xwayland.enable = true; xwayland.enable = true;
systemd.enable = true; systemd.enable = true;
settings = { settings = {
# BINDS # BINDS
"$mod" = "SUPER"; "$mod" = "SUPER";
bind = [ bind =
"SUPERSHIFT, E, exit" [
"$mod, Q, killactive" "SUPERSHIFT, E, exit"
"$mod, B, exec, brave" "$mod, Q, killactive"
"$mod, return, exec, alacritty" "$mod, B, exec, brave"
"$mod,E,exec,nautilus" "$mod, return, exec, alacritty"
"$mod,D,exec,killall -q wofi; wofi --show drun -I" "$mod,E,exec,nautilus"
"SUPERSHIFT,R,exec,hyprctl reload" "$mod,D,exec,killall -q wofi; wofi --show drun -I"
"$mod,space,togglefloating," "SUPERSHIFT,R,exec,hyprctl reload"
"ALTSHIFT, L, exec, swaylock" "$mod,space,togglefloating,"
"$mod,F,fullscreen" "ALTSHIFT, L, exec, swaylock"
"ALTSHIFT,K,exec,amixer set 'Master' 5%+" "$mod,F,fullscreen"
"ALTSHIFT,J,exec,amixer set 'Master' 5%-" "ALTSHIFT,K,exec,amixer set 'Master' 5%+"
"SUPERSHIFT,N,exec, swaync-client -t -sw" "ALTSHIFT,J,exec,amixer set 'Master' 5%-"
"$mod, M, exec,hyprctl keyword monitor 'eDP-1, enable'" "SUPERSHIFT,N,exec, swaync-client -t -sw"
"SUPERSHIFT, M, exec,hyprctl keyword monitor 'eDP-1, disable'" "$mod, M, exec,hyprctl keyword monitor 'eDP-1, enable'"
"SUPERSHIFT,P,exec,hyprshot -m region -o ~/Screenshot/" "SUPERSHIFT, M, exec,hyprctl keyword monitor 'eDP-1, disable'"
"SUPERALTSHIFT, P, exec, hyprshot -m window -o ~/Screenshot/" "SUPERSHIFT,P,exec,hyprshot -m region -o ~/Screenshot/"
"SUPERALTSHIFT, P, exec, hyprshot -m window -o ~/Screenshot/"
"$mod,left,movefocus,l" "$mod,left,movefocus,l"
"$mod, H,movefocus,l" "$mod, H,movefocus,l"
"SUPERALT, left, movewindow, l" "SUPERALT, left, movewindow, l"
"SUPERALT, H, movewindow, l" "SUPERALT, H, movewindow, l"
"$mod,right,movefocus,r" "$mod,right,movefocus,r"
"$mod, L,movefocus,r" "$mod, L,movefocus,r"
"SUPERALT, right, movewindow, r" "SUPERALT, right, movewindow, r"
"SUPERALT, L, movewindow, r" "SUPERALT, L, movewindow, r"
"$mod,up,movefocus,u" "$mod,up,movefocus,u"
"$mod, K,movefocus,u" "$mod, K,movefocus,u"
"SUPERALT, up, movewindow, u" "SUPERALT, up, movewindow, u"
"SUPERALT, K, movewindow, u" "SUPERALT, K, movewindow, u"
"$mod,down,movefocus,d" "$mod,down,movefocus,d"
"$mod, J,movefocus,d" "$mod, J,movefocus,d"
"SUPERALT, down, movewindow, d" "SUPERALT, down, movewindow, d"
"SUPERALT, J, movewindow, d" "SUPERALT, J, movewindow, d"
] ]
++ ( ++ (
# workspaces # workspaces
# binds $mod + [shift +] {1..9} to [move to] workspace {1..9} # binds $mod + [shift +] {1..9} to [move to] workspace {1..9}
builtins.concatLists (builtins.genList (i: builtins.concatLists (builtins.genList (
let ws = i + 1; i: let
in [ ws = i + 1;
"$mod, code:1${toString i}, workspace, ${toString ws}" in [
"$mod SHIFT, code:1${toString i}, movetoworkspace, ${toString ws}" "$mod, code:1${toString i}, workspace, ${toString ws}"
] "$mod SHIFT, code:1${toString i}, movetoworkspace, ${toString ws}"
) ]
9) )
); 9)
);
bindm = [ bindm = [
"$mod, mouse:272,movewindow" "$mod, mouse:272,movewindow"
"$mod, mouse:273,resizewindow" "$mod, mouse:273,resizewindow"
]; ];
binde = [ binde = [
",XF86MonBrightnessDown,exec,brightnessctl --device=intel_backlight s 5%-" ",XF86MonBrightnessDown,exec,brightnessctl --device=intel_backlight s 5%-"
",XF86MonBrightnessUp,exec,brightnessctl --device=intel_backlight s 5%+" ",XF86MonBrightnessUp,exec,brightnessctl --device=intel_backlight s 5%+"
"SUPERSHIFT,right,resizeactive, 10 0" "SUPERSHIFT,right,resizeactive, 10 0"
"SUPERSHIFT,L,resizeactive, 10 0" "SUPERSHIFT,L,resizeactive, 10 0"
"SUPERSHIFT,down,resizeactive, 0 10" "SUPERSHIFT,down,resizeactive, 0 10"
"SUPERSHIFT,J,resizeactive, 0 10" "SUPERSHIFT,J,resizeactive, 0 10"
"SUPERSHIFT,left,resizeactive, -10 0" "SUPERSHIFT,left,resizeactive, -10 0"
"SUPERSHIFT,H,resizeactive, -10 0" "SUPERSHIFT,H,resizeactive, -10 0"
"SUPERSHIFT,up,resizeactive, 0 -10" "SUPERSHIFT,up,resizeactive, 0 -10"
"SUPERSHIFT,K,resizeactive, 0 -10" "SUPERSHIFT,K,resizeactive, 0 -10"
]; ];
# MONITOR # MONITOR
monitor = [ monitor = [
"eDP-1,2560x1600@165.0,0x0,2" "eDP-1,2560x1600@165.0,0x0,2"
]; ];
# INPUT # INPUT
input = { input = {
kb_layout="us"; kb_layout = "us";
kb_options="compose:ralt,caps:escape"; kb_options = "compose:ralt,caps:escape";
follow_mouse=2; follow_mouse = 2;
touchpad = { touchpad = {
natural_scroll="yes"; natural_scroll = "yes";
}; };
sensitivity=0.0; # -1.0 - 1.0, 0 means no modification. sensitivity = 0.0; # -1.0 - 1.0, 0 means no modification.
}; };
# GENERAL # GENERAL
general = { general = {
gaps_in=10; gaps_in = 10;
gaps_out=20; gaps_out = 20;
border_size=2; border_size = 2;
"col.active_border"="0xffBF616A"; "col.active_border" = "0xffBF616A";
"col.inactive_border"="0xffebdbb2"; "col.inactive_border" = "0xffebdbb2";
}; };
# CURSOR # CURSOR
cursor = { cursor = {
no_warps=true; no_warps = true;
inactive_timeout=3; inactive_timeout = 3;
}; };
# DECORATION # DECORATION
decoration = { decoration = {
active_opacity=0.95; active_opacity = 0.95;
inactive_opacity=0.95; inactive_opacity = 0.95;
rounding=10; rounding = 10;
}; };
# ANIMATION # ANIMATION
animations = { animations = {
enabled=1; enabled = 1;
bezier="overshot,0.13,0.99,0.29,1.1"; bezier = "overshot,0.13,0.99,0.29,1.1";
animation = [ animation = [
"windows,1,4,overshot,slide" "windows,1,4,overshot,slide"
"border,1,10,default" "border,1,10,default"
"fade,1,10,default" "fade,1,10,default"
"workspaces,1,6,overshot,slide" "workspaces,1,6,overshot,slide"
]; ];
}; };
# EXEC ONCE # EXEC ONCE
exec-once = [ exec-once = [
"waybar" "waybar"
"nm-applet" "nm-applet"
"swaync" "swaync"
"whatpulse" "whatpulse"
]; ];
# WINDOW RULES
# WINDOW RULES windowrule = [
windowrule = [ "move 400 400, float, title:(jetbrains toolbox)"
"move 400 400, float, title:(jetbrains toolbox)" "float,wofi"
"float,wofi" "opacity 1 override,title:^(.*)(Brave)(.*)$"
"opacity 1 override,title:^(.*)(Brave)(.*)$" ];
]; };
}; };
};
# Optional, hint Electron apps to use Wayland: # Optional, hint Electron apps to use Wayland:
home.sessionVariables = { home.sessionVariables = {
NIXOS_OZONE_WL = "1"; NIXOS_OZONE_WL = "1";
}; };
} }

View file

@ -1,39 +1,41 @@
{ config, pkgs, ... }:
{ {
programs.hyprlock = { config,
enable = true; pkgs,
settings = { ...
general = { }: {
disable_loading_bar = true; programs.hyprlock = {
grace = 300; enable = true;
hide_cursor = true; settings = {
no_fade_in = false; general = {
}; disable_loading_bar = true;
grace = 300;
hide_cursor = true;
no_fade_in = false;
};
background = [ background = [
{ {
path = "screenshot"; path = "screenshot";
blur_passes = 3; blur_passes = 3;
blur_size = 8; blur_size = 8;
} }
]; ];
input-field = [ input-field = [
{ {
size = "200, 50"; size = "200, 50";
position = "0, -80"; position = "0, -80";
monitor = ""; monitor = "";
dots_center = true; dots_center = true;
fade_on_empty = false; fade_on_empty = false;
font_color = "rgb(202, 211, 245)"; font_color = "rgb(202, 211, 245)";
inner_color = "rgb(91, 96, 120)"; inner_color = "rgb(91, 96, 120)";
outer_color = "rgb(24, 25, 38)"; outer_color = "rgb(24, 25, 38)";
outline_thickness = 5; outline_thickness = 5;
placeholder_text = "<span foreground='##cad3f5'>Password...</span>"; placeholder_text = "<span foreground='##cad3f5'>Password...</span>";
shadow_passes = 2; shadow_passes = 2;
} }
]; ];
}; };
}; };
} }

View file

@ -1,8 +1,10 @@
{ config, pkgs, ... }:
{ {
services.nextcloud-client = { config,
enable = true; pkgs,
startInBackground = true; ...
}; }: {
services.nextcloud-client = {
enable = true;
startInBackground = true;
};
} }

View file

@ -1,12 +1,14 @@
{ config, pkgs, ... }:
{ {
programs.password-store = { config,
pkgs,
...
}: {
programs.password-store = {
enable = true; enable = true;
settings = { settings = {
PASSWORD_STORE_DIR="$HOME/.password-store"; PASSWORD_STORE_DIR = "$HOME/.password-store";
PASSWORD_STORE_GENERATED_LENGTH = "20"; PASSWORD_STORE_GENERATED_LENGTH = "20";
PASSWORD_STORE_ENABLE_EXTENSIONS = "true"; PASSWORD_STORE_ENABLE_EXTENSIONS = "true";
}; };
}; };
programs.browserpass.enable = true; programs.browserpass.enable = true;

File diff suppressed because it is too large Load diff

View file

@ -1,68 +1,70 @@
{ config, pkgs, ... }:
{ {
programs.wofi = { config,
enable = true; pkgs,
settings = { ...
allow-images=true; }: {
image-size="64px"; programs.wofi = {
gtk_dark=true; enable = true;
insensitive=true; settings = {
halign=true; allow-images = true;
location="center"; image-size = "64px";
prompt="Search..."; gtk_dark = true;
orientation="vertical"; insensitive = true;
}; halign = true;
style = '' location = "center";
@define-color base00 #282828; prompt = "Search...";
@define-color base01 #3C3836; orientation = "vertical";
@define-color base02 #504945; };
@define-color base03 #665C54; style = ''
@define-color base04 #BDAE93; @define-color base00 #282828;
@define-color base06 #D5C4A1; @define-color base01 #3C3836;
@define-color base06 #EBDBB2; @define-color base02 #504945;
@define-color base07 #FBF1C7; @define-color base03 #665C54;
@define-color base08 #FB4934; @define-color base04 #BDAE93;
@define-color base09 #FE8019; @define-color base06 #D5C4A1;
@define-color base0A #FABD2F; @define-color base06 #EBDBB2;
@define-color base0B #B8BB26; @define-color base07 #FBF1C7;
@define-color base0C #8EC07C; @define-color base08 #FB4934;
@define-color base0D #83A598; @define-color base09 #FE8019;
@define-color base0E #D3869B; @define-color base0A #FABD2F;
@define-color base0F #D65D0E; @define-color base0B #B8BB26;
@define-color base0C #8EC07C;
@define-color base0D #83A598;
@define-color base0E #D3869B;
@define-color base0F #D65D0E;
window { window {
margin: 5px; margin: 5px;
border-radius: 10px; border-radius: 10px;
background-color: @base03; background-color: @base03;
} }
#input { #input {
border-radius: 5px; border-radius: 5px;
background-color: @base03; background-color: @base03;
color: @base06; color: @base06;
} }
#inner-box { #inner-box {
margin: 5px; margin: 5px;
color: @base06; color: @base06;
background-color: @base00; background-color: @base00;
} }
#outer-box { #outer-box {
margin: 5px; margin: 5px;
background-color: @base00; background-color: @base00;
} }
#scroll { #scroll {
margin: 5px; margin: 5px;
background-color: @base00; background-color: @base00;
} }
#text { #text {
margin: 2px; margin: 2px;
} }
''; '';
}; };
} }

View file

@ -1,25 +1,27 @@
{ config, pkgs, ... }:
{ {
programs.eza.enable = true; config,
programs.zsh = { pkgs,
enable = true; ...
shellAliases = { }: {
ll = "exa --icons -l"; programs.eza.enable = true;
l = "exa --icons -la"; programs.zsh = {
ls = "exa --icons"; enable = true;
update = "sudo nixos-rebuild switch"; shellAliases = {
clear = "clear && fastfetch"; ll = "exa --icons -l";
}; l = "exa --icons -la";
ls = "exa --icons";
update = "sudo nixos-rebuild switch";
clear = "clear && fastfetch";
};
history.size = 10000; history.size = 10000;
autosuggestion.enable = true; autosuggestion.enable = true;
syntaxHighlighting.enable = true; syntaxHighlighting.enable = true;
oh-my-zsh = { oh-my-zsh = {
enable = true; enable = true;
plugins = [ "git" "docker" ]; plugins = ["git" "docker"];
theme = "strug"; theme = "strug";
}; };
}; };
} }

View file

@ -1,12 +1,14 @@
{ lib, config, pkgs, ... }:
let
cfg = config.main-user;
in
{ {
lib,
config,
pkgs,
...
}: let
cfg = config.main-user;
in {
options.main-user = { options.main-user = {
enable enable =
= lib.mkEnableOption "enable user module"; lib.mkEnableOption "enable user module";
username = lib.mkOption { username = lib.mkOption {
default = "mainuser"; default = "mainuser";
@ -21,7 +23,7 @@ in
users.users.${cfg.username} = { users.users.${cfg.username} = {
isNormalUser = true; isNormalUser = true;
initialPassword = "12345"; initialPassword = "12345";
extraGroups = [ "input" "networkmanager" "wheel" ]; extraGroups = ["input" "networkmanager" "wheel"];
description = "Stefan"; description = "Stefan";
shell = pkgs.zsh; shell = pkgs.zsh;
}; };