-
Notifications
You must be signed in to change notification settings - Fork 288
/
gulpfile.js
30 lines (27 loc) · 842 Bytes
/
gulpfile.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
var fontName = 'seti',
gulp = require('gulp'),
iconfont = require('gulp-iconfont'),
iconfontCss = require('gulp-iconfont-css'),
svgmin = require('gulp-svgmin');
exports.font = function font () {
return gulp.src(['./icons/*.svg'])
.pipe(iconfontCss({
fontName: fontName,
path: './styles/_fonts/_template.less',
targetPath: '../seti.less/',
fontPath: './styles/_fonts/seti/'
}))
.pipe(iconfont({
normalize: true,
fontHeight: 1000,
fontName: fontName,
formats: ['ttf', 'eot', 'woff', 'woff2', 'svg']
}))
.pipe(gulp.dest('./styles/_fonts/seti/'));
};
exports.svg = function svg () {
return gulp.src('./icons/*.svg')
.pipe(svgmin())
.pipe(gulp.dest('./icons'));
};
exports.default = exports.icon = exports.icons = gulp.series([exports.svg, exports.font]);