This repository has been archived by the owner on Mar 26, 2021. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Sean Sun
committed
Jan 21, 2016
1 parent
f84730a
commit ce13ed6
Showing
6 changed files
with
17 additions
and
44 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
var gulp = require('gulp'); | ||
var sass = require('gulp-sass'); | ||
var autoprefixer = require('gulp-autoprefixer'); | ||
|
||
// 一次性编译 Sass | ||
gulp.task('sass', function() { | ||
return gulp.src('./source/scss/*.scss') | ||
.pipe(sass({outputStyle: 'compressed'})) | ||
.pipe(autoprefixer()) | ||
.pipe(gulp.dest('./source/css')); | ||
}); | ||
|
||
// 实时编译 | ||
gulp.task('default', ['sass'], function() { | ||
gulp.watch('./source/scss/_partial/*.scss', ['sass']); | ||
gulp.watch('./source/scss/*.scss', ['sass']); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters