nix-config/modules/home-manager/desktop-xmonad/common.nix

52 lines
1.4 KiB
Nix
Raw Normal View History

2022-01-25 12:27:52 +01:00
{ config, pkgs, ... }:
let
obtoxmd = pkgs.callPackage ./obtoxmd.nix { inherit config pkgs; };
in {
imports = [ ./rofi.nix ./misc.nix ];
home = {
keyboard = {
layout = "us";
options = [ "caps:escape" ];
variant = "altgr-intl";
};
2022-08-22 11:59:41 +02:00
packages = [ obtoxmd pkgs.openbox pkgs.xsel ];
2022-01-25 12:27:52 +01:00
file = {
".xmonad/icons/3cols.xpm".source = ./icons/3cols.xpm;
".xmonad/icons/float.xpm".source = ./icons/float.xpm;
".xmonad/icons/full.xpm".source = ./icons/full.xpm;
".xmonad/icons/grid.xpm".source = ./icons/grid.xpm;
".xmonad/icons/mtall.xpm".source = ./icons/mtall.xpm;
".xmonad/icons/tabs.xpm".source = ./icons/tabs.xpm;
".xmonad/icons/tall.xpm".source = ./icons/tall.xpm;
};
};
xsession = {
enable = true;
initExtra = ''
xset s off -dpms
${pkgs.autorandr}/bin/autorandr --change --default default
export WINIT_X11_SCALE_FACTOR=1.33
'';
};
services.stalonetray = {
enable = true;
config = {
2022-11-08 13:54:36 +01:00
icon_size = 16;
2022-01-25 12:27:52 +01:00
background = "#282828"; # todo
sticky = true;
geometry = "3x1-350+0";
icon_gravity = "E";
grow_gravity = "E";
};
};
programs.zsh.loginExtra = ''
[[ -z "''${DISPLAY}" ]] && [[ "$(tty)" = "/dev/tty1" ]] && \
exec "${pkgs.xorg.xinit}/bin/startx" 1> "${config.home.homeDirectory}/.xsession-errors" 2>&1
'';
}