canoe-blog
canoe-blog copied to clipboard
install the node dependencies 😭 install 不了
非常喜欢这个主题,,,就是没有学过前端,不知道怎么弄 😭
首先安装nodejs,下载镜像 然后打开命令行,在项目目录里面执行:
npm install --registry=https://registry.npm.taobao.org
PS: 后面那个参数是为了使用淘宝的仓库
还是err,哎😐
那就贴err,把你做的步骤贴出来(元旦不陪妹子跨年,还搞这些干啥子呦🌚
同无法安装啊 ``E:\zhangzp\canoe-blog-master ([email protected]) λ yarn global add gulp yarn global v1.3.2 [1/4] Resolving packages... [2/4] Fetching packages... [3/4] Linking dependencies... [4/4] Building fresh packages... success Installed "[email protected]" with binaries: - gulp Done in 6.49s.
E:\zhangzp\canoe-blog-master ([email protected])
λ yarn install
yarn install v1.3.2
info No lockfile found.
[1/4] Resolving packages...
warning gulp > [email protected]: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
warning gulp > vinyl-fs > [email protected]: please upgrade to graceful-fs 4 for compatibility with current and future versions of Node.js
warning gulp > vinyl-fs > glob-stream > [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 > [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]: please upgrade to graceful-fs 4 for compatibility with current and future versions of Node.js
warning gulp-clean > [email protected]: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
warning gulp-clean > through2 > xtend > [email protected]:
warning gulp-htmlmin > [email protected]: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
warning gulp-imagemin > [email protected]: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
warning gulp-imagemin > imagemin-optipng > optipng-bin > bin-wrapper > download > gulp-decompress > [email protected]: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
warning gulp-plumber > [email protected]: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
warning gulp-sass > [email protected]: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
[2/4] Fetching packages...
info [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.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
[1/7] ⠠ uws
[6/7] ⠠ nodejieba: E:\zhangzp\canoe-blog-master\node_modules\nodejieba\build\nodeji
[-/7] ⠠ waiting...
[7/7] ⠐ pngquant-bin
error E:\zhangzp\canoe-blog-master\node_modules\nodejieba: Command failed.
Exit code: 1
Command: node-gyp rebuild
Arguments:
Directory: E:\zhangzp\canoe-blog-master\node_modules\nodejieba
Output:
E:\zhangzp\canoe-blog-master\node_modules\nodejieba>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\....\node_modules\node-gyp\bin\node-gyp.js" rebuild ) else (node "" rebuild )
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | win32 | x64
gyp info spawn C:\Python27\python.EXE
gyp info spawn args [ 'C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\gyp_main.py',
gyp info spawn args 'binding.gyp',
gyp info spawn args '-f',
gyp info spawn args 'msvs',
gyp info spawn args '-G',
gyp info spawn args 'msvs_version=auto',
gyp info spawn args '-I',
gyp info spawn args 'E:\zhangzp\canoe-blog-master\node_modules\nodejieba\build\config.gypi',
gyp info spawn args '-I',
gyp info spawn args 'C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\addon.gypi',
gyp info spawn args '-I',
gyp info spawn args 'C:\Users\Administrator\.node-gyp\8.0.0\include\node\common.gypi',
gyp info spawn args '-Dlibrary=shared_library',
gyp info spawn args '-Dvisibility=default',
gyp info spawn args '-Dnode_root_dir=C:\Users\Administrator\.node-gyp\8.0.0',
gyp info spawn args '-Dnode_gyp_dir=C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp',
gyp info spawn args '-Dnode_lib_file=node.lib',
gyp info spawn args '-Dmodule_root_dir=E:\zhangzp\canoe-blog-master\node_modules\nodejieba',
gyp info spawn args '-Dnode_engine=v8',
gyp info spawn args '--depth=.',
gyp info spawn args '--no-parallel',
gyp info spawn args '--generator-output',
gyp info spawn args 'E:\zhangzp\canoe-blog-master\node_modules\nodejieba\build',
gyp info spawn args '-Goutput_dir=.' ]
gyp info spawn C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe
gyp info spawn args [ 'build/binding.sln',
gyp info spawn args '/clp:Verbosity=minimal',
gyp info spawn args '/nologo',
gyp info spawn args '/p:Configuration=Release;Platform=x64' ]
在此解决方案中一次生成一个项目。若要启用并行生成,请添加“/m”开关。
E:\zhangzp\canoe-blog-master\node_modules\nodejieba\build\nodejieba.vcxproj(20,3): error MSB4019: 未找到导入的项目“E:\Microsoft.Cpp.Default.props”。请确认 <Import> 声明中的路径正确,
且磁盘上存在该文件。
gyp ERR! build error
gyp ERR! stack Error: C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe
failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\build.js:285:23)
gyp ERR! stack at emitTwo (events.js:125:13)
gyp ERR! stack at ChildProcess.emit (events.js:213:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:197:12)gyp ERR! System Windows_NT 10.0.16299
gyp ERR! command "C:\Program Files\nodejs\node.exe" "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" "rebuild"
gyp ERR! cwd E:\zhangzp\canoe-blog-master\node_modules\nodejieba``
这是nodejieba在windows上安装的问题。可以参考一下: https://github.com/yanyiwu/nodejieba/issues/70
确实,不过我按照参考操作之后nodejieba依旧无法安装,已经放弃windows了,Linux无任何错误
C:\Users\Administrator\.node-gyp\8.0.0\Release\node.lib : fatal error LNK1107: invalid or corrupt file: cannot read at 0x2DB9F4 [E:\zhangzp\canoe-blog-master\node_modules\nodejieba\build\nodejieba.vcxproj]
gyp ERR! build error
gyp ERR! stack Error: `C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe` failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\build.js:285:23)
gyp ERR! stack at emitTwo (events.js:125:13)
gyp ERR! stack at ChildProcess.emit (events.js:213:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:197:12)gyp ERR! System Windows_NT 10.0.16299
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd E:\zhangzp\canoe-blog-master\node_modules\nodejieba
我的天,看来nodejieba在windows上真的坑的不行
- npm install nodejieba -g --registry=https://registry.npm.taobao.org 安装nodejieba
- npm install -g node-gyp --registry=https://registry.npm.taobao.org 安装 node-gyb
- 还有 python要 2.7 😄 Install Error: Can't find Python executable #28
npm --add-python-to-path='true' --debug install --global windows-build-tools @lesoleil
@Mason-Xu 非常感谢,不过我放弃Win了 = =