File tree Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -233,11 +233,10 @@ def list_monitors(json_output: bool = False) -> None:
233
233
234
234
if json_output :
235
235
if has_descriptions :
236
- monitors_list_of_dict = [{'name' : name , 'desc ' : desc } for name , desc in monitor_names ]
236
+ monitors_list_of_dict = [{'name' : name , 'description ' : desc } for name , desc in monitor_names ]
237
237
else :
238
238
monitors_list_of_dict = [{'name' : name } for name , _ in monitor_names ]
239
-
240
- json .dump (monitors_list_of_dict , sys .stdout )
239
+ json .dump (monitors_list_of_dict , sys .stdout , indent = 2 , sort_keys = True )
241
240
print ()
242
241
return
243
242
@@ -255,9 +254,8 @@ def list_monitors(json_output: bool = False) -> None:
255
254
def _run_app (opts : Options , args : CLIOptions , bad_lines : Sequence [BadLine ] = (), talk_fd : int = - 1 ) -> None :
256
255
global _is_panel_kitten
257
256
_is_panel_kitten = run_app .cached_values_name == 'panel'
258
- if _is_panel_kitten and run_app .layer_shell_config and run_app .layer_shell_config .output_name in ['list' , 'listjson' ]:
259
- is_json_output = run_app .layer_shell_config .output_name == 'listjson'
260
- list_monitors (is_json_output )
257
+ if _is_panel_kitten and run_app .layer_shell_config and run_app .layer_shell_config .output_name in ('list' , 'listjson' ):
258
+ list_monitors (run_app .layer_shell_config .output_name == 'listjson' )
261
259
return
262
260
if is_macos :
263
261
global_shortcuts = set_cocoa_global_shortcuts (opts )
You can’t perform that action at this time.
0 commit comments