Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gulpfile.js - github.com/htdvisser/hugo-base16-theme.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 6403389a148ab8976f3e2060c0ec571f46772e75 (plain)
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
const postcss = require('gulp-postcss');
const gulp = require('gulp');
const sourcemaps = require('gulp-sourcemaps');
const env = require('postcss-preset-env');

const paths = {
  css: {
    src: 'src/css/style.css',
    dest: 'static/css/',
  },
};

function build() {
  gulp.src(paths.css.src)
    .pipe(sourcemaps.init())
    .pipe(postcss([
      env({
        browsers: 'last 2 versions',
        features: {
          'css-variables': { preserve: false },
          'mediaqueries-custom-mq': true,
        },
      }),
    ]))
    .pipe(sourcemaps.write('.'))
    .pipe(gulp.dest(paths.css.dest));
}

gulp.task('build', build);