DankMaterialShell icon indicating copy to clipboard operation
DankMaterialShell copied to clipboard

Support wrapping the lock IPC command

Open bokicoder opened this issue 1 year ago • 4 comments

Feature Description

Although https://github.com/AvengeMedia/DankMaterialShell/commit/ce6c16214c00dad676227985b1278a7c1a5353c0 added support for custom lock commands, using dms ipc call lock lock in this context would apparently cause infinite recursion.

Use Case

niri msg action do-screen-transition; dms ipc call lock lock

Compositor

Is this feature specific to one compositor?

  • [x] All compositors
  • [ ] niri
  • [ ] Hyprland

bokicoder avatar Oct 19 '25 18:10 bokicoder

Should be solved 0cb081a6d0357fcac009039a6686eb988683e51d

bbedward avatar Oct 20 '25 03:10 bbedward

@bbedward It seems different from what I expected. The behavior I anticipated was that dms ipc call lock lock would equal niri msg action do-screen-transition; dms ipc call lock lock. Alternatively, how can I invoke my custom lock command externally?

bokicoder avatar Oct 20 '25 10:10 bokicoder

I see, to avoid the infinite recursion I figured the best was to exclude the ipc from the custom command. Since it was more geared to customize the UI behavior. For ipc I thought you'd just put the custom command as the keybind, anyway

bbedward avatar Oct 20 '25 12:10 bbedward

I see, to avoid the infinite recursion I figured the best was to exclude the ipc from the custom command.

You have resolved the infinite recursion issue. I can now wrap the lock IPC command using the custom lock command approach.

For ipc I thought you'd just put the custom command as the keybind, anyway

Now it's just a matter of external invocation. But as you mentioned, I can simply assign the custom command to the keybind.

bokicoder avatar Oct 20 '25 13:10 bokicoder