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

Windows end-line issue in 3.3.0 #2485

Closed
jourdain opened this issue Apr 4, 2017 · 9 comments
Closed

Windows end-line issue in 3.3.0 #2485

jourdain opened this issue Apr 4, 2017 · 9 comments

Comments

@jourdain
Copy link

jourdain commented Apr 4, 2017

Bug on unix system

$ npm install
├─┬ hexo@3.3.0 
│ ├─┬ hexo-cli@1.0.2 
│ ├── hexo-front-matter@0.2.3 
│ ├─┬ hexo-fs@0.1.6 
│ ├─┬ hexo-i18n@0.2.1 
│ ├─┬ hexo-log@0.1.2 
│ ├─┬ hexo-util@0.6.0 
├─┬ hexo-deployer-git@0.1.0 
│ └─┬ hexo-util@0.5.3 
├─┬ hexo-generator-archive@0.1.4 
│ ├─┬ hexo-pagination@0.0.2 
├─┬ hexo-generator-feed@1.2.0 
├── hexo-generator-sitemap@1.1.2 
├─┬ hexo-renderer-jade@0.3.0 
├─┬ hexo-renderer-marked@0.2.11 
├─┬ hexo-renderer-stylus@0.3.3 
├─┬ hexo-server@0.2.0 

$ ./node_modules/.bin/hexo generate
env: node\r: No such file or directory

Changing the line ending to Unix in ./node_modules/.bin/hexo solved the problem.

@jourdain
Copy link
Author

jourdain commented Apr 4, 2017

The file in the repo is fine. I'm guessing, the issue came from the publication to npm by @NoahDragon. Probably some wrong setup on git on Windows for CRLF.

I think our Windows user have their environment setup with git config --global core.autocrlf false

Otherwise, great project, I love it!!!

@NoahDragon
Copy link
Member

@jourdain thank you. I didn't notice the config. I will fix it, and re-publish.

@jourdain
Copy link
Author

jourdain commented Apr 4, 2017

Thanks for the great work...
I noticed it, as it broke all our product documentation when it picked up the new version of hexo. ;-)

@jourdain
Copy link
Author

jourdain commented Apr 4, 2017

It seems that our Windows user have core.autocrlf=true. Sorry...

@NoahDragon
Copy link
Member

Sorry for the inconvenience. Publish 3.3.1. Please get the latest version, and kindly info if it is working.

@NoahDragon
Copy link
Member

NPM really should avoid such issue by following the git global config, which is check-out as windows style and check-in as unix ending.

npm/npm#12371

@jourdain
Copy link
Author

jourdain commented Apr 4, 2017

Yep. Waiting for my travis to get back to let you know...

@jourdain
Copy link
Author

jourdain commented Apr 4, 2017

Ok giving up on travis... Tried locally and everything is fine now. Thanks!

@jourdain jourdain closed this as completed Apr 4, 2017
@NoahDragon
Copy link
Member

Great glad it is working! Thanks for letting us know.

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

2 participants