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
CLI Error: react-static-create(1) does not exist #807
Comments
If I uninstall the global package with yarn and reinstall it with npm it's worst, because I see the package installed doing a
but if I run
it doesn't find the command. |
I tried cleaning the yarn cache and reinstalling, but I receive the same error as before:
|
This sounds a lot like: |
Yes, thank you for pointing me.
|
Ok, I confirm that it is a problem with yarn 1.10.x and also npm... |
I'll see if I can replicate the issue so we can know if it is caused by yarn/npm or some weird issue in our setup. |
Am unable to reconfirm this bug with npm or yarn so far... I'll try on my work computer tomorrow but I'm afraid it seems to env-specific. |
I had the issue but seemed to be related to where bin was pointing with |
Couldn't reproduce this on a new computer without pre-existing npm/yarn installs. :/ |
Thank you, so I think it's a problem with my environment. |
I have the exact same problem. I have
This is not a problem with yarn 1.9 because it directly links from Not sure who's to blame here? |
I have the same problem.. I also have found a workaround/resolution It seems that it is indeed due to the installed symlink pointing to a relative path that is breaking as Environment$ lsb_release -ds && uname -rv && node -v && yarn -v && react-static -V
Ubuntu 17.10
4.13.0-46-generic #51-Ubuntu SMP Tue Jun 12 12:36:29 UTC 2018
v8.12.0
1.12.3
5.9.12 ReproduceRemove the global package
Check it is no longer available
Above should have no output Add the global package
Check it is now available
Above should have output pointing to something like Try to create a project
Above fails with Check the command
Above outputs something like Note the Try using the command directly; so the command the symlink points to
The above works..
Workaround/SolutionMake the symlink absolute
Outputs: The symlink is now absolute and the command works ;-) react-static create
@tannerlinsley postinstall hook? as it seems to be a problem with the |
I'm having this issue as well, trying to switch from Gatsby to React-Static but can't even get a basic project off the ground. Anybody find a solution to this bug? |
@luskin a useable (sic) workaround is to make the symlink absolute
Above works on linux based systems. osx, afaik, does not support Let me know if you get it working using this... Note: on an update of |
@luskin And to make @AubreyHewes' workaround work on macOS, you have to first run brew install coreutils and then you can run the same command but with |
yeah why is this closed... still happening. thanks for the workaround @luskin |
This is not 100% reproducible and might be caused by your local setup. |
I tried to reproduce this on 4 separate devices. 2 of them who never had react-static on it. Tried it with both yarn & npm as well... |
The root of the problem appears to be with Yarn, and not React Static. Per yarnpkg/yarn#648 (as mentioned in #789), Yarn has longstanding issues with global packages, such as installing to undesirable locations (particularly with nvm) and not linking. Reinstalling @Pixelatex, would you be willing to get fixes in for the Quick Start docs with a warning about using |
Describe the bug
The CLI command
react-static create
shows an error.
To Reproduce
I just installed react-static globally using
yarn global add react-static
(latest version of yarn 1.10.1)If I launch
react-static create
I receive the error
error: react-static-create(1) does not exist, try --help
The help command is the only which works.
I'm using Node 10.9.0 on a Mac with MacOS Sierra 10.12.6.
I fear it's a problem with my environment, but other CLIs like create-react-app, gatsby or next work well.
Thank you,
Matteo
The text was updated successfully, but these errors were encountered: