Coder Social home page Coder Social logo

Comments (6)

Lete114 avatar Lete114 commented on June 12, 2024

这个想法不错👍

from mini-nrm.

Lete114 avatar Lete114 commented on June 12, 2024

这个能解决 node-sass 下载失败的问题吗?

不能,因为 node-sass 在安装的时候自动执行下载脚本,因为它自己实现了一套下载程序,不受 npm 约束,所以 mini-nrm 无法解决此问题

from mini-nrm.

Lete114 avatar Lete114 commented on June 12, 2024

你可以试试在安装 node-sass 后手动执行 node node_modules/node-sass/scripts/install.js --sass-binary-site 自定义下载地址

cypresspuppeteer 也同 node-sass 一样自己实现了一套自动下载脚本

from mini-nrm.

so1ve avatar so1ve commented on June 12, 2024

https://antfu.me/posts/npm-binary-mirrors
设置一下sass镜像就行

from mini-nrm.

lizy0329-biubiubiu avatar lizy0329-biubiubiu commented on June 12, 2024

https://antfu.me/posts/npm-binary-mirrors 设置一下sass镜像就行

get!其实我意思是能够在运行 nrm use taobao 时,同时将这些 binary-mirrors 也一同写入 .bashrc 或 .zshrc 里,就不用分两步走了

from mini-nrm.

Lete114 avatar Lete114 commented on June 12, 2024

get!其实我意思是能够在运行 nrm use taobao 时,同时将这些 binary-mirrors 也一同写入 .bashrc 或 .zshrc 里,就不用分两步走了

没法弄

  1. 在 Windows 里没有 .bashrc 和 .zshrc
  2. 很难知道使用的是什么终端
  3. 写入环境变量的话,会对用户的环境变量造成污染
  4. 维护成本高,这些需要下载 binary 的包下载程序不统一,需要看源码或看文档才知道可以自定义下载镜像,而且环境变量名也不统一(如果都统一为包名_binary_download会好办一些)
  5. binary-mirrors 比较少

from mini-nrm.

Related Issues (1)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.