-
-
Notifications
You must be signed in to change notification settings - Fork 614
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
build: upgrade all npm dependencies and refactor Gulpfiles
- Loading branch information
Showing
8 changed files
with
4,691 additions
and
4,529 deletions.
There are no files selected for viewing
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 |
---|---|---|
|
@@ -9,3 +9,6 @@ charset = utf-8 | |
indent_style = space | ||
indent_size = 4 | ||
trim_trailing_whitespace = true | ||
|
||
[*.json] | ||
indent_size = 2 |
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,54 @@ | ||
// jshint node:true | ||
'use strict'; | ||
|
||
import gulp from 'gulp'; | ||
import gulpAutoprefixer from 'gulp-autoprefixer'; | ||
import gulpLivereload from 'gulp-livereload'; | ||
import gulpCleanCss from 'gulp-clean-css'; | ||
import gulpSassPlugin from 'gulp-sass'; | ||
import sass from 'sass'; | ||
import vinylPaths from 'vinyl-paths'; | ||
import {deleteSync} from 'del'; | ||
|
||
const gulpSass = () => gulpSassPlugin(sass)(); | ||
|
||
const mainStyle = 'scss/main.scss'; | ||
|
||
|
||
const clean = function () { | ||
return gulp.src('dist/*') | ||
.pipe(vinylPaths(deleteSync)); | ||
}; | ||
|
||
|
||
const styles = function () { | ||
return gulp.src(mainStyle) | ||
.pipe(gulpSass({ | ||
sass: 'sass', | ||
includePaths: ['sass'] | ||
})) | ||
.pipe(gulpAutoprefixer(['last 1 version', '> 1%', 'ff >= 20', 'ie >= 8', 'opera >= 12', 'Android >= 2.2'], {cascade: true})) | ||
.pipe(gulpCleanCss()) | ||
.pipe(gulp.dest('css/')); | ||
}; | ||
|
||
|
||
const watch = function () { | ||
gulp.watch(['scss/*.scss'], styles); | ||
|
||
gulp.watch(['css/**', 'img/*', 'js/*'], function (file) { | ||
gulpLivereload.changed(file); | ||
}); | ||
|
||
gulpLivereload.listen(); | ||
}; | ||
|
||
const build = gulp.series(styles); | ||
|
||
const buildAndWatch = gulp.series(build, watch); | ||
|
||
export default buildAndWatch; | ||
export { | ||
clean, | ||
build, | ||
}; |
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 |
---|---|---|
@@ -1,33 +1,19 @@ | ||
{ | ||
"name": "trumbowyg-github-page", | ||
"title": "Trumbowyg GitHub Page", | ||
"description": "GitHub page of Trumbowyg", | ||
"homepage": "http://alex-d.github.io/Trumbowyg", | ||
"private": true, | ||
"author": { | ||
"name": "Alexandre Demode (Alex-D)", | ||
"email": "[email protected]", | ||
"url": "http://alex-d.fr" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/Alex-D/Trumbowyg.git" | ||
}, | ||
"bugs": { | ||
"url": "https://github.com/Alex-D/Trumbowyg/issues" | ||
"url": "https://alex-d.fr" | ||
}, | ||
"license": "MIT", | ||
"devDependencies": { | ||
"gulp": "3.9.1", | ||
"gulp-autoprefixer": "6.0.0", | ||
"gulp-clean-css": "3.7.0", | ||
"gulp-livereload": "4.0.1", | ||
"gulp-load-plugins": "1.5.0", | ||
"gulp-sass": "4.0.2" | ||
}, | ||
"scripts": { | ||
"start": "gulp", | ||
"build": "gulp build", | ||
"test": "gulp test" | ||
"dev": "gulp", | ||
"clean": "gulp clean", | ||
"build": "gulp build" | ||
}, | ||
"volta": { | ||
"node": "18.12.1", | ||
"npm": "9.3.0" | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.