dioxus icon indicating copy to clipboard operation
dioxus copied to clipboard

formatter read from stdin and print to stdout

Open Dangerise opened this issue 2 years ago • 3 comments

Specific Demand

I'm using helix editor which require formatter to read the source file from stdin and print the result to stdout

My discussion on Helix Editor

Dangerise avatar Feb 02 '24 13:02 Dangerise

That was added in https://github.com/DioxusLabs/dioxus/pull/1529. You can use dx fmt -f - to format code from stdin

ealmloff avatar Feb 02 '24 13:02 ealmloff

@ealmloff log will be printed to stdout, how to disable it ?

Dangerise avatar Feb 02 '24 14:02 Dangerise

@ealmloff log will be printed to stdout, how to disable it ?

What log are you getting? I don't get any extra logs running this command:

echo "rsx\!{div{}}" | dx fmt -f -

You can change the log level with the DIOXUS_LOG environment variable. Error is the level with only the most critical logs:

export DIOXUS_LOG=error

ealmloff avatar Feb 05 '24 13:02 ealmloff