For sure: https://gitlab.com/joneshf/purty/snippets/1714537
You can use that in at least a few ways:
-
Download the file and use it locally. Probably the most straight forward way to do it. Your .purty.dhall file would look like this:
{ formatting =
< Static = {=} | Dynamic : {} >
, verbosity =
< NotVerbose = {=} | Verbose : {} >
, output =
< StdOut = {=} | InPlace : {} >
}
-
Import it in the .purty.dhall file:
https://gitlab.com/joneshf/purty/snippets/1714537/raw
That can be the entire .purty.dhall file. Dhall will handle importing it and making everything work.
-
Import it in the .purty.dhall file and verify the contents of the file:
https://gitlab.com/joneshf/purty/snippets/1714537/raw sha256:c667e904ad11deb56534b3156ead983a59def3533d5766fcdad37fd6a4390f86
The sha256:c667e904ad11deb56534b3156ead983a59def3533d5766fcdad37fd6a4390f86 part forces dhall to verify the integrity of the import. That’s maybe a saner move than the previous suggestion.
-
Use it as a base to extend the configuration:
let defaultConfig =
https://gitlab.com/joneshf/purty/snippets/1714537/raw sha256:c667e904ad11deb56534b3156ead983a59def3533d5766fcdad37fd6a4390f86
in defaultConfig ⫽ { verbosity = < Verbose = {=} | NotVerbose : {} > }
The // operator combines records. It prefers fields from the right record over the left record.
Let me know if that all makes sense.
I’ll try to make config easier in the future.
Not yet, but I’ll add it.