fix(minecraft): check gui condition in home
This commit is contained in:
parent
7c826861db
commit
d9dba8b68a
|
@ -2,15 +2,15 @@
|
||||||
, lib
|
, lib
|
||||||
, config
|
, config
|
||||||
, ... }: with lib; let
|
, ... }: with lib; let
|
||||||
|
inherit (config.passthrough) gui;
|
||||||
cfg = config.passthrough.minecraft;
|
cfg = config.passthrough.minecraft;
|
||||||
enable = cfg.enable && config.home.username == "minecraft";
|
enable = cfg.enable && config.home.username == "minecraft";
|
||||||
in mkIf enable {
|
in mkIf enable {
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
prismlauncher
|
|
||||||
jdk8
|
jdk8
|
||||||
];
|
] ++ optional gui prismlauncher;
|
||||||
|
|
||||||
wayland.windowManager.sway.config.window.commands = [
|
wayland.windowManager.sway.config.window.commands = mkIf gui [
|
||||||
{ criteria.app_id = "org.prismlauncher.PrismLauncher"; command = "floating enable"; }
|
{ criteria.app_id = "org.prismlauncher.PrismLauncher"; command = "floating enable"; }
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue