hk util mixed-line-ending
- Usage:
hk util mixed-line-ending [-d --diff] [-f --fix] <FILES>… - Effect: modifies state
Detect and fix mixed line endings
Fixing normalizes every line to the file's most frequent ending, or LF when LF and CRLF are tied. A lone CR is left alone.
Arguments
<FILES>…— Files to check or fix
Flags
-d --diff— Output a diff of the change. Cannot use withfix.-f --fix— Fix mixed line endings by normalizing to the most frequent one (LF on a tie)-h --help— Print help
Examples
Check for mixed line endings, or normalize them to the most frequent one.
sh
hk util mixed-line-ending README.md
hk util mixed-line-ending --fix README.mdLearn more
Built-in linters and utilities · Troubleshooting · All commands
