hyprwm / hyprland-wiki

The Hyprland Wiki Pages, automatically synced with the website.
BSD 3-Clause "New" or "Revised" License
237 stars 332 forks source link

Fix Nix Loop for Workspaces on Home Manager Page #514

Open anotherhadi opened 5 months ago

anotherhadi commented 5 months ago

The Nix loop for workspaces on the Home Manager page (https://wiki.hyprland.org/Nix/Hyprland-on-Home-Manager/) appears to be broken. Here's my corrected version:

      bind = [
           # ...
      ] ++ (
        # workspaces
        # binds $mod + [shift +] {1..10} to [move to] workspace {1..10}
        builtins.concatLists (builtins.genList (i:
          let ws = i + 1;
          in [
            "$mod, code:1${toString i}, workspace, ${toString ws}"
            "$mod SHIFT, code:1${toString i}, movetoworkspace, ${toString ws}"
          ]) 9));

Don't know if the issue was due to an older version of Hyprland, Is anyone else also using it in Home Manager?

vaxerski commented 5 months ago

@fufexan

fufexan commented 5 months ago

I'm still using the snippet in the wiki and it works fine. However, I haven't updated Hyprland in a few days. Perhaps something changed?