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

initCommands result validation #19

Open
dchekanov opened this issue Dec 30, 2020 · 3 comments
Open

initCommands result validation #19

dchekanov opened this issue Dec 30, 2020 · 3 comments

Comments

@dchekanov
Copy link

Hi and thanks for open-sourcing this module!

It would be great to be able to get results of initCommands execution - to check for errors and throw if something is not right (if there's a message in stderr, for example).

@bitsofinfo
Copy link
Owner

@dchekanov if you want to submit that in a PR I can build/tag and push it. I just don't have time to code it at the moment. Or maybe @nfedyk could do it.

@dchekanov
Copy link
Author

I was able to inject a function to validate initCommands results. However, stderr for basic bash commands like >&2 echo "error" or err is empty. The expected stderr content ("error"/"bash: err: command not found") appears in the next command result instead for some reason, and it's deeper than I'd like to go at the moment. With pwsh it seem to work fine for post-init commands, and that's enough in our case. I'll submit a PR if our requirements change and I end up patching the library.

@bitsofinfo
Copy link
Owner

hmm odd, yeah if you have anything to add, most welcome! thanks!

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