Open doozMen opened 1 month ago
Synced to Apple’s issue tracker as rdar://136347689
This could also serve as an enabler for the command-line tool for getting a future extension to pass the config as a string inline, like clang-format's --style="{key: value, ...}"
👍
Which version of the swift-format package are you using? This was added in https://github.com/swiftlang/swift-format/pull/634, so it should be available in the 6.0 release.
This could also serve as an enabler for the command-line tool for getting a future extension to pass the config as a string inline, like clang-format's
--style="{key: value, ...}"
👍
The PR above also added this. We should probably update the README to reflect that, instead of just the argument help text.
Hei I'm using, and loving, the formatting tool inside my code generator. I embed the config json file into the code as it is a cli tool that runs on linux. This means in my package manifest i use
resources: [.embedInCode(swift_format.json)]
which would not produce a url but data.As the
let config = try Configuration(contentsOf: url)
only accepts an url would it be ok to make a PR and add an init that accepts data?My current workaround is to create a temporary file but that seams like inefficient.