Skip to content
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

[MacOS] bug: env: node\r: No such file or directory #4

Closed
notiv-nt opened this issue Sep 27, 2018 · 9 comments
Closed

[MacOS] bug: env: node\r: No such file or directory #4

notiv-nt opened this issue Sep 27, 2018 · 9 comments
Assignees

Comments

@notiv-nt
Copy link

To reproduce:

  • Create an empty folder
  • yarn add svg2sprite-cli
  • Add script
     "scripts": {
     	"sprite": "svg2sprite"
     },
  • Error: env: node\r: No such file or directory

Problem:

image

Solution:

Change line endings to LF

image

@notiv-nt
Copy link
Author

notiv-nt commented Nov 6, 2018

@mrmlnc

@mrmlnc mrmlnc self-assigned this Nov 6, 2018
@mrmlnc
Copy link
Owner

mrmlnc commented Nov 6, 2018

Sorry, but I don't fully understand your problem.

How do you run npm script?

@notiv-nt
Copy link
Author

notiv-nt commented Nov 6, 2018

yarn add svg2sprite-cli
yarn sprite

@notiv-nt
Copy link
Author

notiv-nt commented Nov 6, 2018

Problem in line endings, must be LF instead of CRLF

@notiv-nt
Copy link
Author

Switching to the svg-sprite package

@glebmachine
Copy link

Still got same error(

@cenda
Copy link

cenda commented Jun 19, 2019

same here, change CRLF -> LF line endings in node_modules/svg2sprite-cli/out/cli.js file fixed an issue, but I think that's not a good idea to manually change such thing

@dimitriy-k
Copy link

yeah, here the same issue on Mac OS

@notiv-nt
Copy link
Author

Use svg-sprite

svg-sprite -s --symbol-sprite='sprite.svg' --symbol-dest=public/assets --shape-id-generator='icon-%s' source/icons/*.svg

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants