首先要安装ruby
https://rubyinstaller.org/downloads/
ruby -v
//如安装成功会打印
ruby 2.2.2p95 (2015-04-13 revision 50295) [i386-mingw32]
//1.删除原gem源
gem sources --remove https://rubygems.org/
//2.添加国内gem源
gem sources --add https://gems.ruby-china.com/
//3.打印是否替换成功
gem sources -l
//4.更换成功后打印如下
https://gems.ruby-china.com
//安装如下(如mac安装遇到权限问题需加 sudo gem install sass)
gem install sass
gem install compass
编译sass
//scss文件夹下
node-sass -wro css scss/
网友评论