yarn install --production
å®è¡ãããšãå¿
èŠãªforever
äŸåé¢ä¿ãã€ã³ã¹ããŒã«ãããŸããã ããã¯ã devDependencies
nodemon
ãããããšã«é¢é£ããŠããããã§ãã
ãšã©ãŒå¿çïŒ
> forever app.js
module.js:457
throw err;
^
Error: Cannot find module 'minimatch'
ããã§ãã¹ãã¢ããªã±ãŒã·ã§ã³ãäœæããŸããïŒ
https://github.com/donovan-graham/yarn-example-app
# Steps to reproduce error
git clone https://github.com/donovan-graham/yarn-example-app.git
cd yarn-example-app
yarn install --production
npm start
# temporary step to bypass error
rm -rf node_modules
yarn remove nodemon
yarn install --production
npm start
@ Daniel15ããã¯ãnodemonãææ°ããŒãžã§ã³ã®ãããããã䜿çšããŠããããã ãšæããŸãã
ãªã³ã«é¢æ°ã¯çŸåšãdepsãšdevdepsã®äž¡æ¹ãåãå ¥ããŠããŸãã åŒæ°ã®çæã«ã€ããŠã¯ããããé²ãå¿ èŠããããŸãã
éåžžã®ç³žã§ãçç£ã®è°è«ãªãã§ã€ã³ã¹ããŒã«ããŸãã ææ°ããŒãžã§ã³ã®ã¿ãå®éã®ãã¹ã«ã€ã³ã¹ããŒã«ãããŸãã ããããã§ãã¯ããå¿ èŠããããŸãã
yarn install --production
ãå®è¡ããŠããã webpack
ã䜿çšããŠãã«ããå®è¡ããããšãããšãåæ§ã®åé¡ãçºçããŸãïŒ yarn install
ã¯æ£åžžã«æ©èœããŸãïŒã
> NODE_ENV=production webpack -p --config webpack/production.config.js
module.js:457
throw err;
^
Error: Cannot find module 'graceful-fs'
at Function.Module._resolveFilename (module.js:455:15)
at Function.Module._load (module.js:403:25)
at Module.require (module.js:483:17)
at require (internal/module.js:20:19)
ç§ãæ£ããæãåºãã°ã以åã®è©Šã¿ã¯å¥ã®ããã±ãŒãžã§åæ§ã®ãšã©ãŒã瀺ããŸããïŒ graceful-fs
ã ãã§ãªãïŒ
ç§ãéåžžã«äŒŒãŠããŸã... yarn install
ã¯åé¡ãªãåäœããŸãã ãããã --production
ãã©ã°ã䜿çšãããšã次ã®ããã«ãªããŸãã
> yarn install --production
yarn install v0.15.1
error npm-shrinkwrap.json found. This will not be updated or respected. See [TODO] for more information.
[1/4] Resolving packages...
[2/4] Fetching packages...
warning [email protected]: The engine "rhino" appears to be invalid.
warning [email protected]: The platform "win32" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
warning [email protected]: The engine "rhino" appears to be invalid.
warning [email protected]: The engine "rhino" appears to be invalid.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
[1/1] â node-sass: at Module.require (module.js:367:17)
[-/1] â waiting...
[-/1] â waiting...
[-/1] â waiting...
error C:\vagrant\ebroker-quoteengine\node_modules\node-sass: Command failed.
Exit code: 1
Command: C:\WINDOWS\system32\cmd.exe
Arguments: /d /s /c node scripts/install.js
Directory: C:\vagrant\ebroker-quoteengine\node_modules\node-sass
Output:
module.js:341
throw err;
^
Error: Cannot find module 'tough-cookie'
at Function.Module._resolveFilename (module.js:339:15)
at Function.Module._load (module.js:290:25)
at Module.require (module.js:367:17)
at require (internal/module.js:16:19)
at Object.<anonymous> (C:\vagrant\ebroker-quoteengine\node_modules\node-sass\node_modules\request\lib\cookies.js:3:13)
at Module._compile (module.js:413:34)
at Object.Module._extensions..js (module.js:422:10)
at Module.load (module.js:357:32)
at Function.Module._load (module.js:314:12)
at Module.require (module.js:367:17)
at SpawnError (C:\Users\nathan.white\AppData\Roaming\npm\node_modules\yarnpkg\lib\errors.js:18:1)
at ChildProcess.<anonymous> (C:\Users\nathan.white\AppData\Roaming\npm\node_modules\yarnpkg\lib\util\child.js:107:15)
at emitTwo (events.js:100:13)
at ChildProcess.emit (events.js:185:7)
at maybeClose (internal/child_process.js:827:16)
at Socket.<anonymous> (internal/child_process.js:319:11)
at emitOne (events.js:90:13)
at Socket.emit (events.js:182:7)
at Pipe._onclose (net.js:471:12)
次ã®å Žåãšåæ§ã®åé¡ãåçŸã§ããŸãã
npm init --yes
yarn add --dev nodemon
yarn add gulp
rm -rf node_modules
yarn install --production
ããã«ããis-glob
ãã€ã³ã¹ããŒã«ãããŸãããäŸåé¢ä¿ã¯ã€ã³ã¹ããŒã«ãããŸããis-extglob
ïŒ
> yarn why is-glob
yarn why v0.16.0
# ...
info Reasons this module exists
- "nodemon#chokidar" depends on it
- "gulp#liftoff#findup-sync" depends on it
> yarn why is-extglob
yarn why v0.16.0
# ...
info This module exists because "nodemon#chokidar#is-glob" depends on it.
ãã©ããŒã¹äžã«gulp#liftoff
äŸåãã¹ããå¿ãããããã§ãã
ç·šéïŒå°ããªäŸïŒ
npm init --yes
yarn add --dev [email protected]
yarn add [email protected]
rm -rf node_modules
yarn --prod
node -e "require('is-glob')"
ãŸãã yarn --prod
å®è¡ããåã«devDependencies
ãåé€ãããšãæ£ããäŸåé¢ä¿ããªãŒãã€ã³ã¹ããŒã«ãããããšã確èªããŸããã
ç§ã®ãœãããŠã§ã¢ããŒã ã¯ãç¹ã«less
ãšpouchdb
ã®äž¡æ¹ã®äŸåé¢ä¿ã§ããããã±ãŒãžprr
ã§ãã®åé¡ã«ééããŸããã ä»ã®å€ãã®ããã±ãŒãžã--production
ãã«ãããæ¬ èœããŠããŸãããã prr
ãæåã«è£œåã®é害ãåŒãèµ·ãããŸããã devããã±ãŒãžãå«ãããšã€ã³ã¹ããŒã©ãŒã®ãµã€ãºã倧å¹
ã«å¢å ããããããã®åé¡ã¯ç§ãã¡ã«ãšã£ãŠå€§ããªåé¡ã§ããããã®ãããnpmã®äœ¿çšã«æ»ããŸããã
FWIWïŒæ¬çªç°å¢ã§yarn
ãå®è¡ããåã«ãpackage.jsonããdevDependencies
ã»ã¯ã·ã§ã³ãåé€ããããšã§ããã®åé¡ãåé¿ã§ããŸãã
@gihrigãèšã£ãããã«ã npm prune --production
å®è¡ãããšãdevDependenciesãåé€ããããã®åé¡ã®åé¿ã«åœ¹ç«ã¡ãŸãã
@gihrigãèšã£ãããã«ãnpm prune --productionãå®è¡ãããšãdevDependenciesãåé€ããããã®åé¡ã®åé¿ã«åœ¹ç«ã¡ãŸãã
npmã«å¯ŸããYarnã®äž»ãªå©ç¹ã¯ã決å®è«çãªnode_modules
ãã£ã¬ã¯ããªã§ããã€ãŸããéçºãCIãããã³æ¬çªç°å¢ã§ãã®ãŸãŸäœ¿çšã§ããŸãã npm prune --production
å®è¡ãããšãåãåäœãçºçããŸããïŒ
ç§ã®çŸåšã®åé¿çã¯ãæ¬çªç°å¢ã«ãdevDependencies
ãã€ã³ã¹ããŒã«ããããšã§ãã ãã£ã¹ã¯ã¯å®äŸ¡ã§ïŒç¹ã«AWSã§ã¯ïŒããã£ã¹ã¯å®¹éããã確å®çãªã€ã³ã¹ããŒã«ã®æ¹ãã¯ããã«éèŠã§ãã ãããã£ãŠãç§ã®ãåé¿çãã¯ã yarn --production
ãçŸåšååšããªãããã«åäœããããšã§ãã
@tanx npm prune --production
ã¯devDependenciesãåé€ããã ãã§ãã ãããŠç§ã®ãã¹ãã§ã¯ãåžžã«åãã¢ãžã¥ãŒã«ãåé€ãããŸããã äžæ¹ãã¯ãããã£ã¹ã¯å®¹éã¯å®ãã®ã§ã yarn --production
ãçµäºããªããã®ããã«æ¯ãèãæ¹ããããè¯ãåé¿çã§ã:)
@tanx npm prune --productionã¯ãdevDependenciesãåé€ããã ãã§ãã ãããŠç§ã®ãã¹ãã§ã¯ãåžžã«åãã¢ãžã¥ãŒã«ãåé€ãããŸããã
ããã¯ãŸãã«ã Yarnã®ããã°æçš¿ã§èª¬æãããŠãããç§ã®ãã·ã³ã§åäœããããšããèãæ¹ã§ãã åé¡ã¯ã yarn.lock
ãã¡ã€ã«ãä»ããyarnã®æŽåæ§ãã§ãã¯ãªãã§npmã«node_modules
ã®ç¶æ
ãå€æŽãããŠããããšã§ãã
ããŸãããã°ãè°è«ãããåé¿çã¯ãéçºéšéãšæ¬çªéšéãå°éããããã«ãã€ãŒã³ã®æŽæ°ã«ãã£ãŠããã«ç¡å¹ã«ãªããŸãã ãããŸã§ã®éããnpmpruneãã®åŸåŠçããã¯ã«ã¯ããã声ããããããããŸãã
äžèšã®yarn why
ããšã¯ãç¡é¢ä¿ãªåé¡ã§ãã ããã¯ã why
ã³ãŒããããã±ãŒãžãæ€çŽ¢ããæ¹æ³ã®åãªãå¯äœçšã®ããã§ãã
ã°ã©ãã1åãŠã©ãŒã¯ããåŸãå¯èŠæ§ãäŒæããããã®ãã¹ãè¿œå ããã«ããããè¡ãããã®åªããæ¹æ³ãèŠã€ããããšããŸããã å¯èŠæ§ãå¥ã®ã¹ãããã«åå²ããã ãã§ãããã©ããã¯ããããŸããã
ããã€ãã®èå³æ·±ããšããžã±ãŒã¹ããããŸããããã¯ãå¯èŠæ§ãé©åã«è§£æ±ºããããšã ãã§ã¯ãããŸããã
ãã®å ŽåãCã®ãªãã·ã§ã³ã®ãã©ã°ã¯devãšprodã«äŸåããŸãã éçºã§ã¯ãªãã·ã§ã³ã§ã¯ãªãã補åã§ã¯ãªãã·ã§ã³ã«ãªããŸãã 芪ã®1ã€ãããªãã·ã§ã³ã®ãã©ã°ãç¶æ¿ããïŒãŸãã¯åžžã«prodã®èŠªããç¶æ¿ããïŒã ãã§ãå¥åŠãªçµæã«ãªãå¯èœæ§ããããŸãã
ããã¯0.17.2ã§ã¯ãŸã ä¿®æ£ãããŠããŸããð¢
åçŸïŒ https ïŒ
yarn
node index.js # works
yarn --prod
node index.js # explodes
/ cc @jkrems
0.17.2ïŒHearthSim / JoustïŒ169ïŒã§ãä¿®æ£ãããŠããªãããã§ãã
@SimenBã®æ瀺ã§ç°¡åã«åçŸã§ããã®ã§ãåéããŸãã
@wyzeåé¡ã¯ããã«ãŒãã³ã°ã§ã¯ãªããã€ã³ã¹ããŒã«èªäœã«ããå¯èœæ§ããããŸããïŒ
rm -rf node_modules/ && yarn && npm prune --production && node index.js
ã¯åããšã©ãŒã§å€±æããŸãã
ãã ãã rm -rf node_modules/ && npm i && npm prune --production && node index.js
æ©èœããŸãã
ãã ããyarnãšnpmã¯åæã«äœ¿çšããããšãæå³ããŠããªãã®ã§ãåããšã©ãŒãçºçããã®ã¯å¶ç¶ãããããŸããã
npm i
ãšyarn
node_modules
åŸã«"_requiredBy"
åºåããªãããšã瀺ããŠããŸããããããã npm prune
ãyarn install
åŸã«æ··ä¹±ããçç±ã§ãã
ããã§åãåé¡ãçºçããŸãããDockerã§æ¬çªãã«ãããã¹ãããŠãããšããã芪ã¢ãžã¥ãŒã«send
ïŒExpressã§äœ¿çšïŒãã€ã³ã¹ããŒã«ãããŠããŠãã yarn --production
ã§ã¯ããã±ãŒãžmime
ãæ¬ èœããŠããããšãããããŸããã ã
ãã«ããäºæž¬ã§ããªãããããã®åé¡ã¯æåªå ã§åŠçããå¿ èŠããããšæããŸãã
åé¿çãšããŠããã«ãã¹ã¯ãªããã®package.jsonããdevDependenciesã»ã¯ã·ã§ã³ãåé€ããã ãã§ãã
$ jq 'del(.devDependencies)' package.json > tmp.json && mv tmp.json package.json
@ dy-dxã®ã¢ããã€ã¹ã«åŸã£ãŠãéçºäžã«ãã®åé¡ãã¢ã³ããŒãããããDockerã®ã«ã¹ã¿ã ãšã³ããªãã€ã³ããäœæããŸããã
ãŸããDockerfileã«jqãã€ã³ã¹ããŒã«ããŠã次ã®è¡ãã©ããã«è¿œå ããå¿ èŠããããŸãã
RUN apt-get update && \
apt-get install -y jq
ãããŠããã®ã¹ã¯ãªããã®ã©ãããè¿œå ããDockerfileãšããŠããã䜿çšãã[ENTRYPOINT]
ãŸãã¯ãããã³ã°ãŠã£ã³ããŠã»ã³ã³entrypoint
entrypoint.sh
Dockerfile [CMD]
ãŸãã¯docker-compose command
奜ã¿ã®ã³ãã³ãã䜿çšããŸãïŒäŸïŒ npm start
åãã¹ã¯ãªãããCIã§äœ¿çšããç·šéããŠã€ã¡ãŒãžãäœæããããšãã§ããŸã
@SimenB entries-test
ããã±ãŒãžããnode_modules
ãåé€ããŠãè©ŠããŠã¿ãŠãã ããã
v1.0.1 tarããŒã«ãæœåºããŸãã define-properties
ãšä»ã®ã¢ãžã¥ãŒã«ãå«ãnode_modules
ãã©ã«ããŒããããŸãã ãããŠããããã®ã©ãã*.js
ãã¡ã€ã«ãæã£ãŠããŸããã
@torifatãããšãã©ããã£ãŠãããããŸããã£ãã®ã§ããïŒ ããããšã¯ã§ããªãã¯ãnode_modules
䜿çšããã«bundledDependencies
...
ã¯ãªãŒã³ãªãã®ãããã·ã¥ããããšããŸãïŒãããžã§ã¯ããåé€ããã®ã§ãåäœæããå¿
èŠããããŸãïŒã
@torifatããã¯ãããèŠãã糞ã®ããã§ãã
$ mkdir some-dir && cd some-dir && yarn init -y && yarn add object.entries && yarn pack && tar -ztvf some-dir-v1.0.0.tgz
drwxr-xr-x 0 0 0 0 Nov 27 10:36 package
-rw-r--r-- 0 0 0 972 Oct 15 2015 package/node_modules/define-properties/CHANGELOG.md
-rw-r--r-- 0 0 0 1080 Oct 15 2015 package/node_modules/define-properties/LICENSE
-rw-r--r-- 0 0 0 2725 Oct 15 2015 package/node_modules/define-properties/README.md
-rw-r--r-- 0 0 0 1593 Oct 15 2015 package/node_modules/define-properties/package.json
-rw-r--r-- 0 0 0 3798 Aug 21 11:09 package/node_modules/es-abstract/CHANGELOG.md
-rw-r--r-- 0 0 0 1080 Jul 29 2015 package/node_modules/es-abstract/LICENSE
-rw-r--r-- 0 0 0 1812 Aug 13 2015 package/node_modules/es-abstract/README.md
-rw-r--r-- 0 0 0 1989 Aug 21 11:09 package/node_modules/es-abstract/package.json
-rw-r--r-- 0 0 0 1207 Jan 4 2016 package/node_modules/es-to-primitive/CHANGELOG.md
-rw-r--r-- 0 0 0 1082 Nov 1 2015 package/node_modules/es-to-primitive/LICENSE
-rw-r--r-- 0 0 0 2180 Nov 1 2015 package/node_modules/es-to-primitive/README.md
-rw-r--r-- 0 0 0 1558 Jan 4 2016 package/node_modules/es-to-primitive/package.json
-rw-r--r-- 0 0 0 1074 Sep 22 2014 package/node_modules/foreach/LICENSE
-rw-r--r-- 0 0 0 593 Sep 22 2014 package/node_modules/foreach/Readme.md
-rw-r--r-- 0 0 0 1297 Sep 22 2014 package/node_modules/foreach/package.json
-rw-r--r-- 0 0 0 1052 Feb 14 2016 package/node_modules/function-bind/LICENSE
-rw-r--r-- 0 0 0 1488 Feb 14 2016 package/node_modules/function-bind/README.md
-rw-r--r-- 0 0 0 1619 Feb 14 2016 package/node_modules/function-bind/package.json
-rw-r--r-- 0 0 0 1060 Jul 24 2015 package/node_modules/has/LICENSE-MIT
-rw-r--r-- 0 0 0 239 Jul 24 2015 package/node_modules/has/README.mkd
-rw-r--r-- 0 0 0 782 Jul 24 2015 package/node_modules/has/package.json
-rw-r--r-- 0 0 0 1839 Feb 28 2016 package/node_modules/is-callable/CHANGELOG.md
-rw-r--r-- 0 0 0 1082 May 19 2015 package/node_modules/is-callable/LICENSE
-rw-r--r-- 0 0 0 1978 Aug 12 2015 package/node_modules/is-callable/README.md
-rw-r--r-- 0 0 0 1983 Feb 28 2016 package/node_modules/is-callable/package.json
-rw-r--r-- 0 0 0 421 Sep 27 2015 package/node_modules/is-date-object/CHANGELOG.md
-rw-r--r-- 0 0 0 1082 Mar 13 2015 package/node_modules/is-date-object/LICENSE
-rw-r--r-- 0 0 0 1751 Aug 12 2015 package/node_modules/is-date-object/README.md
-rw-r--r-- 0 0 0 1420 Sep 27 2015 package/node_modules/is-date-object/package.json
-rw-r--r-- 0 0 0 482 Jan 30 2015 package/node_modules/is-regex/CHANGELOG.md
-rw-r--r-- 0 0 0 1081 Jan 15 2014 package/node_modules/is-regex/LICENSE
-rw-r--r-- 0 0 0 1623 Jan 28 2015 package/node_modules/is-regex/README.md
-rw-r--r-- 0 0 0 1512 Jan 30 2015 package/node_modules/is-regex/package.json
-rw-r--r-- 0 0 0 121 Jan 26 2015 package/node_modules/is-symbol/CHANGELOG.md
-rw-r--r-- 0 0 0 1082 Jan 24 2015 package/node_modules/is-symbol/LICENSE
-rw-r--r-- 0 0 0 1469 Jan 24 2015 package/node_modules/is-symbol/README.md
-rw-r--r-- 0 0 0 1214 Jan 26 2015 package/node_modules/is-symbol/package.json
-rw-r--r-- 0 0 0 6992 Jul 5 19:14 package/node_modules/object-keys/CHANGELOG.md
-rw-r--r-- 0 0 0 1080 Oct 15 2015 package/node_modules/object-keys/LICENSE
-rw-r--r-- 0 0 0 2460 Oct 15 2015 package/node_modules/object-keys/README.md
-rw-r--r-- 0 0 0 1955 Jul 5 19:14 package/node_modules/object-keys/package.json
-rw-r--r-- 0 0 0 560 Oct 6 2015 package/node_modules/object.entries/CHANGELOG.md
-rw-r--r-- 0 0 0 1082 Sep 2 2015 package/node_modules/object.entries/LICENSE
-rw-r--r-- 0 0 0 2339 Sep 2 2015 package/node_modules/object.entries/README.md
-rw-r--r-- 0 0 0 1636 Oct 6 2015 package/node_modules/object.entries/package.json
-rw-r--r-- 0 0 0 145 Nov 27 10:36 package/package.json
npm pack
ãããšãïŒåããã£ã¬ã¯ããªã§ïŒæåŸ
ã©ããã«æ©èœããŸãã
$ npm pack && tar -ztvf some-dir-1.0.0.tgz
-rw-r--r-- 0 501 20 145 Nov 27 10:36 package/package.json
-rw-r--r-- 0 501 20 2460 Nov 27 10:36 package/yarn.lock
Yarnã¯ã changelog
ã readme
ã package.json
ãå«ããããšã«éåžžã«ç±å¿ã§ã node_modules
ããã®ãã®ãå«ãŸããŠããããã§ã...
ã€ãŒã³@ 0.17.9ã䜿çš
@torifatã1.0.2ãå ¬éããŸããïŒä»è¿°ã¹ããã°ãåé¿ããããã«npmã䜿çšïŒãããã§ãåãåé¡
node_modulesã«é¢ãããã°ã®ããã«ïŒ2047ãéããŸããããç§ã®åçŸã¯é©åãªtarballãå ¬éãããŠããŠãæå¹ã§ããããããã®åé¡ã§ã¯èµ€ãã·ã³ã§ãã
ïŒè³ŒèªããŠãã人ãžã®ã¹ãã ã«ã€ããŠç³ãèš³ãããŸãããç§ã¯ä»ãããŸãïŒ
@SimenBãæéãããã ãããããšãããããŸãã ç§ã¯ãã°ãèŠã€ããŸããã
ããã¯ãç§ãéããã°ããã®ïŒ2104ã«é¢é£ããŠããããã§ãã OPã®ã€ã³ã¹ããŒã«åŸã®node_modules/.bin
ïŒ
$ ll node_modules/.bin
total 16
lrwxr-xr-x 1 samuelreed staff 22B Dec 1 11:16 forever -> ../forever/bin/forever
lrwxr-xr-x 1 samuelreed staff 109B Dec 1 11:16 nodemon -> ../../../../../Library/Caches/Yarn/npm-nodemon-1.11.0-226c562bd2a7b13d3d7518b49ad4828a3623d06c/bin/nodemon.js
ïŒ2116ã§ä¿®æ£ã
ïŒ2116ã¯ãŸã çµ±åãããŠããŸããïŒ ã³ãããå±¥æŽã«è¡šç€ºãããŸããã ã¿ã°ä»ãããããªãªãŒã¹ã«ãªãå Žåãå°ãªããšããã¹ã¿ãŒã§ä¿®æ£ãå©çšå¯èœã«ãªãåã«ãå€ãã®åé¡ãéããã®ã¯ææå°æ©ã®ããã§ãã ãŸããïŒ2116ã3ã€ã®ãã§ãã¯ãã¹ãŠã«å€±æããŠããããã§ãã ç§ã¯äœãã足ããªãã®ã§ããïŒ
ããã¯ãïŒïŒ2116ïŒãå«ãv0.18.0ã§ããŸã åé¡ã§ãã
ã¯ãããã®åé¡ã0.18.0ã§ããŸã ååšããŠããããšã確èªã§ããŸã
ç§ãèŠããšãããããïŒ2116ã¯ãã®åé¡ã®ãã¹ããå°å ¥ããå¿ èŠããããŸããïŒ test.concurrentïŒ '-productionflagã¯devã®äŸåé¢ä¿ãç¡èŠããŸã' ...ãŸãã¯ç§ã¯ééã£ãŠããŸããïŒ
ãã®ãã¹ãã§ã¯ãæšç§»çãªäŸåé¢ä¿ã®æ£ããåäœã¯æ€èšŒãããŸããã
ç§ã®å Žåãåé¡ã¯ãprodïŒminimatch v2.0.0ïŒãšdevïŒuseragent v2.1.9ïŒã®äŸåé¢ä¿ã®éã®å
±æäŸåé¢ä¿ïŒlru-cacheïŒã§ãã ãã®å
±æäŸåé¢ä¿ã¯ãprodäŸåé¢ä¿ã§å¿
èŠãªå Žåã§ãã --production
ã«ã€ã³ã¹ããŒã«ãããŸããã
@beheh minimatch
ãlru-cache
䜿çšããŠããã®ãããããŸãããæ¬çªç°å¢ã«ã€ã³ã¹ããŒã«ãããŠããªãçç±ã§ããïŒ
dep { A->B }
devDep { B }
OK
A,B are installed.
dep { A->C->D }
devDep { B->C->D }
OK
A,C,D are installed.
dep { E->A->C->D }
devDep { B->C->D }
KO
E,A,C are installed but D is missing.
ããã¯@SimenBã«ãã£ãŠç€ºãããŠããã±ãŒã¹
"dependencies": {
"entries-test": "^1.0.1"
},
"devDependencies": {
"object.values": "^1.0.3"
}
@SharpEdgeMarshallãã¹ãããŠããã ãããããšãããããŸãã ãã¹ãã±ãŒã¹ãšããŠè¿œå ããŸãã
@torifatã¯ãããåéããããšãæ€èšãããããããŸãã
@SharpEdgeMarshall以äžãè©ŠããŸããããæ©èœããŠããŸãã å®éã®åé¡ãç解ããå¿ èŠããããŸãã
@SimenBã¯ãoptionalDependencies
ãåå ã§çºçããå¯èœæ§ããããŸãã ããã«ã¯å¥ã®æªè§£æ±ºã®åé¡ããããŸãã
@torifatç§ã®åçŸã¯ãŸã çºçããŸãïŒ https ïŒ
ç·šéïŒãªãã·ã§ã³ã®depsããªãå Žåã grep optional yarn.lock
ã¯1ã§çµäºããŸã
ãã ãã define-properties
ãæ¬ èœãã代ããã«ã Error: Cannot find module 'object-keys'
倱æããããã«ãªããŸããã
$ yarn why object-keys
yarn why v0.18.0
[1/4] ð€ Why do we have the module "object-keys"...?
[2/4] ð Initialising dependency graph...
[3/4] ð Finding dependency...
[4/4] ð¡ Calculating file sizes...
info This module exists because "object.values#define-properties" depends on it.
âš Done in 0.09s.
ä»ã§ã¯1ã¬ãã«æ·±ãåŠçããŠããããã§ããã倱æããŸã
@SimenBããªããšäžç·ã«è©ŠããŸããïŒ
{
"dependencies": {
"entries-test": "^1.0.1"
},
"devDependencies": {
"object.values": "^1.0.3"
}
}
ãããŠãããã¯ç§ã«ãšã£ãŠã¯ããŸãæ©èœããŠããŸãã yarn cache clean
ãå®è¡ããŠãåè©Šè¡ã§ããŸããïŒ
ãããã倱æããŸã
@SimenB yarn.lock
ãã¡ã€ã«ãå
±æã§ããŸããïŒ
$ rm -rf node_modules && rm yarn.lock && yarn cache clean && yarn && node index.js && yarn --prod && node index.js
yarn cache v0.18.0
success Cleared cache.
âš Done in 0.07s.
yarn install v0.18.0
info No lockfile found.
[1/4] ð Resolving packages...
[2/4] ð Fetching packages...
[3/4] ð Linking dependencies...
[4/4] ð Building fresh packages...
success Saved lockfile.
âš Done in 0.92s.
yarn install v0.18.0
[1/4] ð Resolving packages...
[2/4] ð Fetching packages...
[3/4] ð Linking dependencies...
[4/4] ð Building fresh packages...
âš Done in 0.18s.
module.js:471
throw err;
^
Error: Cannot find module 'object-keys'
at Function.Module._resolveFilename (module.js:469:15)
at Function.Module._load (module.js:417:25)
at Module.require (module.js:497:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/Users/simbekkh/repos/ugh/node_modules/define-properties/index.js:3:12)
at Module._compile (module.js:570:32)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
ç§ã«ãšã£ãŠãSimenBã®äŸã¯yarn cache clean
åŸã§ã0.18.0ã§ã¯æ©èœããŸãã
# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
# yarn lockfile v1
define-properties@^1.1.2:
version "1.1.2"
resolved "http://npm.office.crweb.it/define-properties/-/define-properties-1.1.2.tgz#83a73f2fea569898fb737193c8f873caf6d45c94"
dependencies:
foreach "^2.0.5"
object-keys "^1.0.8"
entries-test@^1.0.1:
version "1.0.2"
resolved "http://npm.office.crweb.it/entries-test/-/entries-test-1.0.2.tgz#f1039aba3a2effc9c3a56b6b1180694b2789e4d5"
dependencies:
object.entries "^1.0.3"
es-abstract@^1.6.1:
version "1.6.1"
resolved "http://npm.office.crweb.it/es-abstract/-/es-abstract-1.6.1.tgz#bb8a2064120abcf928a086ea3d9043114285ec99"
dependencies:
es-to-primitive "^1.1.1"
function-bind "^1.1.0"
is-callable "^1.1.3"
is-regex "^1.0.3"
es-to-primitive@^1.1.1:
version "1.1.1"
resolved "http://npm.office.crweb.it/es-to-primitive/-/es-to-primitive-1.1.1.tgz#45355248a88979034b6792e19bb81f2b7975dd0d"
dependencies:
is-callable "^1.1.1"
is-date-object "^1.0.1"
is-symbol "^1.0.1"
foreach@^2.0.5:
version "2.0.5"
resolved "http://npm.office.crweb.it/foreach/-/foreach-2.0.5.tgz#0bee005018aeb260d0a3af3ae658dd0136ec1b99"
function-bind@^1.0.2, function-bind@^1.1.0:
version "1.1.0"
resolved "http://npm.office.crweb.it/function-bind/-/function-bind-1.1.0.tgz#16176714c801798e4e8f2cf7f7529467bb4a5771"
has@^1.0.1:
version "1.0.1"
resolved "http://npm.office.crweb.it/has/-/has-1.0.1.tgz#8461733f538b0837c9361e39a9ab9e9704dc2f28"
dependencies:
function-bind "^1.0.2"
is-callable@^1.1.1, is-callable@^1.1.3:
version "1.1.3"
resolved "http://npm.office.crweb.it/is-callable/-/is-callable-1.1.3.tgz#86eb75392805ddc33af71c92a0eedf74ee7604b2"
is-date-object@^1.0.1:
version "1.0.1"
resolved "http://npm.office.crweb.it/is-date-object/-/is-date-object-1.0.1.tgz#9aa20eb6aeebbff77fbd33e74ca01b33581d3a16"
is-regex@^1.0.3:
version "1.0.3"
resolved "http://npm.office.crweb.it/is-regex/-/is-regex-1.0.3.tgz#0d55182bddf9f2fde278220aec3a75642c908637"
is-symbol@^1.0.1:
version "1.0.1"
resolved "http://npm.office.crweb.it/is-symbol/-/is-symbol-1.0.1.tgz#3cc59f00025194b6ab2e38dbae6689256b660572"
object-keys@^1.0.8:
version "1.0.11"
resolved "http://npm.office.crweb.it/object-keys/-/object-keys-1.0.11.tgz#c54601778ad560f1142ce0e01bcca8b56d13426d"
object.entries@^1.0.3:
version "1.0.4"
resolved "http://npm.office.crweb.it/object.entries/-/object.entries-1.0.4.tgz#1bf9a4dd2288f5b33f3a993d257661f05d161a5f"
dependencies:
define-properties "^1.1.2"
es-abstract "^1.6.1"
function-bind "^1.1.0"
has "^1.0.1"
object.values@^1.0.3:
version "1.0.4"
resolved "http://npm.office.crweb.it/object.values/-/object.values-1.0.4.tgz#e524da09b4f66ff05df457546ec72ac99f13069a"
dependencies:
define-properties "^1.1.2"
es-abstract "^1.6.1"
function-bind "^1.1.0"
has "^1.0.1"
$ rm -rf node_modules && rm yarn.lock && yarn cache clean && yarn && node index.js && rm -rf node_modules && rm yarn.lock && yarn cache clean && yarn --prod && node index.js
yarn cache v0.18.0
success Cleared cache.
âš Done in 0.07s.
yarn install v0.18.0
info No lockfile found.
[1/4] ð Resolving packages...
[2/4] ð Fetching packages...
[3/4] ð Linking dependencies...
[4/4] ð Building fresh packages...
success Saved lockfile.
âš Done in 0.93s.
yarn cache v0.18.0
success Cleared cache.
âš Done in 0.07s.
yarn install v0.18.0
info No lockfile found.
[1/4] ð Resolving packages...
[2/4] ð Fetching packages...
[3/4] ð Linking dependencies...
[4/4] ð Building fresh packages...
success Saved lockfile.
âš Done in 0.76s.
module.js:471
throw err;
^
Error: Cannot find module 'object-keys'
at Function.Module._resolveFilename (module.js:469:15)
at Function.Module._load (module.js:417:25)
at Module.require (module.js:497:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/Users/simbekkh/repos/ugh/node_modules/define-properties/index.js:3:12)
at Module._compile (module.js:570:32)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
ããã¯ãã¡ã€ã«ïŒ
# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
# yarn lockfile v1
define-properties@^1.1.2:
version "1.1.2"
resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.2.tgz#83a73f2fea569898fb737193c8f873caf6d45c94"
dependencies:
foreach "^2.0.5"
object-keys "^1.0.8"
entries-test@^1.0.1:
version "1.0.2"
resolved "https://registry.yarnpkg.com/entries-test/-/entries-test-1.0.2.tgz#f1039aba3a2effc9c3a56b6b1180694b2789e4d5"
dependencies:
object.entries "^1.0.3"
es-abstract@^1.6.1:
version "1.6.1"
resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.6.1.tgz#bb8a2064120abcf928a086ea3d9043114285ec99"
dependencies:
es-to-primitive "^1.1.1"
function-bind "^1.1.0"
is-callable "^1.1.3"
is-regex "^1.0.3"
es-to-primitive@^1.1.1:
version "1.1.1"
resolved "https://registry.yarnpkg.com/es-to-primitive/-/es-to-primitive-1.1.1.tgz#45355248a88979034b6792e19bb81f2b7975dd0d"
dependencies:
is-callable "^1.1.1"
is-date-object "^1.0.1"
is-symbol "^1.0.1"
foreach@^2.0.5:
version "2.0.5"
resolved "https://registry.yarnpkg.com/foreach/-/foreach-2.0.5.tgz#0bee005018aeb260d0a3af3ae658dd0136ec1b99"
function-bind@^1.0.2, function-bind@^1.1.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.0.tgz#16176714c801798e4e8f2cf7f7529467bb4a5771"
has@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/has/-/has-1.0.1.tgz#8461733f538b0837c9361e39a9ab9e9704dc2f28"
dependencies:
function-bind "^1.0.2"
is-callable@^1.1.1, is-callable@^1.1.3:
version "1.1.3"
resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.3.tgz#86eb75392805ddc33af71c92a0eedf74ee7604b2"
is-date-object@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/is-date-object/-/is-date-object-1.0.1.tgz#9aa20eb6aeebbff77fbd33e74ca01b33581d3a16"
is-regex@^1.0.3:
version "1.0.3"
resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.0.3.tgz#0d55182bddf9f2fde278220aec3a75642c908637"
is-symbol@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/is-symbol/-/is-symbol-1.0.1.tgz#3cc59f00025194b6ab2e38dbae6689256b660572"
object-keys@^1.0.8:
version "1.0.11"
resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.0.11.tgz#c54601778ad560f1142ce0e01bcca8b56d13426d"
object.entries@^1.0.3:
version "1.0.4"
resolved "https://registry.yarnpkg.com/object.entries/-/object.entries-1.0.4.tgz#1bf9a4dd2288f5b33f3a993d257661f05d161a5f"
dependencies:
define-properties "^1.1.2"
es-abstract "^1.6.1"
function-bind "^1.1.0"
has "^1.0.1"
object.values@^1.0.3:
version "1.0.4"
resolved "https://registry.yarnpkg.com/object.values/-/object.values-1.0.4.tgz#e524da09b4f66ff05df457546ec72ac99f13069a"
dependencies:
define-properties "^1.1.2"
es-abstract "^1.6.1"
function-bind "^1.1.0"
has "^1.0.1"
@SimenBããããšãã ãã£ãã·ã¥ã«åé¡ããã£ãããã§ãã ãã£ãã·ã¥ãã¯ãªã¢ããåŸã倱æããŠããŸãã ããããå¥ã®ãšã©ãŒããããŸãã 調æ»ããæéããã ããã
ãšããã§ããã®ã¹ã¬ããã§ã¯https://github.com/Mottie/Octopatcherã䜿çšããããšããå§ãã
å€ãã®åºåã©ã€ã³ã§éåžžã«å®çšç
ã¹ãã ããããŸã
@SimenB v0.18.0
倱æããŸããããææ°ã®master
ã§ã¯åçŸã§ããŸããã
æŽæ°ïŒå¥åŠãªïŒ åã³å€±æããŠããŸãð
@torifatãã¹ã¿ãŒïŒv0.19.0ïŒã§ã¯åäœããªãããšã確èªã§ããŸãrm -rf node_modules && rm yarn.lock && ../yarn/bin/yarn cache clean && ../yarn/bin/yarn && node index.js && rm -rf node_modules && rm yarn.lock && ../yarn/bin/yarn cache clean && ../yarn/bin/yarn --prod && node index.js
yarn cache v0.19.0-0
success Cleared cache.
Done in 0.58s.
yarn install v0.19.0-0
info No lockfile found.
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
[4/4] Building fresh packages...
success Saved lockfile.
Done in 10.18s.
yarn cache v0.19.0-0
success Cleared cache.
Done in 0.09s.
yarn install v0.19.0-0
info No lockfile found.
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
[4/4] Building fresh packages...
success Saved lockfile.
Done in 4.26s.
module.js:457
throw err;
^
Error: Cannot find module 'object-keys'
at Function.Module._resolveFilename (module.js:455:15)
at Function.Module._load (module.js:403:25)
at Module.require (module.js:483:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/home/sharpedge/git/Utility/YarnBug/node_modules/define-properties/index.js:3:12)
at Module._compile (module.js:556:32)
at Object.Module._extensions..js (module.js:565:10)
at Module.load (module.js:473:32)
at tryModuleLoad (module.js:432:12)
at Function.Module._load (module.js:424:3)
çŸåšã®å®å®ãã0.17.10
åãåé¡ãçºçããŸãïŒäžéšã®ããã±ãŒãžã¯--production
ãã©ã°ã§ã€ã³ã¹ããŒã«ãããŸããïŒïŒ
curl -o- -L https://yarnpkg.com/install.sh | bash && ~/.yarn/bin/yarn install --production && rm -rf ~/.yarn
ããããçŸåšã®ãã€ããªãŒãã«ãYarn 0.19.0-20161207.1241
ãè©ŠããŠã¿ããšãå¿
èŠãªãã¹ãŠã®ããã±ãŒãžãã¢ããªã«æ£ããã€ã³ã¹ããŒã«ãããŠããŸãã
wget https://yarnpkg.com/install.sh && chmod +x install.sh && ./install.sh --nightly && rm -f install.sh && ~/.yarn/bin/yarn install --production && rm -rf ~/.yarn
@SharpEdgeMarshall @SimenBã¯ãææ°ã®ãã€ããªãŒãã«ããè©ŠããŠãåé¡ã解決ããªãããšã確èªã§ããŸããã
Dockerã³ã³ããã§äœ¿çšïŒ https ïŒ
@nodkz 18ã¯
ãŸã install yarn@rc
ãå¿
èŠã ãšæããŸãïŒ
'dist-tags': { rc: '0.18.0', latest: '0.17.10' },
ããã¯æ°ããããšã§ããæ°æ¥åã«ã€ã³ã¹ããŒã«ããã ãã§0.18ãååŸããŸããã ãšã«ããããã°ã¯ãŸã 0.18ã§åçŸå¯èœã§ãã
@nodkzReproã¯æ¬¡ã®
{
"dependencies": {
"entries-test": "^1.0.1"
},
"devDependencies": {
"object.values": "^1.0.3"
}
}
ã¯ããç§ãã¡ã®ãããžã§ã¯ãã§ãåæ§ã®åé¡ãçºçããŠããŸãã
rm -rf package.json yarn.lock node_modules && npm init --yes && yarn add --dev nodemon && yarn add glob-stream && yarn --prod && node -p "require('glob-stream')"
0.18ãšææ°ã®ãã¹ã¿ãŒãã©ã³ãã®äž¡æ¹ã§å€±æããŸãã
åæããŸããã ããã§ãææ°ã®ãã®ã§åçŸããããšãã§ããŸãã
ç§ã®åé¡ã¯ãããšäŒŒãŠãããåãã ãšæããŸãã Herokuã§ãã«ãã倱æããŸãããå®çšŒåç°å¢ã§ã®ã¿å€±æããŸãã ãã£ãã·ã¥ãç¡å¹ã«ãªã£ãŠããŸãã
Resolving node version ^7.2.1 via semver.io...
Downloading and installing node 7.2.1...
Using default npm version: 3.10.10
Resolving yarn version (latest) via semver.io...
Downloading and installing yarn (0.18.1)...
Installed yarn 0.18.1
-----> Restoring cache
Skipping cache restore (disabled by config)
-----> Building dependencies
Installing node modules (yarn)
yarn install v0.18.1
[1/4] Resolving packages...
[2/4] Fetching packages...
warning [email protected]: The platform "linux" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
error /tmp/build_0e4ff736ad0f25dc816a47543687fefc/bbb7b6e751dde291f65dea175f41a26862eef28f/node_modules/bcrypt: Command failed.
Exit code: 1
Command: sh
Arguments: -c node-pre-gyp install --fallback-to-build
Directory: /tmp/build_0e4ff736ad0f25dc816a47543687fefc/bbb7b6e751dde291f65dea175f41a26862eef28f/node_modules/bcrypt
Output:
module.js:472
throw err;
^
Error: Cannot find module 'abbrev'
at Function.Module._resolveFilename (module.js:470:15)
at Function.Module._load (module.js:418:25)
at Module.require (module.js:498:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/tmp/build_0e4ff736ad0f25dc816a47543687fefc/bbb7b6e751dde291f65dea175f41a26862eef28f/node_modules/nopt/lib/nopt.js:10:14)
at Module._compile (module.js:571:32)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:488:32)
at tryModuleLoad (module.js:447:12)
at Function.Module._load (module.js:439:3)
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
-----> Build failed
ç§ããã®åé¡ãæ±ããŠããŸãã yarn install --production
ãé©åãªäŸåé¢ä¿ãæ£ããã€ã³ã¹ããŒã«ããªããããçŸæç¹ã§ã¯ãŸã yarn install
ãæ¬çªç°å¢ã«äœ¿çšããŠããŸãã
Herokuãã«ãããã¯ã§yarn install --production
ã«ããŒãã³ãŒããããŠããããããããã§ããªãã®ã§ã¯ãªãããšæããŸãïŒhttps://github.com/heroku/heroku-buildpack-nodejs/issues/337ãåç
§ïŒ
@adamreisnzç³ãèš³ãããŸããããç§ã¯ããªãã®åé¡ã§ã¯ãªããå ã®åé¡ã«ã€ããŠèšåããŠããŸããã
ãã®åé¡ã®åé¿çãšããŠããã®åé¡ãä¿®æ£ããããŸã§ãä»ã®ãšãããã¹ãŠã®devDependencies
ãdependencies
ã«é
眮ããããšããå§ãããŸãã
@dashmugãããåé¡ãããŸããã
ãšã«ãããç§ã¯ãããããŒãªãœãªã¥ãŒã·ã§ã³ãããããåãããããYarnãããå®å®ãããŸã§ãHerokuã§npm
ã䜿çšããããšã奜ã¿ãŸãã yarn.lock
ã.gitignore
ã®ã§ãã¬ã/ herokuã«ã¢ããããŒããããŸããã ãã®ããã«ãYarnãããŒã«ã«ã§äœ¿çšããããšã¯ã§ããŸãããHerokuã®ãã«ãã«ã¯åœ±é¿ããŸããã
@adamreisnzããã¯yarn
ã䜿ããšããããªãã®ç®çãæã¡ç ŽããŸããã
@dashmugå°ãªããšããç§ãã¡ã«ãšã£ãŠã¯ããã§ã¯ãããŸããã ããã±ãŒãžããŒãžã§ã³ãæå®ã®äœçœ®ã«ããã¯ããããã«äœ¿çšããŠããŸããã éåžžã«ææ°ã®äŸåé¢ä¿ãããããèªåã®ãã·ã³ã§åäœããããšããåé¡ã¯ãããŸããã npmãä»ããŠyarnã«ç§»è¡ããäž»ãªçç±ã¯ãé床ã®ããã§ãããäŸåé¢ä¿ãå€ãè€éãªã¢ããªã®å Žåã npm install
5åããyarnã®22ç§ã«ãªããŸããã
糞ãäžå®å®ã§ããéããéçºã®ããã«ããŒã«ã«ã§ç³žã䜿çšã§ããã€ã³ã¹ããŒã«ãé«éã§ããéããHerokuã§ã®ãã«ãããã»ã¹ã¯å°ãé ããªããŸã:)
Yarnã¯ãnpmã®ã»ãšãã©ã®ããããã€ã³ä»£æ¿åãšããŠå®£äŒãããŠããŸãã ãã ãããã®ãããªåé¡ãçºçãããŸã 解決ãããŠããªãããããã®ãŸãŸäœ¿çšããããšã¯ã§ããŸããã ãããã£ãŠãçŸæç¹ã§ã¯è¿œå ã®ããŒã«ãšèŠãªããŠããŸããããã¯ãããç®çã«ã¯åœ¹ç«ã¡ãŸãããå¥ã®ç®çã«ã¯ãŸã ãããŸããã ç§ã¯ãããããŸãããããšã¯ééããããŸãã:)
ããã¯0.18.1ã§ä¿®æ£ãããããã§ãã
Herokuã¯å€±æãããšãã«0.18.1ã䜿çšããŠããããããŸã ä¿®æ£ãããŠããŸããã
ãã®åé¡ã¯0.18.1ã§ä¿®æ£ãããŸããã
ç§ã®ä»¥åã®åçŸã¯0.18.1ã§ä¿®æ£ãããŠããŸãð
ææ¥ã¯æ¬ç©ã®ã¢ããªã§ãã£ãŠã¿ãŸã
0.18.1ã§åé¡ãä¿®æ£ãããŸããã ç§ã¯å¹žããªãã£ã³ãã³ã°ã«ãŒã§ãð
以åã¯å€±æããŠããéèŠãªã¢ããªã§0.18.1ãè©ŠããŸããããçŸåšã¯æ©èœããŠããããã§ãã ð
ãããããã£ãŠã¿ãããšæããŸã:)
ç³ãèš³ãããŸãããããŸã 0.18.1ã§ã¯åäœããŸããã
-----> Node.js app detected
-----> Creating runtime environment
NPM_CONFIG_LOGLEVEL=error
NPM_CONFIG_PRODUCTION=true
NODE_ENV=production
NODE_MODULES_CACHE=true
-----> Installing binaries
engines.node (package.json): ^7.2.1
engines.npm (package.json): unspecified (use default)
Resolving node version ^7.2.1 via semver.io...
Downloading and installing node 7.2.1...
Using default npm version: 3.10.10
Resolving yarn version (latest) via semver.io...
Downloading and installing yarn (0.18.1)...
Installed yarn 0.18.1
-----> Restoring cache
Loading 2 from cacheDirectories (default):
- node_modules
- bower_components (not cached - skipping)
-----> Building dependencies
Installing node modules (yarn)
yarn install v0.18.1
[1/4] Resolving packages...
[2/4] Fetching packages...
warning [email protected]: The platform "linux" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
error /tmp/build_c86802dccae94b3fb074d3b88f3f63f2/9512deeed23c0eca48d68fb2c8850a28f76692ea/node_modules/bcrypt: Command failed.
Exit code: 1
Command: sh
Arguments: -c node-pre-gyp install --fallback-to-build
Directory: /tmp/build_c86802dccae94b3fb074d3b88f3f63f2/9512deeed23c0eca48d68fb2c8850a28f76692ea/node_modules/bcrypt
Output:
module.js:472
throw err;
^
Error: Cannot find module 'abbrev'
at Function.Module._resolveFilename (module.js:470:15)
at Function.Module._load (module.js:418:25)
at Module.require (module.js:498:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/tmp/build_c86802dccae94b3fb074d3b88f3f63f2/9512deeed23c0eca48d68fb2c8850a28f76692ea/node_modules/nopt/lib/nopt.js:10:14)
at Module._compile (module.js:571:32)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:488:32)
at tryModuleLoad (module.js:447:12)
at Function.Module._load (module.js:439:3)
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
-----> Build failed
We're sorry this build is failing! You can troubleshoot common issues here:
https://devcenter.heroku.com/articles/troubleshooting-node-deploys
Some possible problems:
- A module may be missing from 'dependencies' in package.json
https://devcenter.heroku.com/articles/troubleshooting-node-deploys#ensure-you-aren-t-relying-on-untracked-dependencies
- This module may be specified in 'devDependencies' instead of 'dependencies'
https://devcenter.heroku.com/articles/nodejs-support#devdependencies
Love,
Heroku
! Push rejected, failed to compile Node.js app.
! Push failed
NODE_MODULES_CACHE=false
èšå®ããŠã圹ã«ç«ã¡ãŸãã
äŸåé¢ä¿ããªãŒã¯æ¬¡ã®ãšããã§ãã
ââ⬠[email protected]
â ââ⬠[email protected]
â ââ⬠[email protected]
â ââ⬠[email protected]
â ââ⬠[email protected]
â âââ [email protected]
ââ⬠[email protected]
â ââ⬠@google-cloud/[email protected]
â ââ⬠@google-cloud/[email protected]
â ââ⬠[email protected]
â ââ⬠[email protected]
â ââ⬠[email protected]
â âââ [email protected]
ââ⬠[email protected]
âââ [email protected]
åé¡ã¯google-cloud
ä»ããæ·±ãäŸåé¢ä¿ã ãšæããŸãã ããã¯æ¬çªã¢ãžã¥ãŒã«ã§ããã bable-cli
ãšinstanbul
ã¯ã©ã¡ããéçºè
å°çšã§ãã
ããã«ã yarn why abbrev
ã䜿çšãããšã google-cloud
ãšbabel-cli
芪ã®æ¶é€å®¶æãååŸã§ããŸããã
yarn why v0.18.1
[1/4] ð€ Why do we have the module "abbrev"...?
[2/4] ð Initialising dependency graph...
[3/4] ð Finding dependency...
[4/4] ð¡ Calculating file sizes...
info Reasons this module exists
- "istanbul" depends on it
- "istanbul#nopt" depends on it
@ jkrems ã @ SimonBãã®ããã®æ°ããåé¡ãæèµ·ããŸãããïŒ
istanbul#nopt
ãã why
åºåã§ééã£ãŠããããã«èŠããŸãã
ç§ã¯ä»ä»äºãããæ¹æ³ããããŸããããããå®éã®ã¢ããªã§ãã¹ãããŸã
@SimenBããããšãããããŸã
ç·šéïŒå®éã«ããã§ããã¯å¿µã®ããã§ããç§ã¯ä»å¯ãã€ããã§ãã
"dependencies": {
"bcrypt": "^1.0.1",
"bluebird": "^3.4.6",
"body-parser": "^1.15.2",
"chalk": "^1.1.3",
"compression": "^1.6.2",
"cookie-parser": "^1.4.3",
"cors": "^2.8.1",
"express": "^4.14.0",
"glob": "^7.1.1",
"google-cloud": "^0.45.1",
"handlebars": "^4.0.6",
"html-pdf": "^2.1.0",
"http-as-promised": "^1.1.0",
"meanie-express-error-handling": "git+https://github.com/meanie/express-error-handling#2.0.0",
"meanie-express-github-service": "^2.0.2",
"meanie-express-jwt-service": "^1.0.2",
"meanie-express-raven-service": "^1.0.1",
"meanie-mail-composer": "^1.2.0",
"meanie-mongoose-only-id": "^1.0.1",
"meanie-mongoose-set-properties": "^1.0.1",
"meanie-mongoose-to-json": "^1.1.0",
"meanie-multer-mime-types-filter": "^1.0.1",
"meanie-passport-refresh-strategy": "^1.1.2",
"moment": "^2.17.1",
"mongoose": "^4.7.3",
"morgan": "^1.7.0",
"multer": "^1.1.0",
"passport": "^0.3.2",
"passport-http-bearer": "^1.0.1",
"passport-local": "^1.0.0",
"phantomjs-prebuilt": "2.1.14",
"sendgrid": "^4.7.1",
"sendgrid-mailer": "^1.0.7",
"socket.io": "^1.7.2",
"yargs": "^6.5.0"
},
"devDependencies": {
"babel-cli": "^6.16.0",
"babel-preset-es2015": "^6.18.0",
"chai": "^3.5.0",
"chai-as-promised": "^6.0.0",
"dirty-chai": "^1.2.2",
"eslint": "^3.12.1",
"express-simulate-latency": "0.0.2",
"istanbul": "^1.0.0-alpha.2",
"mocha": "^3.2.0",
"mocha-clean": "^1.0.0",
"nodemon": "^1.11.0",
"sinon": "^1.17.6",
"sinon-as-promised": "^4.0.0",
"sinon-mongoose": "^1.3.0"
}
ããã¯ãåäœäžã®ã¢ããªã§ã¯ãŸã 倱æããŸãã ã€ãŒã³ã¯æ·±ãéããã©ãããšãã§ããªãããã§ãã ãããnpm ls entities
åŸã®yarn --prod
$ npm ls entities
[email protected] /Users/simbekkh/repos/frontpage
ââ⬠@finn-no/[email protected]
ââ⬠[email protected]
ââ⬠[email protected]
ââ⬠[email protected]
ââ⬠[email protected]
ââ⬠[email protected]
âââ UNMET DEPENDENCY entities@~1.1.1
npm ERR! missing: entities@~1.1.1, required by [email protected]
@adamreisnzãšåãããã«ã yarn why
ã¯æ£ããããªãŒãååŸããŸããã
$ yarn why entities
yarn why v0.18.1
[1/4] ð€ Why do we have the module "entities"...?
[2/4] ð Initialising dependency graph...
[3/4] ð Finding dependency...
[4/4] ð¡ Calculating file sizes...
info Reasons this module exists
- "cheerio" depends on it
- "cheerio#htmlparser2" depends on it
info Disk size without dependencies: "108kB"
info Disk size with unique dependencies: "108kB"
info Disk size with transitive dependencies: "108kB"
info Amount of shared dependencies: 0
âš Done in 0.40s.
istanbulïŒnoptããwhyåºåã§ééã£ãŠããããã«èŠããŸãã
ããã§ããããããã®åé¡ã®æ žå¿ã§ããå¯èœæ§ãé«ãããã§ãã nopt
ã¯ã google-cloud
ãbabel-cli
ã§ã¯ãªãã istanbul
ããã±ãŒãžã®äžéšã§ãããšèããããŠããããã§ãããã®ãããæ¬çªç°å¢ã«ã€ã³ã¹ããŒã«ãããŠããªãå¯èœæ§ããããŸãã istanbul
ã¯è£œåã®äŸåé¢ä¿ã§ã¯ãªããããç°å¢ã
ã¿ãªããããã®åé¡ããã°ããçºçããŠããããšããè©«ã³ç³ãäžããŸãã
ç§ã¯ãã®åé¡ãèªåèªèº«ã«å²ãåœãŠãçŸåšã¯åªå
床ãé«ãã®ã§ãäŒæäžã«ä¿®æ£ããããšããŸãã
åé¢ãããç Žå£ãã¹ããŸãã¯ä¿®æ£ïŒçæ³çã«ã¯ïŒã䌎ããã«ããšPRã¯å€§æè¿ã§ãã
gulp-imagemin
ã®ãªãã·ã§ã³ã®äŸåé¢ä¿ã®äŸåé¢ä¿ã§ããlib bl
prodenvã§ãåãåé¡ããããŸãð
[~/Workspaces/my-project 12:05:33] NODE_ENV=production yarn
yarn install v0.18.1
info No lockfile found.
[1/4] ð Resolving packages...
warning algoliasearch > [email protected]: Just use Array.isArray directly
warning gulp-file > through2 > xtend > [email protected]:
warning raven > [email protected]: use uuid module instead
warning wiredep > bower-config > [email protected]: graceful-fs v3.0.0 and before will fail on node releases >= v7.0. Please update to graceful-fs@^4.0.0 as soon as possible. Use 'npm ls graceful-fs' to find it in the tree.
warning chromedriver > [email protected]: this package has been reintegrated into npm and is now out of date with respect to npm
warning mversion > [email protected]: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
warning wiredep > glob > [email protected]: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
warning webdriverio > request > [email protected]: use uuid module instead
warning gulp > vinyl-fs > glob-watcher > gaze > globule > [email protected]: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
warning gulp > vinyl-fs > glob-watcher > gaze > globule > glob > [email protected]: graceful-fs v3.0.0 and before will fail on node releases >= v7.0. Please update to graceful-fs@^4.0.0 as soon as possible. Use 'npm ls graceful-fs' to find it in the tree.
warning sprity-lwip > lwip > decree > [email protected]: This package is discontinued. Use lodash@^4.0.0.
[2/4] ð Fetching packages...
warning [email protected]: The engine "ender" appears to be invalid.
[3/4] ð Linking dependencies...
[4/4] ð Building fresh packages...
[1/7] â fsevents: GET https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.0.15/fse-v1.0.15-node-v51-darwi
[2/7] â gifsicle
[3/7] â jpegtran-bin
[4/7] â optipng-bin
error /Users/fdubost/Workspaces/my-project/node_modules/gifsicle: Command failed.
Exit code: 1
Command: sh
Arguments: -c node lib/install.js
Directory: /Users/fdubost/Workspaces/my-project/node_modules/gifsicle
Output:
module.js:474
throw err;
^
Error: Cannot find module 'bl'
at Function.Module._resolveFilename (module.js:472:15)
at Function.Module._load (module.js:420:25)
at Module.require (module.js:500:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/Users/fdubost/Workspaces/my-project/node_modules/tar-stream/extract.js:2:10)
at Module._compile (module.js:573:32)
at Object.Module._extensions..js (module.js:582:10)
at Module.load (module.js:490:32)
at tryModuleLoad (module.js:449:12)
at Function.Module._load (module.js:441:3)
ããªãã®å©ããããããšãð
package.jsonã«bl
ãæåã§è¿œå ãããšæ©èœããŸã...
ããã«é¢ãããã¥ãŒã¹ã¯ãããŸããïŒ
ãŸã ãYarnã®å·»ãäžãããã³è§£æ±ºã¢ã«ãŽãªãºã https://github.com/yarnpkg/yarn/pull/2419ãšã¯ç¡é¢ä¿ã«node_modulesæ§é ãæ€èšŒããã¢ãããã¯commonJSãã§ãã«ãŒãæ§ç¯ããŠã
ãã®ãã°ã§èª¬æãããŠãããã¹ãŠã®ã±ãŒã¹ããã£ããããå°æ¥ã®ãªã°ã¬ãã·ã§ã³ããä¿è·ããããšãã§ããŸãã
@kittensã¯ãããã§äœãèµ·ãã£ãŠããã®ãã調ã¹ãŠããŸãã
ãã°ã¯äºçŽ°ãªããšã§ã¯ãªãã®ã§ãè¿œå ã®æŽå¯ã¯å€§æè¿ã§ã
äºè§£ããŸãããææ°ã®ãã©ã³ã¯ã§ãã¹ãŠã®åçŸãåéããŸãã
æåã®ã³ã¡ã³ãã®äŸã¯ããåçŸãããã yarn check --verify-tree
ã¯åæ Œã§ã
ãããåçŸãããŸããhttps://github.com/yarnpkg/yarn/issues/761#issuecomment-260975012ããã³https://github.com/yarnpkg/yarn/issues/761#issuecomment-265823529
ããããã®åçŸã¯0.18.1ã§ä¿®æ£ãããŸããã
2ã€ã®ã¢ã€ãã¢ïŒ
ç§ãããªããšå ±æã§ãã解決çãèµ·ãã£ãŠãããã°ã¯ãããŸããïŒ
ããã«ãè·å Žã§ãããåçŸããããã¯ãã¡ã€ã«ãæäŸããããšã¯ã§ããŸããããã©ã€ããŒãéšéã®ããã«ã€ã³ã¹ããŒã«ããããšã¯ã§ããŸããã ããã±ãŒãžã®ãã§ãããããã£ãŠã¹ãããããããªãŒããããããŸããããšãã§ãããããããŸãããïŒ
@SimenB ã
ãã®å Žåã¯ã次ã®ããšãè©Šãããšãã§ããŸãã
yarn install --production --verbose
yarn check --production --verify-tree
ææ°ã®ãã¹ã¿ãŒãã©ã³ãä»ãã
ãã°ãå
¬éããããªãå Žåã¯ã bestander @ gmail.comãŸã§ã¡ãã»ãŒãžãéã£ãŠ
ããã0.18.1ã¯ãŸã å£ããŠããŠã0.19ïŒãŸãã¯ãã¹ã¿ãŒïŒããã¹ãããŠããŸããã ããã§ãåçŸãããå ŽåïŒåžæããªãïŒïŒããã°ãéå ¬éã§éä¿¡ããŸã
ã¿ã€ãã«ã®åé¡ã解決ããã®ã§ããã®ã¿ã¹ã¯ãéããŸãããã
ãŸã å確èªããŠããªãæªè§£æ±ºã®ãã®ã2ã€ãããŸããïŒ2263ãšïŒ2141ã«ã³ã¡ã³ãããããã±ãŒã¹çšã«æ°ãããã®ãäœæããŠCCããŠãã ããã
2allïŒã€ã³ã¹ããŒã«ãæ£ãããªããšã³ã¡ã³ãããå Žåã¯ãä»ã®äººããããåçŸã§ããããã«package.jsonãå«ããŠãã ããã
ïŒãããªãã¹ããããäœããçŽ æŽãããREPROã¹ã¯ãªãããæåºããããã®@jkremsã«è³è³https://github.com/yarnpkg/yarn/issues/761#issuecomment -265823529
@bestander https://github.com/yarnpkg/yarn/issues/761#issuecomment -268130124ãå確èªããŸãããïŒ
@ adamreisnz ãpackage.jsonãããäžåºŠå ±æã§ããŸããïŒ
https://github.com/yarnpkg/yarn/issues/761#issuecomment-268130124ã¯å¥ã®åé¡ã§ãã
ããã¯yarn install --production
倱æããŸãã
ãã®åé¡ã¯ã yarn install --production
æ£åžžã«çµäºããããšã§ãããæ£ããæ©èœããŠããŸããã
@bestanderãã®äžã®ã³ã¡ã³ãã§å ±æããŸããã httpsïŒ //github.com/yarnpkg/yarn/issues/761#issuecomment -268201708ã也æ¯
ããã§ãç§ã«ãšã£ãŠã¯ãã¹ã¿ãŒïŒc98df16bïŒã§å€±æããŸã...
yarn check --verify-tree
ã¯ã¹ããŒããŸãããããã¯ææã§ãã ãããããããã®å€ãã¯éçºéšéã§ãã
yarn check v0.20.0-0
error "babel-preset-es2015" not installed
error "browserify-middleware" not installed
error "cheerio" not installed
error "codeceptjs" not installed
error "del-cli" not installed
error "eslint" not installed
error "eslint-config-finn" not installed
error "espower-loader" not installed
error "hashmark" not installed
error "interfake" not installed
error "nightmare" not installed
error "nightmare-upload" not installed
error "nock" not installed
error "nodemon" not installed
error "nyc" not installed
error "power-assert" not installed
error "sinon" not installed
error "supertest" not installed
error "uglifyify" not installed
error "@finn-no/express-base#nunjucks#chokidar#anymatch" not installed
error "@finn-no/express-base#unleash-client#request#json-stringify-safe" not installed
error "@finn-no/express-base#pretty-error#renderkid#css-select#domutils#dom-serializer#entities" not installed
error Found 22 errors.
ã¢ããªãå®è¡ãããšãäžèŽãããã®ãèŠã€ãããªããšå€±æããŸãã
npm ls
ã¯ãä»ã®äžè¶³ããŠããéšéã瀺ããŠããŸããããã¯ããçã«ããªã£ãŠããŸã
npm ERR! extraneous: [email protected] /Users/simbekkh/repos/frontpage/node_modules/node-pre-gyp
npm ERR! missing: anymatch@^1.3.0, required by [email protected]
npm ERR! missing: entities@~1.1.1, required by [email protected]
npm ERR! missing: json-stringify-safe@~5.0.1, required by [email protected]
ãããŠããããåé¡ã®èŠ³å¯/åå ã§ããïŒ https ïŒ
ããã§ããããããã®åé¡ã®æ žå¿ã§ããå¯èœæ§ãé«ãããã§ãã noptã¯google-cloudãbabel-cliã§ã¯ãªãistanbulããã±ãŒãžã®äžéšã§ãããšèããããŠããããã§ããããããistanbulãæ¬çªç°å¢ã«äŸåããŠããªããããæ¬çªç°å¢ã«ã€ã³ã¹ããŒã«ãããŠããªãçç±ãããããŸããã
ããããã¿ãŸããã @ SimonB
yarn check --prodution --verify-tree
ã³ã¡ã³ããç·šéããŸã
yarn check --verify-tree --production
ãå®è¡ãããšãè¯å¥œãªåºåãåŸãããŸãïŒ npm ls
ãšäžèŽããŸãïŒã
yarn check v0.20.0-0
error "@finn-no/express-base#nunjucks#chokidar#anymatch" not installed
error "@finn-no/express-base#unleash-client#request#json-stringify-safe" not installed
error "@finn-no/express-base#pretty-error#renderkid#css-select#domutils#dom-serializer#entities" not installed
error Found 3 errors.
@bestander package.jsonãyarn.lockãããã³è©³çŽ°ãªã€ã³ã¹ããŒã«ãã°ãã¡ãŒã«ã§éä¿¡ããŸãð
@dashmugãã®åé¡ã®æ°ãããã±ãããäœæããŸããïŒ ïŒæ¬çªçšã§ã¯ãããŸããïŒèª€ã£ãäŸåé¢ä¿ãã€ã³ã¹ããŒã«ãããŠãããšããåé¡ããŸã ããã®ã§ããã®ãã±ããã«é¢é£ããŠãããšæããŸãã
@bestanderã¡ãŒã«ãéä¿¡ãããŸããã
@finn-no/express-base
ã¯å
¬éãããŠããŸããããåºåå
ã®ä»ã®3ã€ã®ããã±ãŒãžã¯å
¬éãããŠãããããå
¬éããã±ãŒãžã®ã¿ã§è€è£œã§ããããšãé¡ã£ãŠããŸãã
æ°ããå·ãéãå¿ èŠããããŸããïŒ
@adamreisnz ãæ°ããåé¡ãäœæããŠ
åçŸã¯ã§ããŸãããã¿ã€ãã«ãšã¯å¥åé¡ã§ã
é¢é£ããŠããŸãã ããããåãåå ã§ãã ãã éãçç¶ã ã¿ã€ãã«ã®å 容ãšå šãåãã§ã¯ãªãã®ã§ãå¥ã®åé¡ãšããŠèããŸãã
@SimenB ãããããšããèŠãŠã¿ãŸã
倧äžå€«ã ãã
@bestanderåºåã«3ã€ã ããå«ãŸããŠããããã±ãŒãžãäœæããŠã倱æãããšããã¹ã¿ãŒã§ãããªãã¯ãããã ãã§åçŸå¯èœã«ãªããŸãã æå°éã®è€è£œã§ã¯ãããŸããããããã§ã
{
"name": "app",
"version": "1.0.0",
"dependencies": {
"brakes": "^2.5.1",
"compression": "^1.6.2",
"envalid": "^2.4.0",
"express": "^4.14.0",
"object.entries": "^1.0.4",
"prom-client": "^7.0.0",
"response-time": "^2.3.2",
"spaden": "^7.13.1",
"yarn-issue-repro-package": "^1.0.0"
},
"devDependencies": {
"babel-preset-es2015": "^6.18.0",
"browserify": "^13.1.1",
"browserify-middleware": "^7.1.0",
"cheerio": "^0.22.0",
"codeceptjs": "^0.4.13",
"del-cli": "^0.2.1",
"eslint": "^3.12.2",
"eslint-config-finn": "^1.0.1",
"espower-loader": "^1.0.1",
"hashmark": "^4.1.0",
"interfake": "^1.19.0",
"mocha": "^3.2.0",
"nightmare": "^2.9.0",
"nightmare-upload": "^0.1.1",
"nock": "^9.0.2",
"nodemon": "^1.11.0",
"nyc": "^10.0.0",
"power-assert": "^1.4.1",
"sinon": "^1.17.6",
"supertest": "^2.0.1",
"uglify-js": "^2.7.5",
"uglifyify": "^3.0.4"
}
}
package.json
ã®yarn-issue-repro-package
{
"name": "yarn-issue-repro-package",
"version": "1.0.0",
"main": "index.js",
"license": "MIT",
"dependencies": {
"nunjucks": "^2.5.2",
"pretty-error": "^2.0.2",
"unleash-client": "^1.0.0-beta.7"
}
}
èå³æ·±ãããšã«ã3ã€ã§ã¯ãªã4ã€ã®ãšã©ãŒãçºçããŸã...
$ yarn check v0.20.0-0 âââ [email protected]
error "yarn-issue-repro-package#nunjucks#chokidar#anymatch" not installed âââ [email protected]
error "yarn-issue-repro-package#unleash-client#request#json-stringify-safe" not installed ââš Done in 2.65s.
error "yarn-issue-repro-package#nunjucks#yargs#string-width#code-point-at" not installed â ~/repos/yarn-issue-repro-package î° vim package.json
error "yarn-issue-repro-package#pretty-error#renderkid#css-select#domutils#dom-serializer#entities" not installed â ~/repos/yarn-issue-repro-package î° npm publish
error Found 4 errors.
ãããåãåé¡ãã©ããã¯ããããŸããããåºåã¯æ¬¡ã®ãšããã§ãïŒ0.19.1ã§ãã¹ãæžã¿ïŒ
ã€ã³ã¹ããŒã«ã®åé¡ã®æ ¹æ¬çãªåå ãèŠã€ãããšæããŸãã
ããã±ãŒãžã®ã€ã³ã¹ããŒã«ã®å€±æã¯ã次ã®package.jsonã§åçŸã§ããŸãã
{ "dependencies": {
"bcrypt": "^1.0.1",
"gamepad": "1.4.2"
},
"devDependencies": {
"istanbul": "^1.0.0-alpha.2"
}
}
ãããŠãã³ãã³ã
rm -rf node_modules yarn.lock
yarn install
rm -rf node_modules
yarn install --production
npm ls abbrev
ãã®æ§æã§ã¯ã abbrev
ã¯ã€ã³ã¹ããŒã«ãããŸããã
abbrev
ã¯istanbul
ãšnopt
ã«ãã£ãŠäœ¿çšãããŸãïŒ yarn why abbrev
ãããããããã«ïŒã nopt
ã¯istanbul
ãšnode-pre-gyp
ã«ãã£ãŠäœ¿çšãããŸãïŒããã¯bcrypt
ãšgamepad
ã«ãã£ãŠäœ¿çšãããŸãïŒã
ããã±ãŒãžãã€ã¹ã¿ãŒã§abbrev
ãéè€æé€ããå Žåã次ã®ã³ãŒãã䜿çšããŠããã€ã¹ãã¬ã³ãŒãã®æ°ããisIgnoredé¢æ°ã決å®ããŸãã
// switch to non ignored if earlier deduped version was ignored
if (existing.isIgnored() && !info.isIgnored()) {
existing.isIgnored = info.isIgnored;
}
abbrev
ã¯ãåŠçãããæåã®å·»ãäžãã¬ã³ãŒãã®1ã€ã§ãã ãã®æç¹ã§ãæ¢åã®ã¬ã³ãŒãã¯istanbul#abbrev
ïŒ istanbul
ãç¡èŠãããããç¡èŠãããŸãïŒã§ãããéè€ã¬ã³ãŒãã¯istanbul#nopt#abbrev
ãããããåãçç±ã§ãã®æç¹ã§ç¡èŠãããŸãã ã
äž¡æ¹ã®ã¬ã³ãŒãããã®æç¹ã§ç¡èŠããããããç¡èŠé¢æ°ã¯æ³å®ã©ããã«èª¿æŽãããŸãããããã¯ã node-pre-gyp
ã«ããäŸåé¢ä¿ã®ããã nopt
ãåŸã®éè€æé€ã§ç¡èŠãããªããªãããã§ãã äž¡æ¹ã®ã¬ã³ãŒãã®ç¡èŠã¹ããŒã¿ã¹ã¯ãã€ã§ãå€æŽãããå¯èœæ§ããããããæ°ããç¡èŠé¢æ°ã¯ããããæ··åããå¿
èŠããããŸãã
å®éããããã®è¡ã次ã®ããã«çœ®ãæãããšãã€ã³ã¹ããŒã«ã®åé¡ã¯ãªããªããŸãã
// switch to non ignored if earlier deduped version was ignored
if (existing.isIgnored()) {
if (info.isIgnored()) {
// both are ignored now, but any one could become non ignored later on.
let oldIsIgnored = existing.isIgnored;
existing.isIgnored = () => oldIsIgnored() && info.isIgnored();
} else {
existing.isIgnored = info.isIgnored;
}
}
@blexrob ãçŽ æŽãããçºèŠïŒ
PRãéã£ãŠããã ããŸãããïŒ
Integration.jsã«ã¯ãã-productionã䜿çšããŠã€ã³ã¹ããŒã«ãããšãã«äŸåé¢ä¿ã倱ãããªãããã«ããããšããç¡å¹ãªãã¹ãããããŸããããã¯ä»ããä¿®æ£ããå¿
èŠããããŸãã
@bestander ããã¹ãããã°ãã
d#es5-ext -> es6-symbol#es5-ext -> es6-set#es5-ext -> es6-iterator#es5-ext -> es6-map#es5-ext -> es5-ext#es6-iterator -> es6-set#es6-iterator -> es6-weak-map#es6-iterator -> event-emitter#es5-ext -> d#es5-ext
ã ãããçŽ æŽãªååž°åŒã³åºãã¢ãããŒããåºãŠããŸã...
ãããå°ã調æŽãå¿ èŠã ãšæããŸãããã¢ã€ãã¢ã¯æ£ããããã§ã
ã€ãŒã³0.27.5-1ã®phantomjs-prebuilt
ã¢ãžã¥ãŒã«ïŒäŸåé¢ä¿ã®äŸåæ§ãšããŠïŒã§ãã®ãããªåé¡ãçºçããŸãã
ã ããä»ç§ã¯yarn install --production
åã«ãããŒã®yarn add phantomjs-prebuilt
yarn install --production
ãŸãã
æ®å¿µãªãããããã¯Yarn1.3.2ã§ã¯ãŸã åé¡ã®ããã§ãã
Yarn 1.3.2ã䜿çšãããšãNetlifyã§ã®ãã«ãã倱æããŸãããYarn0.18.2ã§ã¯æåããŸãã
cannot find module 'are-we-there-yet'
ã§ãæ¬çªãã©ã°ã®ã¿ã®ãã«ããšã©ãŒã
@adamreisnz ããã®ã¹ã¬ããã¯å€§ããããŠãã¹ãŠã®åé¡ã远跡ã§ããŸããã
reproã¹ã¯ãªããã§æ°ãããã®ãè²ãŠãŠããããŸããïŒ
@bestanderå®äºãããããšãã
ããã§ãåäœããã jqãã€ã³ã¹ããŒã«ããããªã人ã¯
$ python -c "import json; p = json.loads(open('package.json').read()); del p['devDependencies']; open('package.json', 'w').write(json.dumps(p, indent=2));"
ç§ã¯lerna
ã¢ãã¬ãã®ç³ž1.17.3
ãšããŒãv10.16.2
ã䜿çšããŠããŸãã ãŸã åãåé¡ã«çŽé¢ããŠããŸãã
ç§ã確èªã§ããŸãã
äŸåé¢ä¿ã¯ãããããããŸããã yarn install --production
ã䜿çšãããšã2ã€ã®ã¢ãžã¥ãŒã«ããã€ã³ã¹ããŒã«ãããŸããã
ãã ããç§ã¯@hannadrehmanã«äŒŒãLerna monorepoã䜿çšããŠYarnã¯ãŒã¯ã¹ããŒã¹ããã
糞ããŒãžã§ã³ïŒ1.22.0
ããŒãïŒv12.16.1
ãã ãã npm install --production
ã¯å®å
šã«æ©èœããŸãã
@hannadrehmanã¯ãåé¡ã®ãããžã§ã¯ããããªãã®ã¢ãã¬ãã®ããã±ãŒãžã§ããïŒ
@ TAnas0ãšåãåé¡
æãåèã«ãªãã³ã¡ã³ã
ã¿ãªããããã®åé¡ããã°ããçºçããŠããããšããè©«ã³ç³ãäžããŸãã
ç§ã¯ãã®åé¡ãèªåèªèº«ã«å²ãåœãŠãçŸåšã¯åªå 床ãé«ãã®ã§ãäŒæäžã«ä¿®æ£ããããšããŸãã
åé¢ãããç Žå£ãã¹ããŸãã¯ä¿®æ£ïŒçæ³çã«ã¯ïŒã䌎ããã«ããšPRã¯å€§æè¿ã§ãã