Hello, I'm quite new to Switch.
I created a command line tool to prepare some files, since we don't have the scripting package I simply used Node.js as tool and passed it my script.
My tool writes to the output file correctly when there are no problems, but writes to stderr when there are errors. How do I read from stderr and maybe generate some log file?
how to read stderr with the execute command tool
-
- Newbie
- Posts: 8
- Joined: Fri Feb 26, 2016 5:04 pm
Re: how to read stderr with the execute command tool
I don't think you can, but check messages anyway. You can fail if it finds anything in stderr but I don't think you can check the result of stderr in that configurator. I also work with Switch and Node and I can tell you, even though it is much easier to write code in Node, having the ability to drive that code from within the Switch Scripter is very helpful.
Free Switch scripts: open-automation @ GitHub
Free Switch apps: open-automation @ Enfocus appstore
Want to hire me? I'm looking for my next gig. Contact me on LinkedIn or via email.
Free Switch apps: open-automation @ Enfocus appstore
Want to hire me? I'm looking for my next gig. Contact me on LinkedIn or via email.
-
- Newbie
- Posts: 8
- Joined: Fri Feb 26, 2016 5:04 pm
Re: how to read stderr with the execute command tool
Thank you for your answer! I already changed my strategy, basically outputting to a different file on error (instead of stderr). Not the same but it works!
Cheers!
Cheers!