I found myself needing to add environment variables for CMake. We could add another parameter, like has been done for timeout, but we could just return the CreateProcess<> and let the developer do what they like with it.
cc @ziadadeela, contributor to Fake.Build.CMake.
I don't know:
if it's okay to break the contract while v6 is in alpha
Should we accept this proposal?
For:
allows developers control the creation of the process
the developer can decide how to handle errors
...
Against:
breaks encapsulation of how CMake is run (it exposes that we're using CreateProcess)
the developer may not know what to do with a CreateProcess<> (they need to call Proc.run themselves)
...
If we accept this proposal,
should we remove the timeout parameter and let callers add CreateProcess.withTimeout timeout themselves?
should we remove the working directory and let callers add CreateProcess.withWorkingDirectory binaryDir themselves?
TODO
Feel free to open the PR and ask for help
[ ] New (API-)documentation for new features exist (Note: API-docs are enough, additional docs are in help/markdown)
[ ] unit or integration test exists (or short reasoning why it doesn't make sense)
[ ] boy scout rule: "leave the code behind in a better state than you found it" (fix warnings, obsolete members or code-style in the places you worked in)
[ ] (if new module) the module has been linked from the "side navigation" menu, edit docs/data.json.
[ ] (if new module) the module is in the correct namespace.
[ ] (if new module) the module is added to Fake.sln (dotnet sln Fake.sln add src/app/Fake.*/Fake.*.fsproj)
Description
WIP
I found myself needing to add environment variables for CMake. We could add another parameter, like has been done for
timeout
, but we could just return theCreateProcess<>
and let the developer do what they like with it.cc @ziadadeela, contributor to Fake.Build.CMake.
I don't know:
Should we accept this proposal? For:
Against:
CreateProcess
)CreateProcess<>
(they need to callProc.run
themselves)If we accept this proposal,
CreateProcess.withTimeout timeout
themselves?CreateProcess.withWorkingDirectory binaryDir
themselves?TODO
Feel free to open the PR and ask for help
[ ] New (API-)documentation for new features exist (Note: API-docs are enough, additional docs are in
help/markdown
)[ ] unit or integration test exists (or short reasoning why it doesn't make sense)
[ ] boy scout rule: "leave the code behind in a better state than you found it" (fix warnings, obsolete members or code-style in the places you worked in)
[ ] (if new module) the module has been linked from the "side navigation" menu, edit
docs/data.json
.[ ] (if new module) the module is in the correct namespace.
[ ] (if new module) the module is added to Fake.sln (
dotnet sln Fake.sln add src/app/Fake.*/Fake.*.fsproj
)[ ] Fake API guideline is honored