sass02
新建一个文件夹
1 cd 进入文件夹 ,cd E:\360data\重要数据\桌面\sass,
2 compass creat hello:当前目录创建sass工程,
3 sass文件夹放置sass文件,stylesheets生成的css文件,
4 compass create --bare --sass-dir "sass" --css-dir "css" --images-dir "img" --javascripts-dir "js" 指定创建的目录
5 E:\360data\重要数据\桌面\sass\hello\sass ,创建demo1.scss文件写样式,编译sass demo1.scss demo1.css编译成css文件,
6 sass -watch demo1.scss:demo1.css当scss文件变化的时候css文件自动变化
7 compass compile 编译文件 compass watch 监视文件的变化
8 config.rb:config.rubby文件,定义了一些路径。 require 'compass/import-once/activate'
# Require any additional compass plugins here. # Set this to the root of your project when deployed:
http_path = "/"
css_dir = "stylesheets"
sass_dir = "sass"
images_dir = "images"
javascripts_dir = "javascripts" # You can select your preferred output style here (can be overridden via the command line):输出风格
# output_style = :expanded or :nested or :compact or :compressed # To enable relative paths to assets via compass helper functions. Uncomment: 是否使用绝对路径
# relative_assets = true # To disable debugging comments that display the original location of your selectors. Uncomment:是否使用注释
# line_comments = false
9 中文注释
Encoding.default_external = Encoding.find('utf-8') engine.rb文件路径:
C:\Ruby22-x64\lib\ruby\gems\2.2.0\gems\sass-3.4.15\lib\sass
demo1.scss
body{
background: lightgray;
font-size: 14px;
margin:0px;
margin-left:0px;
// this is the header style.
header{
font-weight: bold;
} footer{/*! This is the footer style.重要注释,压缩模式也会编译到css文件*/
text-align: center;
}
}
demo1.css
@charset "UTF-8";
body {
background: lightgray;
font-size: 14px; }
body header {
font-weight: bold; }
body footer {
/*! This is the footer style.重要注释,压缩模式也会编译到css文件*/
text-align: center; } /*# sourceMappingURL=demo1.css.map */
sass02的更多相关文章
随机推荐
- centos安装nvidia驱动
大部分 Linux 发行版都使用开源的显卡驱动 nouveau,对于 nvidia 显卡来说,还是闭源的官方驱动的效果更好.最明显的一点是,在使用 SAC 拾取震相的时候,使用官方显卡驱动在刷新界面的 ...
- 写入~/.bashrc 文件
1.进入~/.bashrc 文件 vim ~/.bashrc 2.按下I键,然后按Enter键 加入路径 3.按ESC键退出,再按:wq! 保存即可.
- 紫书 习题 11-17 UVa 1670 (图论构造)
一开始要符合题目条件, 那么肯定没有任何一个点是孤立的, 也就是说没有点的度数是1 所以我就想让度数是1的叶子节点相互连起来.然后WA 然后看这哥们的博客 https://blog.csdn.net/ ...
- 紫书 习题 8-23 UVa 1623 (set妙用 + 贪心)
这道题我是从样例中看出思路了 2 4 0 0 1 1 看这组数据, 输出的是No, 为什么呢?因为两个1之间没有神龙喝水, 所以一定会有水灾. 然后就启发了我,两次同一个湖的降水之间必须至少有一次神龙 ...
- C#打开或者创建一个文件,然后向其末尾写入数据的方法
原文:C#打开或者创建一个文件,然后向其末尾写入数据的方法 FileStream fs = new FileStream(@"d:\timetick.txt" ...
- 【cocos2d-x 3.7 飞机大战】 决战南海I (二) 我方飞机的实现
在上一篇中.我们实现了游戏的開始界面,接下来要实现游戏的主界面.主界面包括地图.我方飞机.敌机等 先来实现我方飞机 我方飞机具有哪些属性呢? 飞机要具有生命值.要有动画效果(尾部喷气),飞机不可以飞出 ...
- poj2280--Amphiphilic Carbon Molecules(扫描线+极角排序+转换坐标)
题目链接:id=2280">点击打开链接 题目大意:给出n个点的坐标.每一个点有一个值0或者1,如今有一个隔板(无限长)去分开着n个点,一側统计0的个数,一側统计1的个数,假设点在板上 ...
- 8、java高级面向对象-重载、构造器重载、初始化块、this、super、对象构造和初始化分析、覆盖、toString
1.方法的重载(overload) 同一个类中同时存在一个以上的同名函数,参数个数或类型不同或顺序不同,称为方法的重载. 和返回值无关! 构造器重载:非默认构造器和默认构造器其实就是方法的重载. 2. ...
- xp秘钥
TDCXC-M9FW9-3HQ28-CPXYR-YXQ3QCCBDF-9W9T8-K8B7M-83HJM-X2MCWP3MF6-BTDKT-KR7YF-X4BM9-4HD9TMCCWF-42JGF-W ...
- How to: Create Custom Configuration Sections Using ConfigurationSection
https://msdn.microsoft.com/en-us/library/2tw134k3.aspx You can extend ASP.NET configuration settings ...