FnLock switch for Lenovo ThinkPad Compact USB and Lenovo ThinkPad Trackpoint Keyboard II (wireless / Bluetooth) keyboards
Note: Binary files aren't shown on the web site. To see all files, please download the extension zipfile.
Version | Status |
---|---|
16 | Active |
15 | Active |
14 | Active |
13 | Active |
12 | Active |
11 | Active |
10 | Active |
9 | Rejected |
8 | Active |
7 | Active |
6 | Active |
5 | Active |
4 | Active |
3 | Active |
2 | Active |
1 | Active |
What's the reason for using `cat` over [GLib.file_get_contents](https://gjs-docs.gnome.org/glib20~2.0/glib.file_get_contents)? If that can be done in gjs, it shouldn't be via spawn command.
The reason for using cat is mostly for simplicity. Each time keyboard plugged in it has new fn_lock file path. For example: plug in the keyboard first time, and the current fn_lock file path is: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-3/1-3:1.1/0003:17EF:6047.001F/fn_lock. unplug and plug in it again and then it is: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-3/1-3:1.1/0003:17EF:6047.0021/fn_lock. With 'cat /sys/bus/hid/devices/*17EF:604*/fn_lock' there is no need to track fn_lock file paths. There might be a solution with udev symlink rules though, but I didn't make it work for some reason.