Skip to main content

Module main

Module main 

Source
Expand description

Port of ktfmt’s cli/Main.kt (v0.64): formats files in place (in parallel) or stdin to stdout. Messages, exit codes and write decisions match ktfmt’s (tools/ktfmt-oracle/cli-diff.sh). Deviation: each file’s messages are printed in file order, not in completion order.

Structs§

Main

Functions§

expand_args_to_file_names
expandArgsToFileNames expands args to a list of .kt files to format: a lone file as is, otherwise every .kt/.kts file under each argument, in directory order (sorted here).