question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Failing to run cra.sh script

See original GitHub issue

If you are reporting a bug, please fill in below. Otherwise feel to remove this template entirely.

Description

I’m currently working on issue #750 and to be able to test my changes, i decided that i could run rca.sh script. But when i run it, it fails on line 98 at the node packages/create-react-app/index.js --scripts-version=$scripts_path "$@" command . I’m trying to figure out what am i missing, but no luck so far. Here’s what i see in log :

++ npm pack
+ scripts_path=/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/tmp.Z0Iimlvq/packages/react-scripts/react-scripts-0.6.0.tgz
+ cd /Users/biercoff/Work/GitHubProjects/create-react-app
+ node packages/create-react-app/index.js --scripts-version=/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/tmp.Z0Iimlvq/packages/react-scripts/react-scripts-0.6.0.tgz
Usage: create-react-app <project-directory> [--verbose]
++ set +x
cra.sh: ERROR! An error was encountered executing line 99.
Exiting with error.

Expected behavior

I expect to have a new dummy create-react-app that i could use for my tests.

Actual behavior

I’m getting an error message and i don’t find newly created app build from my changed source code

Environment

Run these commands in the project folder and fill in their results:

  1. npm ls react-scripts (if you haven’t ejected):
  2. node -v: v6.4.0
  3. npm -v:3.10.3

Then, specify:

  1. Operating system: Mac OS Sierra
  2. Browser and version: Doesn’t matter. The problem is with the script

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
azakordonetscommented, Sep 26, 2016

Yeap, that worked 😃 Thanks for the help. Will continue working on improving eject.js output.

0reactions
gaearoncommented, Sep 26, 2016

It exists for that purpose, but it’s not meant to be called directly. It’s meant to be called as npm run create-react-app ../whatever. I’m not sure if it makes a difference though.

Can you reproduce this by running npm run create-react-app ../whatever?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Aborting a shell script if any command returns a non-zero value
Add this to the beginning of the script: set -e. This will cause the shell to exit immediately if a simple command exits...
Read more >
Shell exits when I source a script with dialog/whiptail call
Your script sets the errexit flag with set -e . After you source it, unchecked failing commands will cause the shell to exit....
Read more >
How to Exit When Errors Occur in Bash Scripts - Intoli
Exit When Any Command Fails​​ This can actually be done with a single line using the set builtin command with the -e option....
Read more >
Bash Script That Restarts a Program If It Fails
I've been trying to write a bash script that starts a program inside a tmux session and if said program then shuts down...
Read more >
Troubleshoot Tableau Server Install and Upgrade
Limited disk space can cause a failure to install, a failure to upgrade, or problems running Tableau Server. Restart Tableau Server.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found