You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Quick, short summary:
I have npm scripts defined in my package.json (placed in the project root folder) which run just fine from a terminal window opened at the project root. When I try to run the same scripts using a CodeKit hook, I get the following error in the CodeKit console:
/bin/sh: npm: command not found
I gathered that CodeKit uses its own internal version of npm so I assume that there is some sort of collision between the global version of npm I have installed and the internal version used by CodeKit.
Expected results:
npm scripts defined in package.json run as expected when used in a hook.
Actual results: /bin/sh: npm: command not found
Exact steps to reproduce:
Install npm globally.
Create new project using npm init and add test file to trigger hook.
Create new CodeKit project from project folder.
Add hook to run the default npm test script when test file is changed.
Change test file to trigger hook.
Your configuration (any details about your system that you think might be relevant)
CodeKit 3.16.1
The text was updated successfully, but these errors were encountered:
Use the full, disk-root-relative path to the npm executable in the Hook. That should solve the problem.- BryanOn Oct 21, 2022, at 09:38, Tim Jüdemann ***@***.***> wrote:
Quick, short summary:
I have npm scripts defined in my package.json (placed in the project root folder) which run just fine from a terminal window opened at the project root. When I try to run the same scripts using a CodeKit hook, I get the following error in the CodeKit console:
/bin/sh: npm: command not found
I gathered that CodeKit uses its own internal version of npm so I assume that there is some sort of collision between the global version of npm and the internal version used by CodeKit.
Expected results:
npm scripts defined in package.json run as expected when used in a hook.
Actual results:
/bin/sh: npm: command not found
Exact steps to reproduce:
Install npm globally.
Create new project using npm init and add test file to trigger hook.
Create new CodeKit project from project folder.
Add hook to run the default npm test script when test file is changed.
Change test file to trigger hook.
Your configuration (any details about your system that you think might be relevant)
CodeKit 3.16.1
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you are subscribed to this thread.Message ID: ***@***.***>
Quick, short summary:
I have npm scripts defined in my package.json (placed in the project root folder) which run just fine from a terminal window opened at the project root. When I try to run the same scripts using a CodeKit hook, I get the following error in the CodeKit console:
/bin/sh: npm: command not found
I gathered that CodeKit uses its own internal version of npm so I assume that there is some sort of collision between the global version of npm I have installed and the internal version used by CodeKit.
Expected results:
npm scripts defined in package.json run as expected when used in a hook.
Actual results:
/bin/sh: npm: command not found
Exact steps to reproduce:
Your configuration (any details about your system that you think might be relevant)
CodeKit 3.16.1
The text was updated successfully, but these errors were encountered: