~ruther/nixos-config

f1797fd30af8823865c74f4ae598c994650e3b6c — Frantisek Bohacek 1 year, 14 days ago 8b52668
feat: some more services start only with qtile
M hosts/configuration.nix => hosts/configuration.nix +5 -0
@@ 35,7 35,12 @@
    # zsh is configured at home-manager level afterwards

  networking.networkmanager.enable = true;

  programs.nm-applet.enable = true;
  systemd.user.services.nm-applet = lib.mkIf config.programs.nm-applet.enable {
    wantedBy = lib.mkForce [ "qtile-services.target" ];
    partOf = lib.mkForce [ "qtile-services.target" ];
  };

  programs.command-not-found.enable = false;


M hosts/home.nix => hosts/home.nix +7 -7
@@ 178,13 178,13 @@

  gtk = {                                     # Theming
    enable = true;
    theme = {
      name = "Graphite-orange-Dark";
      package = pkgs.graphite-gtk-theme.override {
        themeVariants = ["orange"];
        colorVariants = ["dark"];
      };
    };
    # theme = {
    #   name = "Graphite-orange-Dark";
    #   package = pkgs.graphite-gtk-theme.override {
    #     themeVariants = ["orange"];
    #     colorVariants = ["dark"];
    #   };
    # };
    iconTheme = {
      name = "Tela-circle-dark";
      package = pkgs.tela-circle-icon-theme;

M modules/desktop/qtile/home.nix => modules/desktop/qtile/home.nix +4 -0
@@ 8,6 8,10 @@ in {
  services.autorandr = {
    enable = true;
  };
  systemd.user.services.autorandr = lib.mkIf config.services.autorandr.enable {
    Unit.PartOf = lib.mkForce [ "qtile-services.target" ];
    Install.WantedBy = lib.mkForce [ "qtile-services.target" ];
  };

  home.packages = with pkgs; [
    nur.rutherther.rutherther-mpris-ctl

A modules/desktop/qtile/scripts/xephyr => modules/desktop/qtile/scripts/xephyr +18 -0
@@ 0,0 1,18 @@
#!/usr/bin/env bash

HERE=$(dirname $(readlink -f $0))
SCREEN_SIZE=${SCREEN_SIZE:-800x600}
XDISPLAY=${XDISPLAY:-:1}
LOG_LEVEL=${LOG_LEVEL:-INFO}
APP=${APP:-$(python -c "from libqtile.utils import guess_terminal; print(guess_terminal())")}

Xephyr +extension RANDR -screen ${SCREEN_SIZE} ${XDISPLAY} -ac &
XEPHYR_PID=$!
(
  sleep 1
  env DISPLAY=${XDISPLAY} QTILE_XEPHYR=1 qtile start -l ${LOG_LEVEL} -c "$HERE"/../config/config.py $@ &
  QTILE_PID=$!
  env DISPLAY=${XDISPLAY} ${APP} &
  wait $QTILE_PID
  kill $XEPHYR_PID
)

Do not follow this link