Commit graph

5 commits

Author SHA1 Message Date
Peter Hutterer
4d058bc2b0 tools - tweak-device: revamp to reduce use of globals
Make the code base a bit more modular so it's easier to add new commands.
Main change here is: options are parsed twice now, first time for the mode
(abs/led) and the device path, then again for the mode-specific options.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
2015-07-01 11:59:04 +10:00
Peter Hutterer
c8a557fc9b tools - tweak-device: fix wrong error message if the LED doesn't exist
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2015-06-29 12:12:39 +10:00
Peter Hutterer
269584b1b5 tools - tweak-device: close the fd on exit
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2015-06-29 12:12:39 +10:00
Peter Hutterer
4160d94baf cosmetic: fix a couple of duplicate/missing empty lines
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2015-03-04 08:41:33 +10:00
Peter Hutterer
3bf7d50230 tools: add a tool to change kernel devices
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2015-02-04 11:02:02 +10:00