setledsmac icon indicating copy to clipboard operation
setledsmac copied to clipboard

Karabiner + setledsmac

Open wallneradam opened this issue 2 years ago • 3 comments

I read the issue #7, and found a workaround to that.

There were an answer suggesting to kill Karabiner then restart it (https://github.com/damieng/setledsmac/issues/7#issuecomment-375844299) . I found that you can disable a device in Karabiner without killing it, under Devices tab. After that you can simply use setledsmac, then you can turn tis settings back immediately.

Also found that, this is easily scriptable, because you can change this setting in ~/.config/karabiner/karabiner.json . You can iterate /profiles/devices and check ./identifiers/product_id/vendor_id to find the device settings. If you found that, you can set ./ignore to true, use setleds, then set back to false. The file is processed by Karabiner automatically, no need to run any command.

I think this could be part of setledsmac, because Karabiner is essential to make numlock function works on external keyboars.

wallneradam avatar Jan 31 '22 16:01 wallneradam

I'd be open to a pull request but given I haven't even powered on a Mac in months it's definitely not something I would tackle myself these days.

damieng avatar Jan 31 '22 19:01 damieng

I read the issue #7, and found a workaround to that.

There were an answer suggesting to kill Karabiner then restart it (#7 (comment)) . I found that you can disable a device in Karabiner without killing it, under Devices tab. After that you can simply use setledsmac, then you can turn tis settings back immediately.

Also found that, this is easily scriptable, because you can change this setting in ~/.config/karabiner/karabiner.json . You can iterate /profiles/devices and check ./identifiers/product_id/vendor_id to find the device settings. If you found that, you can set ./ignore to true, use setleds, then set back to false. The file is processed by Karabiner automatically, no need to run any command.

I think this could be part of setledsmac, because Karabiner is essential to make numlock function works on external keyboars.

I found that Karabiner allows to switch profile from command line. So you can create a new profile without selecting your keywoard and use '/Library/Application Support/org.pqrs/Karabiner-Elements/bin/karabiner_cli' --select-profile 'Default Profile' to switch back and forth.

superkeyor avatar Nov 12 '22 20:11 superkeyor

I knew I'd seen this suggestion somewhere. I have packed all this up in to a zip and included instructions how to use here. It is a fork of this repo, so happy to make a pull request, but there are a lot of additional instructions for getting Karabiner to use the shell script - i.e. the readme now focusses solely on that.

judge2005 avatar Feb 08 '24 15:02 judge2005