69 lines
1.4 KiB
Nix
69 lines
1.4 KiB
Nix
# Buckwheat home.nix
|
|
{ config, lib, pkgs, inputs, user, ... }:
|
|
{
|
|
xsession.windowManager.bspwm = {
|
|
monitors = {
|
|
DP-1 = [
|
|
"1"
|
|
"2"
|
|
"3"
|
|
"4"
|
|
"5"
|
|
];
|
|
DP-2 = [
|
|
"6"
|
|
"7"
|
|
"8"
|
|
"9"
|
|
"0"
|
|
];
|
|
};
|
|
};
|
|
services = {
|
|
udiskie = {
|
|
enable = true;
|
|
automount = true;
|
|
notify = true;
|
|
settings = {
|
|
program_options = {
|
|
udisks_version = 2;
|
|
};
|
|
icon_names.media = [
|
|
"media-optical"
|
|
];
|
|
};
|
|
};
|
|
};
|
|
systemd.user.services = {
|
|
cmus-library-refresh = {
|
|
Unit = {
|
|
Description = "cmus library refresh to add any new songs";
|
|
};
|
|
Service = {
|
|
Type = "oneshot";
|
|
ExecStart = toString (
|
|
pkgs.writeShellScript "cmus-library-refresh" ''
|
|
set -eou pipefail
|
|
${pkgs.bash}/bin/bash "/home/${user.name}/.local/bin/cmus_library_refresh.sh";
|
|
''
|
|
);
|
|
};
|
|
Install.WantedBy = [ "default.target" ];
|
|
};
|
|
};
|
|
systemd.user.timers = {
|
|
cmus_library_refresh = {
|
|
Unit = {
|
|
Description = "cmus library refresh to add any new songs";
|
|
Documentation = [ "man:cmus-remote(1)" ];
|
|
};
|
|
Timer = {
|
|
Unit = "cmus_library_refresh";
|
|
OnBootSec = "5m";
|
|
OnUnitActiveSec = "1h";
|
|
};
|
|
Install.WantedBy = [ "timers.target" ];
|
|
};
|
|
};
|
|
}
|