home: wm: use explicit 'enable' options

This is so that I can explicitly enable them if I were to use Wayland
and Sway, given that they should be compatible with both environment.

This also means that putting them in `/home/x/` would a misnomer... Will
revisit this if and when I try out Wayland and sway...
This commit is contained in:
Bruno BELANYI 2021-04-05 21:27:20 +00:00
parent 38a475d35d
commit c56517497a
3 changed files with 22 additions and 5 deletions

View file

@ -1,9 +1,9 @@
{ config, lib, pkgs, ... }:
let
isEnabled = config.my.home.wm.windowManager == "i3";
cfg = config.my.home.wm.i3bar;
in
{
config = lib.mkIf isEnabled {
config = lib.mkIf cfg.enable {
home.packages = with pkgs; [
alsaUtils # Used by `sound` block
lm_sensors # Used by `temperature` block