mirror of
https://github.com/vlang/v.git
synced 2025-09-18 11:56:57 -04:00
v.help: update help for fmt
(#21430)
This commit is contained in:
parent
ee22dcb0f6
commit
5b9ffe0070
@ -16,7 +16,7 @@ Options:
|
|||||||
-diff Display the differences between the formatted source(s)
|
-diff Display the differences between the formatted source(s)
|
||||||
and the original source(s). This will attempt to find a
|
and the original source(s). This will attempt to find a
|
||||||
working `diff` command automatically unless you specify one
|
working `diff` command automatically unless you specify one
|
||||||
with the VDIFF_TOOL environment variable.
|
with the VDIFF_CMD environment variable.
|
||||||
|
|
||||||
-l List files whose formatting differs from vfmt.
|
-l List files whose formatting differs from vfmt.
|
||||||
|
|
||||||
@ -33,11 +33,7 @@ Options:
|
|||||||
checking code contributions in CI for example.
|
checking code contributions in CI for example.
|
||||||
|
|
||||||
Environment Variables:
|
Environment Variables:
|
||||||
VDIFF_TOOL A command-line tool that will be executed with the original
|
VDIFF_CMD A custom tool and options that will be used for viewing the
|
||||||
file path and a temporary formatted file path as arguments.
|
differences between the original and the temporarily formatted
|
||||||
e.g. `VDIFF_TOOL=opendiff v fmt -diff path/to/file.v` will
|
files, e.g.: `VDIFF_CMD="diff -y -W 100" v fmt -diff path/file.v`
|
||||||
become: opendiff path/to/file.v /tmp/v/vfmt_file.v
|
|
||||||
|
|
||||||
VDIFF_OPTIONS A set of command-line options to be sent immediately after
|
|
||||||
the `diff` command. e.g. VDIFF_OPTIONS="-W 80 -y"
|
|
||||||
v fmt -diff path/to/file.v /tmp/v/vfmt_file.v
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user