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.nix181
1 files changed, 181 insertions, 0 deletions
diff --git a/accounts/gkleen@sif/default.nix b/accounts/gkleen@sif/default.nix
new file mode 100644
index 00000000..9f2df668
--- /dev/null
+++ b/accounts/gkleen@sif/default.nix
@@ -0,0 +1,181 @@
1{ flake, userName, pkgs, customUtils, lib, config, ... }:
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
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:Fira Mono for Powerline:style=Medium:pixelsize=20" ];
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
83 services = {
84 dunst = {
85 settings = import ./dunst-settings.nix;
86 iconTheme = cfg.gtk.iconTheme;
87 enable = true;
88 };
89 emacs.enable = true;
90 gpg-agent = {
91 enable = true;
92 enableSshSupport = true;
93 extraConfig = ''
94 pinentry-program ${pkgs.pinentry-gtk2}/bin/pinentry
95 grab
96 '';
97 };
98 pasystray.enable = true;
99 udiskie = {
100 enable = true;
101 automount = false;
102 };
103 unclutter = {
104 enable = true;
105 timeout = 5;
106 };
107 network-manager-applet.enable = true;
108 blueman-applet.enable = true;
109
110 sxhkd = {
111 enable = true;
112 keybindings = {
113 "button8" = "pacmd set-source-mute @DEFAULT_SOURCE@ 0";
114 "@button8" = "pacmd set-source-mute @DEFAULT_SOURCE@ 1";
115 "button9" = "pacmd set-sink-mute @DEFAULT_SINK@ 1";
116 "@button9" = "pacmd set-sink-mute @DEFAULT_SINK@ 0";
117 };
118 };
119 };
120
121 gtk = {
122 enable = true;
123 font.name = "DejaVu Sans 6";
124 theme = {
125 package = pkgs.equilux-theme;
126 name = "Equilux-compact";
127 };
128 iconTheme = {
129 package = pkgs.paper-icon-theme;
130 name = "Paper";
131 };
132 };
133
134 xsession = {
135 enable = true;
136
137 windowManager.command = "${xmonad}/bin/xmonad";
138
139 initExtra = let
140 lockScript = pkgs.writeScript "lock" ''
141 #!${pkgs.stdenv.shell}
142 ${pkgs.playerctl}/bin/playerctl -a pause
143 exec ${pkgs.xsecurelock}/bin/xsecurelock
144 '';
145 in ''
146 ${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} &
147 ${pkgs.xorg.xinput}/bin/xinput disable 'SynPS/2 Synaptics TouchPad' # Synaptics TM3512-010
148 ${pkgs.xorg.xset}/bin/xset s 590 10
149 '';
150 };
151
152 xresources.properties = import ./xresources.nix;
153
154 home = {
155 packages = with pkgs; [
156 fira-code powerline-fonts nerdfonts pavucontrol keepassxc
157 youtube-dl sxiv xclip mumble pulseaudio-ctl libnotify synergy
158 xorg.xbacklight screen-message pidgin-with-plugins
159 google-play-music-desktop-player qt5ct playerctl evince
160 thunderbird zulip zoom-us steam steam-run wireshark skype
161 virt-manager rclone cached-nix-shell xournal discord xmonad
162 ];
163
164 file = {
165 ".emacs".source = ./emacs.el;
166 ".backup-munin".source = ./backup-patterns;
167 ".mozilla/firefox/default/chrome/userChrome.css".source = ./firefox-chrome.css;
168 ".mozilla/firefox/default/chrome/userContent.css".source = ./firefox-content.css;
169 };
170
171 sessionVariables = {
172 GDK_SCALE = 96.0 / 282.0;
173 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";
174 QT_AUTO_SCREEN_SCALE_FACTOR = 1;
175 QT_QPA_PLATFORMTHEME = "qt5ct";
176 };
177
178 stateVersion = "20.03";
179 };
180 };
181}