fixes
This commit is contained in:
@@ -1,7 +1,21 @@
|
||||
{ lib, config, pkgs, ... }: {
|
||||
{ lib, config, pkgs, ... }:
|
||||
let
|
||||
openOnCurrentScreen = pkgs.writeShellScriptBin "eww-open-on-current-screen" ''
|
||||
window="$1"
|
||||
shift
|
||||
|
||||
screen="$(hyprctl monitors -j | ${lib.getExe pkgs.jq} -r '.[] | select(.focused == true) | .name' | head -n1)"
|
||||
|
||||
if [ -n "$screen" ]; then
|
||||
exec ${lib.getExe pkgs.eww} open "$window" --screen "$screen" "$@"
|
||||
fi
|
||||
|
||||
exec ${lib.getExe pkgs.eww} open "$window" "$@"
|
||||
'';
|
||||
in {
|
||||
|
||||
config = lib.mkIf (config.usercfg.wm == "Wayland") {
|
||||
home.packages = with pkgs; [ eww jq jaq custom.amdgpu_top ];
|
||||
home.packages = with pkgs; [ eww jq jaq custom.amdgpu_top openOnCurrentScreen ];
|
||||
|
||||
xdg.configFile."eww" = {
|
||||
source = lib.cleanSourceWith {
|
||||
|
||||
Reference in New Issue
Block a user