Skip to content

Commit

Permalink
🔧 chore: Migrate to ESM for Gulp, update Gulp deps, update CI to use …
Browse files Browse the repository at this point in the history
…Node 20
  • Loading branch information
Spiderpig86 committed Jan 26, 2024
1 parent 2768afb commit 3697dee
Show file tree
Hide file tree
Showing 9 changed files with 28 additions and 23 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
strategy:
matrix:
node_version:
- 16
- 20
os:
# - macos
- ubuntu
Expand Down
2 changes: 1 addition & 1 deletion dist/cirrus-all.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Cirrus 0.7.2-patch.1
* Stanley Lim, Copyright 2023
* Stanley Lim, Copyright 2024
* https://spiderpig86.github.io/Cirrus
*/
@charset "UTF-8";
Expand Down
2 changes: 1 addition & 1 deletion dist/cirrus-all.min.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/cirrus-core.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Cirrus 0.7.2-patch.1
* Stanley Lim, Copyright 2023
* Stanley Lim, Copyright 2024
* https://spiderpig86.github.io/Cirrus
*/
/* v1 Color scheme for Cirrus */
Expand Down
2 changes: 1 addition & 1 deletion dist/cirrus-core.min.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/cirrus.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Cirrus 0.7.2-patch.1
* Stanley Lim, Copyright 2023
* Stanley Lim, Copyright 2024
* https://spiderpig86.github.io/Cirrus
*/
@charset "UTF-8";
Expand Down
2 changes: 1 addition & 1 deletion dist/cirrus.min.css

Large diffs are not rendered by default.

32 changes: 19 additions & 13 deletions gulpfile.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
const prop = require('./package.json');
const minify = require('gulp-clean-css');
const sass = require('gulp-sass')(require('sass')); // Use Dart Sass;
const gulp = require('gulp');
const $ = require('gulp-load-plugins')();
const sizereport = require('gulp-sizereport');
const gzip = require('gulp-gzip');
import prop from './package.json' assert { type: 'json' };
import minify from 'gulp-clean-css';
import dartSass from 'sass';
import gulpSass from 'gulp-sass';
const sass = gulpSass(dartSass);
import gulp from 'gulp';
// import gulpLoadPlugins from 'gulp-load-plugins';
// const $ = gulpLoadPlugins();
import concat from 'gulp-concat';
import header from 'gulp-header';
import sizereport from 'gulp-sizereport';
import gzip from 'gulp-gzip';
import size from 'gulp-size';
const head =
'/*\r\n* Cirrus ' +
prop.version +
Expand Down Expand Up @@ -40,9 +46,9 @@ function generateGulpBuild(taskName, sassFilePath, outputName) {
}
})
)
.pipe($.concat(`${outputName}.css`))
.pipe($.header(head))
.pipe($.size())
.pipe(concat(`${outputName}.css`))
.pipe(header(head))
.pipe(size())
.pipe(gulp.dest('./dist/'))
.on('error', (err) => {
console.error(err);
Expand Down Expand Up @@ -86,9 +92,9 @@ function generateGulpBuild(taskName, sassFilePath, outputName) {
}
)
)
.pipe($.header(head))
.pipe($.size())
.pipe($.concat(`${outputName}.min.css`))
.pipe(header(head))
.pipe(size())
.pipe(concat(`${outputName}.min.css`))
.pipe(gulp.dest('./dist/'))
.on('error', (err) => {
console.error(`Error encountered for task ${taskName}. Failing.`);
Expand Down
5 changes: 2 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,9 @@
"gulp": "^4.0.2",
"gulp-build": "^0.5.3",
"gulp-clean-css": "^4.2.0",
"gulp-cli": "^2.0.1",
"gulp-concat": "^2.6.1",
"gulp-gzip": "^1.4.2",
"gulp-header": "^2.0.5",
"gulp-load-plugins": "^2.0.1",
"gulp-size": "^5.0.0",
"jest-environment-node-single-context": "^29.2.0"
},
Expand All @@ -61,5 +59,6 @@
"sass": "^1.51.0",
"sass-true": "^7.0.1"
},
"snyk": true
"snyk": true,
"type": "module"
}

0 comments on commit 3697dee

Please sign in to comment.