conda / constructor

tool for creating installers from conda packages
https://conda.github.io/constructor/
Other
453 stars 166 forks source link

Windows: output to stdout during command line installation #764

Open marcoesters opened 4 months ago

marcoesters commented 4 months ago

Checklist

What is the idea?

While a decision has not been made about a replacement for NSIS (#646), it might be worth exploring adding stdout output to the Windows command line installer.

This could be a good start: https://forums.winamp.com/forum/developer-center/nsis-discussion/261756-write-to-command-line-when-silent#post3290436

Why is this needed?

There is currently no way to debug failures in command line installers. Using log files causes other issues (e.g., writing outside the installation directory with GUI installers when the "Browse..." button is clicked).

What should happen?

There should be an additional flag that allows users to output to stdout (or suppress output to stdout).

Additional Context

No response

jaimergp commented 1 month ago

I saw there are a few examples in Github if we search for System::Call 'kernel32::AttachConsole. The most complete examples seem to be:

So I think we won't be able to forward every message from NSIS to stdout, but we can definitely print our custom messages to stdout there.