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

Make "npm run dev" work also on Windows #221

Merged

Conversation

acataluddi
Copy link

It's impossible to launch the npm run dev on Windows as the following command fails:

NODE_ENV=development rollup -c example/rollup.config.js --watch

We integrated the win-node-env to work around this problem. As a result the npm run dev is now cross-platform.

@acataluddi acataluddi changed the title Make "npm run dev" works also on windows Make "npm run dev" work also on Windows Sep 4, 2020
@coveralls
Copy link

coveralls commented Sep 4, 2020

Coverage Status

Coverage remained the same at 100.0% when pulling a270404 on metagusto:make-scripts-cross-platform into a9d7788 on i-like-robots:master.

@i-like-robots
Copy link
Owner

Thanks for bringing this to my attention @acataluddi but I believe this can actually be solved without any other tools! Fortunately Rollup supports an --environment flag which allows environment variables to be set like so:

rollup --environment=NODE_ENV:development

Would you mind testing this and letting me know if this works/amend the PR?

@acataluddi
Copy link
Author

Would you mind testing this and letting me know if this works/amend the PR?

Sure, we'll try this on Windows and let you know (cc: @aDeveloperCase)

@acataluddi
Copy link
Author

Hi Matt,

it seems to work well. Please, review the updated branch.

Best regards,
Adriano C.

@i-like-robots i-like-robots merged commit 22dfa23 into i-like-robots:master Sep 10, 2020
@i-like-robots
Copy link
Owner

Thanks!

@acataluddi
Copy link
Author

Thanks to you Matt, much appreciated.

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

4 participants