2022-12-06 20:38:29 -08:00
|
|
|
{ self, config, pkgs, lib, ... }:
|
2022-09-18 15:13:50 -07:00
|
|
|
let
|
2022-09-27 05:13:16 -07:00
|
|
|
tex = (pkgs.texlive.combine {
|
|
|
|
inherit (pkgs.texlive) scheme-basic
|
|
|
|
dvisvgm dvipng# for preview and export as html
|
|
|
|
wrapfig amsmath ulem hyperref capt-of;
|
|
|
|
#(setq org-latex-compiler "lualatex")
|
|
|
|
#(setq org-preview-latex-default-process 'dvisvgm)
|
|
|
|
});
|
2022-09-18 15:13:50 -07:00
|
|
|
dracula-gtk = pkgs.fetchFromGitHub {
|
|
|
|
owner = "dracula";
|
|
|
|
repo = "gtk";
|
|
|
|
rev = "502f212d83bc67e8f0499574546b99ec6c8e16f9";
|
|
|
|
sha256 = "1wx9nzq7cqyvpaq4j60bs8g7gh4jk8qg4016yi4c331l4iw1ymsa";
|
|
|
|
};
|
|
|
|
in
|
|
|
|
{
|
|
|
|
# TODO modularize
|
2022-12-17 06:49:01 -08:00
|
|
|
imports = [
|
|
|
|
./battery-low-timer.nix
|
|
|
|
./cal-alarms.nix
|
|
|
|
];
|
2022-09-18 15:13:50 -07:00
|
|
|
|
2022-12-06 19:18:40 -08:00
|
|
|
# Secrets used by home-manager modules
|
|
|
|
age.secrets.fastmail.file = "${self}/secrets/fastmail.age";
|
|
|
|
age.secrets.fastmail.owner = "anish";
|
|
|
|
|
|
|
|
age.secrets.mossnet.file = "${self}/secrets/mossnet.age";
|
|
|
|
age.secrets.mossnet.owner = "anish";
|
|
|
|
|
2022-12-06 21:52:37 -08:00
|
|
|
# We don't plug USBs into servers
|
|
|
|
services.devmon.enable = true;
|
|
|
|
|
2022-09-18 15:13:50 -07:00
|
|
|
services = {
|
|
|
|
gnome.gnome-keyring.enable = true;
|
|
|
|
upower.enable = true;
|
|
|
|
|
|
|
|
dbus = {
|
|
|
|
enable = true;
|
|
|
|
packages = [ pkgs.dconf ];
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2022-10-03 06:59:21 -07:00
|
|
|
security.pam.services.Default.enableGnomeKeyring = true;
|
|
|
|
security.pam.services.Login.enableGnomeKeyring = true;
|
2022-09-18 15:13:50 -07:00
|
|
|
security.pam.services.sddm.enableGnomeKeyring = true;
|
|
|
|
|
|
|
|
environment.sessionVariables = rec {
|
|
|
|
XDG_CACHE_HOME = "\${HOME}/.cache";
|
|
|
|
XDG_CONFIG_HOME = "\${HOME}/.config";
|
|
|
|
XDG_BIN_HOME = "\${HOME}/.local/bin";
|
|
|
|
XDG_DATA_HOME = "\${HOME}/.local/share";
|
|
|
|
|
|
|
|
PATH = [
|
|
|
|
"\${XDG_BIN_HOME}"
|
|
|
|
];
|
|
|
|
};
|
|
|
|
|
|
|
|
environment.systemPackages = with pkgs; [
|
2022-12-06 07:26:43 -08:00
|
|
|
unstable.signal-desktop # bridge to sealight?
|
|
|
|
unstable.sublime-music
|
|
|
|
unstable.nheko
|
|
|
|
unstable.tootle
|
2022-12-09 07:48:26 -08:00
|
|
|
newsflash
|
|
|
|
liferea
|
2022-12-06 19:18:40 -08:00
|
|
|
|
2022-09-18 15:13:50 -07:00
|
|
|
scrot
|
2022-12-06 07:26:43 -08:00
|
|
|
ripcord
|
2022-12-17 08:58:13 -08:00
|
|
|
xfce.orage
|
2022-09-18 15:13:50 -07:00
|
|
|
feh
|
|
|
|
sxiv
|
|
|
|
xkblayout-state
|
2022-12-06 07:26:43 -08:00
|
|
|
vcv-rack
|
2022-09-18 15:13:50 -07:00
|
|
|
zathura
|
|
|
|
calibre
|
2022-10-03 06:59:21 -07:00
|
|
|
fractal
|
2022-09-18 15:13:50 -07:00
|
|
|
mpv
|
|
|
|
zeal
|
|
|
|
xclip
|
|
|
|
xdotool
|
|
|
|
rofi
|
|
|
|
rofimoji
|
|
|
|
rofi-calc
|
|
|
|
eww
|
|
|
|
obs-studio
|
|
|
|
lightdm
|
|
|
|
dunst
|
|
|
|
libnotify
|
|
|
|
(polybar.override {
|
2022-12-19 21:50:50 -08:00
|
|
|
pulseSupport = true;
|
2022-09-18 15:13:50 -07:00
|
|
|
nlSupport = true;
|
|
|
|
})
|
|
|
|
papirus-icon-theme
|
|
|
|
calendar-cli
|
|
|
|
wyrd
|
2022-09-27 05:13:16 -07:00
|
|
|
tex
|
2022-12-15 02:29:19 -08:00
|
|
|
tic-80
|
2022-09-18 15:13:50 -07:00
|
|
|
];
|
|
|
|
|
|
|
|
|
|
|
|
location.provider = "geoclue2";
|
|
|
|
services = {
|
|
|
|
redshift = {
|
|
|
|
enable = true;
|
|
|
|
temperature = {
|
|
|
|
day = 5500;
|
|
|
|
night = 3700;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
xserver = {
|
|
|
|
enable = true;
|
|
|
|
layout = "us,dvorak";
|
|
|
|
desktopManager.wallpaper.mode = "fill";
|
|
|
|
displayManager = {
|
|
|
|
defaultSession = "none+bspwm";
|
|
|
|
sessionCommands = ''
|
|
|
|
${pkgs.xorg.xrdb}/bin/xrdb -merge <<EOF
|
|
|
|
#define blk #1F2430
|
|
|
|
#define bblk #F28779
|
|
|
|
#define red #A6CC70
|
|
|
|
#define bred #FFCC66
|
|
|
|
#define grn #5CCFE6
|
|
|
|
#define bgrn #F29E74
|
|
|
|
#define ylw #77A8D9
|
|
|
|
#define bylw #5C6773
|
|
|
|
#define blu #707A8C
|
|
|
|
#define bblu #F27983
|
|
|
|
#define mag #BAE67E
|
|
|
|
#define bmag #FFD580
|
|
|
|
#define cyn #73D0FF
|
|
|
|
#define bcyn #FFA759
|
|
|
|
#define wht #95E6CB
|
|
|
|
#define bwht #CBCCC6
|
|
|
|
#define bg blk
|
|
|
|
#define fg wht
|
|
|
|
|
|
|
|
*.foreground: fg
|
|
|
|
*.background: bg
|
|
|
|
*.cursorColor: mag
|
|
|
|
|
|
|
|
*.color0: blk
|
|
|
|
*.color8: bblk
|
|
|
|
*.color1: red
|
|
|
|
*.color9: bred
|
|
|
|
*.color2: grn
|
|
|
|
*.color10: bgrn
|
|
|
|
*.color3: ylw
|
|
|
|
*.color11: bylw
|
|
|
|
*.color4: blu
|
|
|
|
*.color12: bblu
|
|
|
|
*.color5: mag
|
|
|
|
*.color13: bmag
|
|
|
|
*.color6: cyn
|
|
|
|
*.color14: bcyn
|
|
|
|
*.color7: wht
|
|
|
|
*.color15: bwht
|
|
|
|
|
|
|
|
! greys
|
|
|
|
*.color234: #1E2029
|
|
|
|
*.color235: #282a36
|
|
|
|
*.color236: #373844
|
|
|
|
*.color237: #44475a
|
|
|
|
*.color239: #565761
|
|
|
|
*.color240: #6272a4
|
|
|
|
*.color241: #b6b6b2
|
|
|
|
EOF
|
|
|
|
|
|
|
|
# hotplug
|
|
|
|
connect() {
|
|
|
|
xrandr --output HDMI-2 --same-as eDP-1
|
|
|
|
}
|
|
|
|
|
|
|
|
disconnect() {
|
|
|
|
xrandr --output HDMI-2 --off
|
|
|
|
}
|
|
|
|
|
|
|
|
xrandr | grep "HDMI-2 connected" &>>/dev/null && connect || disconnect
|
|
|
|
|
|
|
|
# keyboard on curve is busted
|
|
|
|
get_keyboard_id() {
|
|
|
|
xinput list | grep 'AT Translated Set' | cut -f2 | cut -d'=' -f2 | xinput float
|
|
|
|
}
|
|
|
|
|
|
|
|
disconnect_keyboard() {
|
|
|
|
id=$(get_keyboard_id)
|
|
|
|
xinput float $id
|
|
|
|
unset id
|
|
|
|
}
|
|
|
|
|
|
|
|
attach_keyboard() {
|
|
|
|
id=$(get_keyboard_id)
|
|
|
|
xinput reattach $id 3
|
|
|
|
}
|
|
|
|
|
|
|
|
disconnect_keyboard
|
|
|
|
'';
|
2022-10-19 04:11:13 -07:00
|
|
|
lightdm = {
|
|
|
|
enable = true;
|
|
|
|
background = "/etc/nixos/users/profiles/desktop/background.jpg";
|
|
|
|
greeters.mini = {
|
|
|
|
enable = true;
|
|
|
|
user = "anish";
|
|
|
|
extraConfig = ''
|
|
|
|
text-color = "#ff79c6"
|
|
|
|
password-background-color = "#1E2029"
|
|
|
|
window-color = "#181a23"
|
|
|
|
border-color = "#181a23"
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
};
|
2022-09-18 15:13:50 -07:00
|
|
|
};
|
|
|
|
windowManager.bspwm.enable = true;
|
|
|
|
#windowManager.bspwm.configFile = "/home/anish/.bspwm/bspwmrc";
|
|
|
|
windowManager.bspwm.sxhkd.configFile = "/home/anish/.config/sxhkdrc";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
fonts.fonts = with pkgs; [
|
|
|
|
fira-code
|
|
|
|
fira-code-symbols
|
|
|
|
hermit
|
|
|
|
#hack
|
|
|
|
siji
|
|
|
|
font-awesome
|
|
|
|
proggyfonts
|
|
|
|
(nerdfonts.override { fonts = [ "FiraCode" "DroidSansMono" "Iosevka" ]; })
|
|
|
|
];
|
|
|
|
}
|