Compare commits

..

No commits in common. "6bbeef204252f15382d0b6cad60e37b9f879caa4" and "a25457f5b7689265bd2235c4da218896e7c5c1d0" have entirely different histories.

4 changed files with 20 additions and 36 deletions

2
TODO
View File

@ -556,6 +556,8 @@ Features:
* as soon as we have sender timestamps, revisit coalescing multiple parallel daemon reloads:
http://lists.freedesktop.org/archives/systemd-devel/2014-December/025862.html
* in systemctl list-unit-files: show the install value the presets would suggest for a service in a third column
* figure out when we can use the coarse timers
* add "systemctl start -v foobar.service" that shows logs of a service

View File

@ -973,16 +973,16 @@ evdev:input:b0003v046Dp00FE*
KEYBOARD_KEY_c1018=media # Media button
# MX5000 keyboard (HID proxy mode and bluetooth matches)
# The 4 buttons below the LCD send codes 0xc100c - 0xc100f. They only send
# these codes when the LCD is displaying text send to it. These codes are
# directly consumed by recent versions of lcdproc when it is driving the LCD,
# so these codes should not be mapped
evdev:input:b0003v046DpB305*
evdev:input:b0005v046DpB305*
KEYBOARD_KEY_c0230=zoomreset # HUT says fullscreen, kbd says 100%
KEYBOARD_KEY_c1004=send # Send and receive / sync button
KEYBOARD_KEY_c1006=coffee # Status (online/away) button
KEYBOARD_KEY_c1007=camera # Webcam button
KEYBOARD_KEY_c100c=kbd_lcd_menu1 # 1st button below the builtin LCD
KEYBOARD_KEY_c100d=kbd_lcd_menu4 # 4th button below the builtin LCD
KEYBOARD_KEY_c100e=kbd_lcd_menu2 # 2nd button below the builtin LCD
KEYBOARD_KEY_c100f=kbd_lcd_menu3 # 3th button below the builtin LCD
KEYBOARD_KEY_c1038=prog1 # Smartkey A → XF86Launch1
KEYBOARD_KEY_c1039=prog2 # Smartkey B → XF86Launch2
KEYBOARD_KEY_c103a=prog3 # Smartkey C → XF86Launch3

View File

@ -196,10 +196,9 @@ def check_one_mount_matrix(prop, value):
def check_one_keycode(prop, value):
if value != '!' and ecodes is not None:
key = 'KEY_' + value.upper()
if not (key in ecodes or
value.upper() in ecodes or
# new keys added in kernel 5.5
'KBD_LCD_MENU' in key):
if key not in ecodes:
key = value.upper()
if key not in ecodes:
error('Keycode {} unknown', key)
def check_properties(groups):

View File

@ -1436,12 +1436,11 @@ static bool output_show_unit_file(const UnitFileList *u, char **states, char **p
}
static void output_unit_file_list(const UnitFileList *units, unsigned c) {
unsigned max_id_len, id_cols, state_cols, preset_cols;
unsigned max_id_len, id_cols, state_cols;
const UnitFileList *u;
max_id_len = STRLEN("UNIT FILE");
state_cols = STRLEN("STATE");
preset_cols = STRLEN("VENDOR PRESET");
for (u = units; u < units + c; u++) {
max_id_len = MAX(max_id_len, strlen(basename(u->path)));
@ -1459,18 +1458,15 @@ static void output_unit_file_list(const UnitFileList *units, unsigned c) {
id_cols = max_id_len;
if (!arg_no_legend && c > 0)
printf("%s%-*s %-*s %-*s%s\n",
printf("%s%-*s %-*s%s\n",
ansi_underline(),
id_cols, "UNIT FILE",
state_cols, "STATE",
preset_cols, "VENDOR PRESET",
ansi_normal());
for (u = units; u < units + c; u++) {
const char *on_underline = NULL, *on_unit_color = NULL, *id;
const char *on_preset_color = NULL, *off_preset = NULL, *unit_preset_str;
const char *on_underline = NULL, *on_color = NULL, *off = NULL, *id;
_cleanup_free_ char *e = NULL;
int r;
bool underline;
underline = u + 1 < units + c &&
@ -1484,34 +1480,21 @@ static void output_unit_file_list(const UnitFileList *units, unsigned c) {
UNIT_FILE_MASKED_RUNTIME,
UNIT_FILE_DISABLED,
UNIT_FILE_BAD))
on_unit_color = underline ? ansi_highlight_red_underline() : ansi_highlight_red();
on_color = underline ? ansi_highlight_red_underline() : ansi_highlight_red();
else if (u->state == UNIT_FILE_ENABLED)
on_unit_color = underline ? ansi_highlight_green_underline() : ansi_highlight_green();
on_color = underline ? ansi_highlight_green_underline() : ansi_highlight_green();
if (on_underline || on_color)
off = ansi_normal();
id = basename(u->path);
r = unit_file_query_preset(arg_scope, NULL, id);
if (r < 0) {
unit_preset_str = "n/a";
on_preset_color = underline ? on_underline : ansi_normal();
} else if (r == 0) {
unit_preset_str = "disabled";
on_preset_color = underline ? ansi_highlight_red_underline() : ansi_highlight_red();
} else {
unit_preset_str = "enabled";
on_preset_color = underline ? ansi_highlight_green_underline() : ansi_highlight_green();
}
if (on_underline || on_preset_color)
off_preset = ansi_normal();
e = arg_full ? NULL : ellipsize(id, id_cols, 33);
printf("%s%-*s %s%-*s %s%-*s%s\n",
printf("%s%-*s %s%-*s%s\n",
strempty(on_underline),
id_cols, e ? e : id,
strempty(on_unit_color), state_cols, unit_file_state_to_string(u->state),
strempty(on_preset_color), preset_cols, unit_preset_str, strempty(off_preset));
strempty(on_color), state_cols, unit_file_state_to_string(u->state), strempty(off));
}
if (!arg_no_legend)