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

Environment argument for ExecTask is broken for windows #1417

Closed
siad007 opened this issue Oct 15, 2020 · 4 comments · Fixed by #1419
Closed

Environment argument for ExecTask is broken for windows #1417

siad007 opened this issue Oct 15, 2020 · 4 comments · Fixed by #1419

Comments

@siad007
Copy link
Member

siad007 commented Oct 15, 2020

@mrook please revert the changes from #1396, which breaks the function on windows!
It would be better to support multiple env vars for all platforms, if this is not possible, we should consider to document a working alternative like:

<exec executable="sh" outputProperty="outputProperty">
    <arg value="-c"/>
    <arg value="export HELLO=hello; export WORLD=world; php -r &quot;var_dump(\$_ENV);&quot;"/>
</exec>
<echo msg="${outputProperty}"/>

$envString .= 'export ' . $variable . '; ';

@mrook
Copy link
Member

mrook commented Oct 15, 2020

Reverted. We should probably add a test for Windows then, as all the tests were passing.

@siad007
Copy link
Member Author

siad007 commented Oct 15, 2020 via email

@mrook
Copy link
Member

mrook commented Oct 15, 2020

Ah I see, missed that.

@siad007
Copy link
Member Author

siad007 commented Oct 15, 2020

Thanks!

@siad007 siad007 closed this as completed Oct 15, 2020
@mrook mrook linked a pull request Dec 23, 2020 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging a pull request may close this issue.

2 participants