]> Git — Sourcephile - julm/julm-nix.git/blob - homes/julm.nix
wireguard: decrease losurdo's persistentKeepalive to 5
[julm/julm-nix.git] / homes / julm.nix
1 { pkgs, lib, config, hostName, ... }:
2 {
3 imports = [
4 ./softwares.nix
5 ./options.nix
6 julm/mutt.nix
7 (import (julm/hosts + "/${hostName}.nix"))
8 ];
9 host.desktop = lib.elem hostName [ /*"losurdo"*/ "oignon" ];
10 host.server = lib.elem hostName [ "losurdo" "mermet" ];
11 programs.bat.enable = true;
12 programs.bash.enable = true;
13 #programs.broot.enable = true;
14 programs.firefox = {
15 enable = config.host.desktop;
16 profiles =
17 let defaultProfile = {
18 settings = {
19 "browser.bookmarks.showMobileBookmarks" = true;
20 "browser.search.isUS" = false;
21 "browser.search.region" = "FR";
22 "distribution.searchplugins.defaultLocale" = "fr-FR";
23 "general.useragent.locale" = "fr-FR";
24 "security.identityblock.show_extended_validation" = true;
25 "toolkit.legacyUserProfileCustomizations.stylesheets" = true;
26 };
27 userChrome = builtins.readFile softwares/firefox/userChrome.css;
28 }; in {
29 "rp4xy6ye.2021" = lib.mkMerge [defaultProfile {
30 id = 0;
31 name = "2021";
32 settings = {
33 "browser.startup.homepage" = "https://code.sourcephile.fr";
34 };
35 }];
36 "8y3d28fa.tor" = lib.mkMerge [defaultProfile {
37 id = 1;
38 name = "tor";
39 settings = {
40 "browser.startup.homepage" = "https://check.torproject.org";
41 };
42 }];
43 };
44 };
45 programs.gpg.enable = true;
46 home.file."${config.programs.gpg.homedir}/gpg.conf".text = ''
47 # julm@autogeree.net
48 trusted-key 0xD15AF7F467E8299B
49 # julm@sourcephile.fr (2021-08-12)
50 trusted-key 0xA58CD81C3863926F
51 '';
52 services.gpg-agent.enable = true;
53 services.gpg-agent.sshKeys = [
54 # julm@autogeree.net
55 "D275EBA09C7E1FFBFB47F6EEF164E6D56FB24AB2"
56 # julm@sourcephile.fr (2021-08-12)
57 "3D94D14514F1EA2B6D62F1275D888897B082415D"
58 ];
59 programs.direnv.enable = true;
60 programs.htop.enable = true;
61 programs.irssi.enable = hostName == "mermet" || hostName == "losurdo";
62 programs.irssi.extraConfig = builtins.readFile julm/irssi/config;
63 home.file.".irssi/passwd".text = ''
64 FreeNode : ${pkgs.pass}/bin/pass freenode.net/irc/julm
65 GeekNode : ${pkgs.pass}/bin/pass geeknode.org/irc/julm
66 IndyMedia : ${pkgs.pass}/bin/pass indymedia.org/irc/julm
67 Libera : ${pkgs.pass}/bin/pass libera.chat/irc/julm
68 OFTC : ${pkgs.pass}/bin/pass oftc.net/irc/julm
69 ToileLibre : ${pkgs.pass}/bin/pass toile-libre.org/irc/julm
70 '';
71 programs.man.enable = true;
72 #programs.neovim.enable = true;
73 programs.ssh.enable = true;
74 programs.ssh.matchBlocks."lan.losurdo.sourcephile.fr" = {
75 compression = true; # Helps to get a better framerate with forwardX11
76 forwardX11 = true;
77 forwardX11Trusted = true;
78 serverAliveInterval = 15;
79 };
80 programs.tmux.enable = true;
81 programs.vim.enable = true;
82 manual.manpages.enable = true;
83 programs.git = {
84 enable = true;
85 userName = "Julien Moutinho";
86 userEmail = "julm@sourcephile.fr";
87 signing.key = "0x7182433A39582282929B2A222E3618DD0D087650";
88 signing.signByDefault = false;
89 package =
90 if lib.elem hostName [ "losurdo" "oignon" ]
91 then pkgs.gitFull
92 else pkgs.gitMinimal;
93 extraConfig = {
94 sendemail.smtpEncryption = "ssl"; # Yes, "ssl", not "tls" which does not work because it expects STARTTLS.
95 sendemail.smtpServer = "mail.sourcephile.fr";
96 sendemail.smtpServerPort = "465";
97 sendemail.smtpUser = "julm@sourcephile.fr";
98 };
99 };
100 services.redshift.enable = lib.mkDefault config.host.desktop;
101 xsession.enable = lib.mkDefault config.host.desktop;
102 xsession.windowManager.xmonad.enable = lib.mkDefault config.host.desktop;
103 home.stateVersion = "20.09";
104 home.sessionPath = [ "${config.home.homeDirectory}/bin" ];
105 home.sessionVariables = {
106 EDITOR = "vim";
107 LANG = "fr_FR.UTF-8";
108 LESS = "-FRSX";
109 LOCALE_ARCHIVE = "${pkgs.glibcLocales}/lib/locale/locale-archive";
110 MANPAGER = "less";
111 };
112 # Warning: triggers a rebuild of mumble
113 #nixpkgs.config.mumble.speechdSupport = lib.mkDefault config.host.desktop;
114 home.packages = [
115 pkgs.acpi
116 #pkgs.amfora
117 pkgs.aria2
118 pkgs.aspell
119 pkgs.aspellDicts.fr
120 pkgs.bc
121 pkgs.binutils
122 pkgs.bison
123 pkgs.bmon
124 #pkgs.browsh
125 #pkgs.cabal2nix
126 pkgs.cachix
127 pkgs.compsize
128 pkgs.convmv
129 pkgs.coreutils
130 pkgs.croc
131 pkgs.cryptsetup
132 pkgs.curl
133 #pkgs.dnsutils
134 pkgs.dstat
135 pkgs.e2fsprogs
136 pkgs.ethtool
137 pkgs.exa
138 pkgs.ffmpeg
139 pkgs.file
140 pkgs.flex
141 pkgs.gcc
142 pkgs.git-crypt
143 pkgs.git-quick-stats
144 #pkgs.git-remote-gpg
145 pkgs.glib # gio
146 #pkgs.go-mtpfs
147 pkgs.gnumake
148 pkgs.gvfs
149 #pkgs.haskell.packages.ghc865.zerobin
150 pkgs.hledger
151 pkgs.home-manager
152 pkgs.htop
153 pkgs.hunspell
154 pkgs.hunspellDicts.fr-moderne
155 pkgs.hwinfo
156 pkgs.imagemagick
157 pkgs.inetutils
158 pkgs.ipfs
159 #pkgs.i7z
160 pkgs.jq
161 pkgs.knot-dns
162 pkgs.ldns
163 pkgs.less
164 pkgs.lf
165 pkgs.lftp
166 pkgs.libfaketime
167 pkgs.libidn
168 pkgs.libxml2.bin
169 #pkgs.linuxPackages.cpupower
170 #pkgs.linuxPackages.perf
171 pkgs.lm_sensors
172 pkgs.lsof
173 pkgs.lsscsi
174 pkgs.mastodon-archive
175 #pkgs.meli
176 pkgs.miniupnpc
177 pkgs.mosh
178 pkgs.ncdu
179 pkgs.ncurses
180 pkgs.neofetch
181 pkgs.nix-prefetch-git
182 pkgs.nixpkgs-review
183 pkgs.nmon
184 pkgs.nnn
185 pkgs.ntfs3g
186 #pkgs.onionshare
187 pkgs.openssl
188 pkgs.opusTools
189 pkgs.p7zip
190 pkgs.parted
191 pkgs.pass
192 pkgs.pastebinit
193 pkgs.patchelf
194 pkgs.pciutils
195 pkgs.podl
196 pkgs.poppler_utils
197 pkgs.powertop
198 pkgs.procps
199 #pkgs.profanity
200 pkgs.pv
201 pkgs.qprint
202 pkgs.reuse
203 #pkgs.ranger
204 pkgs.rdfind
205 pkgs.ripgrep
206 pkgs.sanoid
207 pkgs.sdate
208 pkgs.shellcheck
209 pkgs.sipcalc
210 pkgs.smartmontools
211 pkgs.socat
212 pkgs.sqlite
213 pkgs.sshfs
214 pkgs.stig
215 pkgs.strace
216 pkgs.stress
217 pkgs.sudo
218 pkgs.tcpdump
219 pkgs.thttpd
220 pkgs.tig
221 pkgs.tree
222 pkgs.unar
223 pkgs.unzip
224 pkgs.usbutils
225 pkgs.utillinux
226 pkgs.vbetool
227 pkgs.weechat
228 pkgs.wget
229 pkgs.wgetpaste
230 pkgs.which
231 pkgs.xdg_utils
232 pkgs.xmlstarlet
233 pkgs.xsel
234 pkgs.youtube-dl
235 pkgs.yubikey-personalization
236 pkgs.zfs
237 ] ++ lib.optionals config.host.desktop [
238 pkgs.amule
239 #pkgs.calibre
240 #pkgs.chromium
241 pkgs.dino
242 pkgs.djview
243 pkgs.dmenu
244 pkgs.evince
245 pkgs.freeciv_gtk
246 pkgs.gajim
247 pkgs.geeqie
248 pkgs.gimp
249 pkgs.glxinfo
250 pkgs.gparted
251 pkgs.graphviz
252 pkgs.hicolor-icon-theme
253 pkgs.keepass
254 pkgs.libdvdcss
255 pkgs.libreoffice
256 pkgs.liferea
257 pkgs.mplayer
258 pkgs.mpv
259 pkgs.mumble
260 pkgs.networkmanager-openvpn
261 pkgs.networkmanagerapplet
262 pkgs.nix-du
263 pkgs.pavucontrol
264 pkgs.thunderbird
265 pkgs.transmission-gtk
266 pkgs.vlc
267 pkgs.xclip
268 pkgs.xorg.xkill
269 pkgs.xsane
270 pkgs.yubikey-personalization-gui
271 ];
272 }