Skip to content
This repository was archived by the owner on Feb 20, 2019. It is now read-only.

Remove $(npm bin) as ./node_modules/.bin is on the path.#73

Open
baerrach wants to merge 1 commit intotonyhb:masterfrom
baerrach:master
Open

Remove $(npm bin) as ./node_modules/.bin is on the path.#73
baerrach wants to merge 1 commit intotonyhb:masterfrom
baerrach:master

Conversation

@baerrach
Copy link
Copy Markdown

It also fixes running this on windows as $() inside npm scripts spawns a command
shell and not a bash shell so it fails the expansion.

It also fixes running this on windows as $() inside npm scripts spawns a command
shell and not a bash shell so it fails the expansion.
@tonyhb
Copy link
Copy Markdown
Owner

tonyhb commented May 25, 2017

Thanks a ton for the feedback and PR!

I like this a little better than what we have but I'm a lil skeptical of having relative dirs in my $PATH (call me paranoid about the tiny possibility of it weakening my security). Maybe there's another way around this error? I'll have a think.

@baerrach
Copy link
Copy Markdown
Author

baerrach commented Jun 1, 2017

I hear you.

https://docs.npmjs.com/cli/run-script says

In addition to the shell's pre-existing PATH, npm run adds node_modules/.bin to the PATH provided to scripts. Any binaries provided by locally-installed dependencies can be used without the node_modules/.bin prefix.

I can't find any alternatives from googling.

If your PATH doesn't contain . in it already, I don't think this weakens security any.

ghost pushed a commit to AoD-Technologies/react-redux-ui-tools that referenced this pull request Jan 23, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants