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

fix: cross-env needs to prefix all individual commands #1

Merged
merged 1 commit into from
Mar 9, 2016
Merged

fix: cross-env needs to prefix all individual commands #1

merged 1 commit into from
Mar 9, 2016

Conversation

kentcdodds
Copy link
Contributor

The problem is that each command separated by && is actually totally isolated from one another, so cross-env can't do anything about other isolated commands. So you need to prefix each one.

This is noted in the docs.

I'm sorry it took so long to get back to you.

mikechabot added a commit that referenced this pull request Mar 9, 2016
fix: cross-env needs to prefix all individual commands
@mikechabot mikechabot merged commit 2772e92 into mikechabot:master Mar 9, 2016
@bchenSyd
Copy link

bchenSyd commented Jan 1, 2018

I think it is doable..

on windows , set NODE_ENV=production&& task1 &&task2
and on linux, export NODE_ENV=production && task1 && task2

both task1 and task2 will have process.env.NODE_ENV setup as 'production'

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

Successfully merging this pull request may close these issues.

None yet

3 participants