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

Use cross-env to make yarn start work for Windows #170

Merged

Conversation

JohnHKoh
Copy link
Contributor

@JohnHKoh JohnHKoh commented Mar 2, 2021

The {KEY}={VALUE} syntax used to set environment variables does not work for Windows. Instead, the set keyword must be used as such: set PORT=3020. Instead of having 2 start scripts (like yarn start and yarn start-windows) to account for this difference, we can use cross-env to have a single start command without worrying about the operating system.

@vercel
Copy link

vercel bot commented Mar 2, 2021

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/downforacross/downforacross.com/4KCusSWVmzigVFtsiVvQQguTQCUd
✅ Preview: https://downforacrossc-git-fork-johnhkoh-johnhkoh-yarn-start-win-8a34bc.vercel.app

@stevenhao
Copy link
Member

sounds good! i noticed cross-env is in maintenance mode, but i suppose that's not a problem for us since we're only using it in a very basic way

@stevenhao stevenhao merged commit 0d18fde into downforacross:master Mar 2, 2021
@JohnHKoh
Copy link
Contributor Author

JohnHKoh commented Mar 2, 2021

sounds good! i noticed cross-env is in maintenance mode, but i suppose that's not a problem for us since we're only using it in a very basic way

Yes, as per their note here the package still should be updated with necessary bug fixes or critical security updates, so hopefully it shouldn't be an issue.

@JohnHKoh JohnHKoh deleted the johnhkoh/yarn-start-windows branch March 2, 2021 03:19
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

2 participants