-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
The token '||' is not a valid statement separator in this version. #1663
Comments
This issue has been automatically marked as idle and stale because it hasn't had any recent activity. It will be automtically closed if no further activity occurs. If you think this is wrong, or the problem still persists, just pop a reply in the comments and @remy will (try!) to follow up. |
Is this using powershell? (The issue does ask but it's not clear from your answer so hard to debug) |
I have been having this issue as well. I'm ussing powershell 6 (also tried with powershell 5.1 and got the same result). As OP mentions, this is what I've done:
I have previously used nodemon (a month ago probably) in another project through this exact same install command and everything worked fine. Now, in that project, deleting the node_modules folder and running npm install yields the same output as above. I'm glad to give any more details if needed. |
This issue has been automatically marked as idle and stale because it hasn't had any recent activity. It will be automtically closed if no further activity occurs. If you think this is wrong, or the problem still persists, just pop a reply in the comments and @remy will (try!) to follow up. |
Needs to run on windows to investigate alternative fix. |
I can't replicate this at all. I've provisioned a Windows 10 machine from AWS and connect to it using Windows Remote Client, then go through the motion. Attached is a screenshot of Powershell running the postinstall command, without error and I'm on a 5.x version of PS. If anyone is able to replicate this in a parred down example and able to offer a fix to the || statement, I'd love to hear about it. I'll leave this open for the time being, but if it remains inactive, it'll close by itself (I hope that's fine). |
I have the same problem. So I downloadad Nodemon from https://github.com/remy/nodemon as a zip file and unpacked next to my project folder , after that I removed
This not-very-elegant workaround works. |
And what if you do what I did and run the npm script directly? (In the name
of solving this issue)
…On Sat, 11 Apr 2020, 12:44 ttomm, ***@***.***> wrote:
I have the same problem.
I use Windows 10, I have Nodemon installed globally in version 2.0.3, but
when I try to install Nodemon locally, in project folder, I get the same
error
[image: image]
<https://user-images.githubusercontent.com/10185576/79041679-dd65ea00-7bf1-11ea-8268-17e372833645.png>
So I downloadad Nodemon from https://github.com/remy/nodemon as a zip
file and unpacked next to my project folder , after that I removed ||
exit 0 from package.json and from my project folder I ran command
npm install ../nodemon-master
This not-very-elegant workaround works.
—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub
<#1663 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAADLBCSONOC47VTRDNOVK3RMBJ27ANCNFSM4KIXN6LQ>
.
|
I ended up switiching to Linux. Definitely not the best solution, but had the chance to do it and did it. Working seamlessly on Linux. |
This issue has been automatically marked as idle and stale because it hasn't had any recent activity. It will be automtically closed if no further activity occurs. If you think this is wrong, or the problem still persists, just pop a reply in the comments and @remy will (try!) to follow up. |
Same error with me |
I tried to replicate this and could not. And since no one was posting any pull requests to fix it, it'll close itself and won't be fixed. I'm going to close this and encourage anyone who is able to replicate to offer a solution that allows the |
Hi all,
and for anyone trying to replicate the problem, run, |
same error with me |
@ArmaanTechDeveloper did you try the fix (literally the last comment): |
nodemon -v
: Can't install (i'm doing locally)node -v
: 12.10.0npm i nodemon --save-dev
Expected behaviour
Install correctly
Actual behaviour
node bin/postinstall || exit 0
`At line:1 char:22
The token '||' is not a valid statement separator in this version.
+ CategoryInfo : ParserError: (:) [], ParentContainsErrorRecordException
+ FullyQualifiedErrorId : InvalidEndOfLine`
Steps to reproduce
npm init
with all default valuenpm i nodemon--save-dev
The text was updated successfully, but these errors were encountered: