安装ruby
sass是基于ruby的环境,所以安装sass之前需要安装ruby。rudy windows 的安装包官方下载地址是:https://rubyinstaller.org/downloads/
ruby -v //查看ruby是否安装成功
安装sass
gem install sass //安装sass
//网络慢可使用淘宝镜像安装
- $ gem sources --remove https://rubygems.org/
- $ gem sources -a https://ruby.taobao.org/ 【如果你系统不支持https,请将淘宝源更换成:gem sources -a http:
//gems.ruby-china.org】
(如果报错可以改为gem sources -a https://gems.ruby-china.com/
或gem sources -a https://gems.ruby-china.com/ )
- $ gem sources -l
*** CURRENT SOURCES ***
https://ruby.taobao.org
# 请确保只有 ruby.taobao.org
- $ gem install sass
sass检测、更新与下载
sass -v
gem update sass //更新
gem uninstall sass //卸载
kalola
下载 http://koala-app.com/index-zh.html
原创文章,作者:Maggie-Hunter,如若转载,请注明出处:https://blog.ytso.com/275197.html