Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sdfmt: support stdin and stdout, together with --assume-filename #262

Open
JohanEngelen opened this issue May 6, 2023 · 3 comments
Open

Comments

@JohanEngelen
Copy link
Contributor

The feature request is to be able to input code via stdin, and then outputting to stdout.
Then for the style to be applied, one should be able to specify --assume-filename (by which then the normal config file lookup would be used).
Clang-format also has this --assume-filename option (https://clang.llvm.org/docs/ClangFormat.html).

@deadalnix
Copy link
Contributor

Sorry I missed this. I'd don't have the bandwidth to make this happen right now, but I'd be happy to assist and/or review any work done on that front. This seems like a good feature.

@JohanEngelen
Copy link
Contributor Author

response is appreciated, notifying contributors (e.g. me) that the work will not be in vain

@deadalnix
Copy link
Contributor

Definitively not, being able to format from stdin is a very useful feature. maybe even be the default if no file is specified on the command line?

I'd be happy to provide pointer through the codebase to do that, but for the most part this should probably happen in the driver for sdfmt or close by.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants