kadirahq / npm-base

A base package for creating NPM packages with ES2015
MIT License
159 stars 19 forks source link

"lib/index.js in your entry point." #6

Open Laurentiu-Andronache opened 8 years ago

Laurentiu-Andronache commented 8 years ago

"lib/index.js in your entry point."

it's actually "src/index.js is your entry point." right?

Laurentiu-Andronache commented 8 years ago

Jeez... how is this an error? Could it not have been configured to ignore this "error"?

> eslint ./src

C:\Projects\bookmaker.js\src\__tests__\index.js
   1:29  error  Expected linebreaks to be 'LF' but found 'CRLF'  linebreak-style
   2:25  error  Expected linebreaks to be 'LF' but found 'CRLF'  linebreak-style
   3:31  error  Expected linebreaks to be 'LF' but found 'CRLF'  linebreak-style
   4:1   error  Expected linebreaks to be 'LF' but found 'CRLF'  linebreak-style
   5:24  error  Expected linebreaks to be 'LF' but found 'CRLF'  linebreak-style
   6:55  error  Expected linebreaks to be 'LF' but found 'CRLF'  linebreak-style
   7:38  error  Expected linebreaks to be 'LF' but found 'CRLF'  linebreak-style
   8:36  error  Expected linebreaks to be 'LF' but found 'CRLF'  linebreak-style
   9:6   error  Expected linebreaks to be 'LF' but found 'CRLF'  linebreak-style
  10:4   error  Expected linebreaks to be 'LF' but found 'CRLF'  linebreak-style

C:\Projects\bookmaker.js\src\index.js
  1:31  error  Expected linebreaks to be 'LF' but found 'CRLF'  linebreak-style
  2:49  error  Expected linebreaks to be 'LF' but found 'CRLF'  linebreak-style
  3:3   error  Expected linebreaks to be 'LF' but found 'CRLF'  linebreak-style
Laurentiu-Andronache commented 8 years ago

Is this for Linux? I ask because I see there's a sh script in scripts/ Also this command doesn't work for me:

npm run testonly

> npm-base@1.0.0 testonly C:\Projects\bookmaker.js
> mocha $npm_package_options_mocha

C:\Users\Sodra\AppData\Roaming\npm\node_modules\mocha\lib\utils.js:628
        throw new Error("cannot resolve path (or pattern) '" + path + "'");
        ^

Error: cannot resolve path (or pattern) '$npm_package_options_mocha'

Sry if I'm being a noob.

arunoda commented 8 years ago

Entrypoint will be lib/index.js after you build it. (doing when it's being publish to NPM).

You need to configure your editor to use LF as line breaks.

You need to have BASH inorder to run this. There are many BASH shells for windows. Use them.

Laurentiu-Andronache commented 8 years ago

I tried with Babun and Msys2 and on both it gave an error on that SH file... :(

kokjinsam commented 8 years ago

@arunoda, wouldn't it be dist/index.js? I don't see lib/ folder after build.