2021-06-03 02:03:20 +02:00
|
|
|
{ config, lib, pkgs, ... }:
|
|
|
|
|
|
|
|
let
|
2021-09-26 11:08:45 +02:00
|
|
|
i3 = {
|
|
|
|
ws1 = "1";
|
|
|
|
ws2 = "ABC";
|
|
|
|
ws3 = "3: Test";
|
|
|
|
ws4 = ''!"§$%&/(){}[]=?\*#<>-_.:,;²³'';
|
2023-07-14 21:25:55 +02:00
|
|
|
ws5 = "Multiple";
|
2021-09-26 11:08:45 +02:00
|
|
|
};
|
2021-06-03 02:03:20 +02:00
|
|
|
|
|
|
|
in {
|
2021-09-26 11:08:45 +02:00
|
|
|
imports = [ ./sway-stubs.nix ];
|
|
|
|
|
|
|
|
wayland.windowManager.sway = {
|
|
|
|
enable = true;
|
|
|
|
package = config.lib.test.mkStubPackage { outPath = "@sway@"; };
|
2023-11-09 19:19:45 +01:00
|
|
|
checkConfig = false;
|
2021-09-26 11:08:45 +02:00
|
|
|
# overriding findutils causes issues
|
|
|
|
config.menu = "${pkgs.dmenu}/bin/dmenu_run";
|
|
|
|
|
|
|
|
config.workspaceOutputAssign = [
|
|
|
|
{
|
|
|
|
workspace = "${i3.ws1}";
|
|
|
|
output = "eDP";
|
|
|
|
}
|
|
|
|
{
|
|
|
|
workspace = "${i3.ws2}";
|
|
|
|
output = "DP";
|
|
|
|
}
|
|
|
|
{
|
|
|
|
workspace = "${i3.ws3}";
|
|
|
|
output = "HDMI";
|
|
|
|
}
|
|
|
|
{
|
|
|
|
workspace = "${i3.ws4}";
|
|
|
|
output = "DVI";
|
|
|
|
}
|
2023-07-14 21:25:55 +02:00
|
|
|
{
|
|
|
|
workspace = "${i3.ws5}";
|
|
|
|
output = [ "DVI" "HDMI" "DP" ];
|
|
|
|
}
|
2021-09-26 11:08:45 +02:00
|
|
|
];
|
2021-06-03 02:03:20 +02:00
|
|
|
};
|
2021-09-26 11:08:45 +02:00
|
|
|
|
|
|
|
nmt.script = ''
|
|
|
|
assertFileExists home-files/.config/sway/config
|
2022-07-07 19:03:58 +02:00
|
|
|
assertFileContent $(normalizeStorePaths home-files/.config/sway/config) \
|
2021-09-26 11:08:45 +02:00
|
|
|
${./sway-workspace-output-expected.conf}
|
|
|
|
'';
|
2021-06-03 02:03:20 +02:00
|
|
|
}
|