nix-infra/common/fragments/graphical/default.nix

216 lines
4.5 KiB
Nix
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

{
pkgs,
config,
lib,
...
}:
{
imports = [
./barebones.nix
./audio.nix
./bspwm.nix
./clipboard.nix
./dunst.nix
./element.nix
./iosevka.nix
./kitty.nix
./lockscreen.nix
./mail.nix
./picom.nix
./polybar.nix
./rofi.nix
./syncthing.nix
./theme.nix
./url-eater.nix
];
nixpkgs.overlays = [
(final: prev: {
pads = final.callPackage ../../../common/pkgs/pads.nix { };
bspm = final.callPackage ../../../common/pkgs/bspm.nix { };
polybar-scripts = final.callPackage ../../../common/pkgs/polybar-scripts.nix { };
})
];
# User packages
users.users.agatha.packages = with pkgs; [
blueberry
brightnessctl
bspm
cider
darktable
dino
element-desktop
flameshot
gimp
glib
gnome.eog
gnome.file-roller
gnome.gnome-calendar
gnome.gnome-control-center
gnome.gnome-disk-utility
gnome.gnome-font-viewer
gnome.nautilus
mpv
mumble
nitrogen
obs-studio
obsidian
polybar-scripts
prismlauncher
rofi-calc
rofimoji
speechd
tdesktop
xdg-utils
xdotool
yubioath-flutter
];
# blame Obsidian
nixpkgs.config.permittedInsecurePackages = [ "electron-25.9.0" ];
# Brightness/volume keys
users.users.agatha.extraGroups = [ "video" ];
location = {
latitude = 49.0;
longitude = 8.4;
};
services.redshift = {
enable = true;
brightness.night = "0.8";
};
services.xserver = {
enable = true;
displayManager = {
gdm.enable = true;
sessionPackages = [ pkgs.sway ];
session = [
{
manage = "window";
name = "bspwm";
start =
let
cfg = config.home-manager.users.agatha;
in
''
${cfg.services.sxhkd.package}/bin/sxhkd ${toString cfg.services.sxhkd.extraOptions} &
${cfg.xsession.windowManager.bspwm.package}/bin/bspwm -c ${cfg.xdg.configHome}/bspwm/bspwmrc
'';
}
];
};
# Layout overrides
layout = lib.mkForce "eu,de(qwerty),ua,ru";
xkbOptions = "ctrl:nocaps,compose:rctrl";
autoRepeatDelay = 200;
autoRepeatInterval = 50;
libinput.enable = true;
};
home-manager.users.agatha = {
# Compose key sequences
home.file.".XCompose".text = ''
include "%L"
<Multi_key> <l> <f> : "( ͡° ͜ʖ ͡°)"
<Multi_key> <s> <f> : "¯\\_()_/¯"
<Multi_key> <g> <f> : " _ "
<Multi_key> <B> <B> : "🅱"
<Multi_key> <o> <asterisk> : ""
<Multi_key> <h> <r> : ""
<Multi_key> <v> <v> : ""
<Multi_key> <v> <period> <v> : ""
<Multi_key> <space> <space> : ""
<Multi_key> <s> <0> : "§"
<Multi_key> <b><l> : ""
<Multi_key> <h><s> : ""
<Multi_key> <s><r> : ""
<Multi_key> <t><r> : " trans rights uwu"
<Multi_key> <w><apostrophe> : "òwó"
<Multi_key> <W><apostrophe> : "ÒwÓ"
<Multi_key> <p><t> : "👉👈"
<Multi_key> <p><l> : "🥺"
<Multi_key> <m><s> : "/html <span data-mx-spoiler=\"\"></span>"
'';
};
services.gvfs.enable = true;
security.polkit.enable = true;
programs.dconf.enable = true;
programs.geary.enable = true;
programs.steam.enable = true;
programs.firefox = {
enable = true;
autoConfig = ''
pref("privacy.webrtc.legacyGlobalIndicator", false);
pref("privacy.webrtc.hideGlobalIndicator", true);
'';
};
# Screenshare on wlroots
xdg = {
portal = {
enable = true;
config.common.default = "*";
wlr.enable = true;
};
};
fonts.fontconfig.enable = true;
fonts.fontDir.enable = true;
fonts.packages = with pkgs; [
(nerdfonts.override {
fonts = [
"DaddyTimeMono"
"NerdFontsSymbolsOnly"
];
})
cantarell-fonts
cm_unicode
corefonts
crimson
crimson-pro
dejavu_fonts
fira-code
fira-code-symbols
font-awesome_5
helvetica-neue-lt-std
iosevka
noto-fonts-cjk
siji
twitter-color-emoji
];
services.printing = {
enable = true;
drivers = [ pkgs.hplip ];
};
services.avahi = {
enable = true;
nssmdns = true;
openFirewall = true;
};
hardware.bluetooth = {
enable = true;
settings = {
General = {
Disable = "Headset";
};
};
};
# Virtual Camera config
boot.extraModulePackages = with config.boot.kernelPackages; [ v4l2loopback ];
boot.kernelModules = [ "v4l2loopback" ];
}