mirror of
https://github.com/shelljs/shelljs.git
synced 2026-01-18 16:03:37 +00:00
No change to logic. This refactors the exec-child.js script to move all of its main logic into a main() function. This function is only invoked if the script is executed, not when it is imported. Importing the script is now a NOOP instead of throwing an exception. It's still not advisable to import the script, however this can be done if absolutely necessary to trick JavaScript bundlers which try to prune non-imported code files. Partially related to issue #1160 and #1172.