helm/modules/desktop/default.nix

66 lines
1.6 KiB
Nix
Raw Normal View History

2019-08-06 10:56:54 -07:00
{ config, lib, pkgs, ... }:
{
2020-01-12 15:17:17 -08:00
my.packages = with pkgs; [
libqalculate
2019-08-06 10:56:54 -07:00
xclip
xdotool
2019-09-06 21:29:33 -07:00
mpv # video player
feh # image viewer
# Useful apps
2020-01-14 03:56:25 -08:00
calibre # managing my ebooks
2019-09-06 21:29:33 -07:00
evince # pdf reader
2019-08-06 10:56:54 -07:00
];
sound.enable = true;
hardware.pulseaudio.enable = true;
# Prevents ~/.esd_auth files by disabling the esound protocol module for
# pulseaudio, which I likely don't need. Is there a better way?
hardware.pulseaudio.configFile =
let paConfigFile =
with pkgs; runCommand "disablePulseaudioEsoundModule"
{ buildInputs = [ pulseaudio ]; } ''
mkdir "$out"
cp ${pulseaudio}/etc/pulse/default.pa "$out/default.pa"
sed -i -e 's|load-module module-esound-protocol-unix|# ...|' "$out/default.pa"
'';
in lib.mkIf config.hardware.pulseaudio.enable
"${paConfigFile}/default.pa";
2019-08-06 10:56:54 -07:00
services = {
2019-10-27 12:28:58 -07:00
xserver.enable = true;
2019-10-17 16:57:00 -07:00
redshift.enable = true;
2019-08-06 10:56:54 -07:00
};
2020-01-12 15:17:17 -08:00
# For redshift
location = (if config.time.timeZone == "America/Toronto" then {
latitude = 43.70011;
longitude = -79.4163;
} else if config.time.timeZone == "Europe/Copenhagen" then {
latitude = 55.88;
longitude = 12.5;
} else {});
2019-08-06 10:56:54 -07:00
fonts = {
enableFontDir = true;
enableGhostscriptFonts = true;
fonts = with pkgs; [
ubuntu_font_family
dejavu_fonts
fira-code
fira-code-symbols
symbola
noto-fonts
noto-fonts-cjk
font-awesome-ttf
];
fontconfig.defaultFonts = {
sansSerif = ["Ubuntu"];
monospace = ["Fira Code"];
};
};
}