【问题标题】:not able to npm install optipng in widnows 10无法在 Windows 10 中安装 optipng
【发布时间】:2020-07-13 06:47:32
【问题描述】:

当我尝试npm install optipng-bin 得到错误时

(node:18016) Warning: Setting the NODE_TLS_REJECT_UNAUTHORIZED environment variable to '0' makes TLS connections and HTTPS requests insecure by disabling certificate verification.

optipng-bin@7.0.0 postinstall D:\node_modules\optipng-bin

node lib/install.js

(node:9868) Warning: Setting the NODE_TLS_REJECT_UNAUTHORIZED environment variable to '0' makes TLS connections and HTTPS requests insecure by disabling certificate verification.

  ‼ self signed certificate in certificate chain

  ‼ optipng pre-build test failed

  i compiling from source

  × Error: Command failed: C:\Windows\system32\cmd.exe /s /c "./configure --with-system-zlib --prefix="D:\node_modules\optipng-bin\vendor" --bindir="D:\node_modules\optipng-bin\vendor""
'.' is not recognized as an internal or external command,
operable program or batch file.

【问题讨论】:

    标签: node.js npm npm-install npm-scripts


    【解决方案1】:

    经过this issue on GH之后,我尝试了这些命令:

    npm rebuild
    npm i
    

    它解决了我的问题。

    【讨论】:

      猜你喜欢
      • 2020-06-18
      • 1970-01-01
      • 2023-01-04
      • 2019-05-10
      • 1970-01-01
      • 1970-01-01
      • 2018-11-30
      • 2020-11-02
      相关资源
      最近更新 更多