summaryrefslogtreecommitdiff
path: root/accounts/gkleen@sif/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'accounts/gkleen@sif/default.nix')
-rw-r--r--accounts/gkleen@sif/default.nix188
1 files changed, 188 insertions, 0 deletions
diff --git a/accounts/gkleen@sif/default.nix b/accounts/gkleen@sif/default.nix
new file mode 100644
index 00000000..545d40b5
--- /dev/null
+++ b/accounts/gkleen@sif/default.nix
@@ -0,0 +1,188 @@
1{ flake, userName, pkgs, customUtils, lib, config, ... }@inputs:
2let
3 cfg = config.home-manager.users.${userName};
4 xmonad = import ./xmonad pkgs.haskellPackages;
5in {
6 imports = with flake.nixosModules.userProfiles.${userName}; [
7 mpv
8 ];
9
10 home-manager.users.${userName} = {
11 programs = {
12 ssh = {
13 matchBlocks = import ./ssh-hosts.nix; # customUtils.recImport { dir = ./ssh-hosts; };
14 extraConfig = ''
15 Match host uniworx3.ifi.lmu.de,uniworx4.ifi.lmu.de,uni2workgw.ifi.lmu.de,blackbeard.tcs.ifi.lmu.de,gitlab2.rz.ifi.lmu.de,oregon.tcs.ifi.lmu.de !exec "nc -z -w 1 %h %p &>/dev/null"
16 ProxyJump gate
17 '';
18 };
19
20 emacs = {
21 enable = true;
22 extraPackages = epkgs: with epkgs; [
23 evil evil-dvorak evil-magit undo-tree magit haskell-mode
24 nix-mode yaml-mode json-mode shakespeare-mode
25 smart-mode-line highlight-parentheses highlight-symbol
26 notmuch ag sass-mode lua-mode fira-code-mode
27 ];
28 };
29 firefox = {
30 enable = true;
31 profiles.default = {
32 settings = {
33 "layout.css.devPixelsPerPx" = "1.75";
34 "browser.tabs.drawInTitlebar" = false;
35 "toolkit.legacyUserProfileCustomizations.stylesheets" = true;
36 };
37 };
38 };
39
40 urxvt = {
41 enable = true;
42 package = pkgs.rxvt_unicode-with-plugins;
43 fonts = [ "xft:FiraCode Nerd Font Mono:style=Regular:pixelsize=21" ];
44 scroll = {
45 lines = 0;
46 bar.enable = false;
47 };
48 extraConfig = {
49 urgentOnBell = false;
50 print-pipe = "cat >/dev/null";
51 perl-ext-common = "52-osc,url-select";
52 "url-select.launcher" = "firefox";
53 "url-select.underline" = true;
54 };
55 keybindings = {
56 "M-u" = "perl:url-select:select_next";
57 };
58 };
59
60 zathura = {
61 enable = true;
62 package = pkgs.zathura.override { useMupdf = false; };
63 };
64
65 mpv.config = {
66 demuxer-max-bytes = 1073741824;
67 demuxer-max-back-bytes = 268435456;
68 };
69
70 autorandr = {
71 enable = true;
72 hooks.postswitch = {
73 # "restart-compton" = "${pkgs.systemd}/bin/systemctl --user try-restart picom";
74 "restart-trays" = ''
75 ${pkgs.coreutils}/bin/sleep 5
76 ${pkgs.systemd}/bin/systemctl --user try-restart trayer xmobar
77 '';
78 };
79 profiles = customUtils.recImport { dir = ./autorandr-profiles; };
80 };
81
82 zsh.initExtra = "source ${./zshrc}";
83 };
84
85 services = {
86 dunst = {
87 settings = import ./dunst-settings.nix;
88 iconTheme = cfg.gtk.iconTheme;
89 enable = true;
90 };
91 emacs.enable = true;
92 gpg-agent = {
93 enable = true;
94 enableSshSupport = true;
95 extraConfig = ''
96 pinentry-program ${pkgs.pinentry-gtk2}/bin/pinentry
97 grab
98 '';
99 };
100 pasystray.enable = true;
101 udiskie = {
102 enable = true;
103 automount = false;
104 };
105 unclutter = {
106 enable = true;
107 timeout = 5;
108 };
109 network-manager-applet.enable = true;
110 blueman-applet.enable = true;
111
112 sxhkd = {
113 enable = true;
114 keybindings = {
115 "button8" = "pacmd set-source-mute @DEFAULT_SOURCE@ 0";
116 "@button8" = "pacmd set-source-mute @DEFAULT_SOURCE@ 1";
117 "button9" = "pacmd set-sink-mute @DEFAULT_SINK@ 1";
118 "@button9" = "pacmd set-sink-mute @DEFAULT_SINK@ 0";
119 };
120 };
121 };
122
123 gtk = {
124 enable = true;
125 font.name = "DejaVu Sans 6";
126 theme = {
127 package = pkgs.equilux-theme;
128 name = "Equilux-compact";
129 };
130 iconTheme = {
131 package = pkgs.paper-icon-theme;
132 name = "Paper";
133 };
134 };
135
136 xsession = {
137 enable = true;
138
139 windowManager.command = "${xmonad}/bin/xmonad";
140
141 initExtra = let
142 lockScript = pkgs.writeScript "lock" ''
143 #!${pkgs.stdenv.shell}
144 ${pkgs.playerctl}/bin/playerctl -a pause
145 exec ${pkgs.xsecurelock}/bin/xsecurelock
146 '';
147 in ''
148 ${pkgs.coreutils}/bin/env XSECURELOCK_WANT_FIRST_KEYPRESS=1 XSECURELOCK_DIM_ALPHA=1 ${pkgs.xss-lock}/bin/xss-lock -l -n ${pkgs.xsecurelock}/libexec/xsecurelock/dimmer -- ${lockScript} &
149 ${pkgs.xorg.xinput}/bin/xinput disable 'SynPS/2 Synaptics TouchPad' # Synaptics TM3512-010
150 ${pkgs.xorg.xset}/bin/xset s 590 10
151 '';
152 };
153
154 xresources.properties = import ./xresources.nix;
155
156 home = {
157 packages = with pkgs; [
158 fira-code powerline-fonts nerdfonts pavucontrol keepassxc
159 youtube-dl sxiv xclip mumble pulseaudio-ctl libnotify synergy
160 xorg.xbacklight screen-message pidgin-with-plugins
161 google-play-music-desktop-player qt5ct playerctl evince
162 thunderbird zulip zoom-us steam steam-run wireshark skype
163 virt-manager rclone cached-nix-shell xournal discord xmonad
164 worktime fira-code-symbols
165 ];
166
167 file = {
168 ".emacs".source = ./emacs.el;
169 ".backup-munin".source = ./backup-patterns;
170 ".mozilla/firefox/default/chrome/userChrome.css".source = ./firefox-chrome.css;
171 ".mozilla/firefox/default/chrome/userContent.css".source = ./firefox-content.css;
172 };
173
174 sessionVariables = {
175 GDK_SCALE = 96.0 / 282.0;
176 XDG_DATA_DIRS = "${pkgs.gsettings-desktop-schemas}/share/gsettings-schemas/${pkgs.gsettings-desktop-schemas.name}:${pkgs.gtk3}/share/gsettings-schemas/${pkgs.gtk3.name}:$XDG_DATA_DIRS";
177 QT_AUTO_SCREEN_SCALE_FACTOR = 1;
178 QT_QPA_PLATFORMTHEME = "qt5ct";
179 };
180
181 stateVersion = "20.03";
182 };
183
184 fonts.fontconfig.enable = true;
185
186 systemd.user = import ./systemd.nix inputs;
187 };
188}