diff options
author | Yu Watanabe <watanabe.yu+github@gmail.com> | 2024-05-13 12:50:04 +0200 |
---|---|---|
committer | Luca Boccassi <luca.boccassi@gmail.com> | 2024-05-13 15:18:37 +0200 |
commit | 0831c99104dccbfde54ae76c4e229613e65fa0b0 (patch) | |
tree | 15ed77d4440ca4e0850600ae9667882537295403 | |
parent | Merge pull request #32758 from yuwata/journal-ratelimit (diff) | |
download | systemd-0831c99104dccbfde54ae76c4e229613e65fa0b0.tar.xz systemd-0831c99104dccbfde54ae76c4e229613e65fa0b0.zip |
hwdb: ID_INPUT_XYZ allows an empty string
This is for making CIs for #32775 green.
-rwxr-xr-x | hwdb.d/parse_hwdb.py | 27 |
1 files changed, 14 insertions, 13 deletions
diff --git a/hwdb.d/parse_hwdb.py b/hwdb.d/parse_hwdb.py index 30d5f8a569..4c970dcbc8 100755 --- a/hwdb.d/parse_hwdb.py +++ b/hwdb.d/parse_hwdb.py @@ -145,6 +145,7 @@ def property_grammar(): mount_matrix_row = SIGNED_REAL + ',' + SIGNED_REAL + ',' + SIGNED_REAL mount_matrix = Group(mount_matrix_row + ';' + mount_matrix_row + ';' + mount_matrix_row)('MOUNT_MATRIX') xkb_setting = Optional(Word(alphanums + '+-/@._')) + id_input_setting = Optional(Or((Literal('0'), Literal('1')))) # Although this set doesn't cover all of characters in database entries, it's enough for test targets. name_literal = Word(printables + ' ') @@ -159,19 +160,19 @@ def property_grammar(): ('ID_AV_PRODUCTION_CONTROLLER', Or((Literal('0'), Literal('1')))), ('ID_PERSIST', Or((Literal('0'), Literal('1')))), ('ID_PDA', Or((Literal('0'), Literal('1')))), - ('ID_INPUT', Or((Literal('0'), Literal('1')))), - ('ID_INPUT_ACCELEROMETER', Or((Literal('0'), Literal('1')))), - ('ID_INPUT_JOYSTICK', Or((Literal('0'), Literal('1')))), - ('ID_INPUT_KEY', Or((Literal('0'), Literal('1')))), - ('ID_INPUT_KEYBOARD', Or((Literal('0'), Literal('1')))), - ('ID_INPUT_MOUSE', Or((Literal('0'), Literal('1')))), - ('ID_INPUT_POINTINGSTICK', Or((Literal('0'), Literal('1')))), - ('ID_INPUT_SWITCH', Or((Literal('0'), Literal('1')))), - ('ID_INPUT_TABLET', Or((Literal('0'), Literal('1')))), - ('ID_INPUT_TABLET_PAD', Or((Literal('0'), Literal('1')))), - ('ID_INPUT_TOUCHPAD', Or((Literal('0'), Literal('1')))), - ('ID_INPUT_TOUCHSCREEN', Or((Literal('0'), Literal('1')))), - ('ID_INPUT_TRACKBALL', Or((Literal('0'), Literal('1')))), + ('ID_INPUT', id_input_setting), + ('ID_INPUT_ACCELEROMETER', id_input_setting), + ('ID_INPUT_JOYSTICK', id_input_setting), + ('ID_INPUT_KEY', id_input_setting), + ('ID_INPUT_KEYBOARD', id_input_setting), + ('ID_INPUT_MOUSE', id_input_setting), + ('ID_INPUT_POINTINGSTICK', id_input_setting), + ('ID_INPUT_SWITCH', id_input_setting), + ('ID_INPUT_TABLET', id_input_setting), + ('ID_INPUT_TABLET_PAD', id_input_setting), + ('ID_INPUT_TOUCHPAD', id_input_setting), + ('ID_INPUT_TOUCHSCREEN', id_input_setting), + ('ID_INPUT_TRACKBALL', id_input_setting), ('ID_SIGNAL_ANALYZER', Or((Literal('0'), Literal('1')))), ('POINTINGSTICK_SENSITIVITY', INTEGER), ('ID_INPUT_JOYSTICK_INTEGRATION', Or(('internal', 'external'))), |