Update packages, Gulp, fix license

This commit is contained in:
lostinlight 2019-01-15 02:01:54 +03:00
parent cba0f55291
commit ad11f18ea8
6 changed files with 6953 additions and 4344 deletions

View File

@ -1,5 +1,5 @@
image: node:8.12
image: node:10.15.0
pages:
script:
@ -7,7 +7,6 @@ pages:
- npm install gulp -g
- gulp build --cwd ./themes/starter
- ./node_modules/hexo/bin/hexo generate
- find public -type f -iregex '.*\.\(htm\|html\|txt\|text\|js\|css\)$' -execdir gzip -f --keep {} \;
artifacts:
paths:
- public
@ -34,4 +33,5 @@ cert-renewal:
- git config --global user.email $GITLAB_USER_EMAIL
- chmod +x ./letsencrypt_generate.sh
- chmod +x ./letsencrypt_authenticator.sh
- chmod +x ./letsencrypt_cleanup.sh
- ./letsencrypt_generate.sh

View File

@ -78,11 +78,14 @@ nofollow:
noreferrer: true
noopener: true
html_minifier:
exclude:
keepClosingSlash: true
removeComments: true
collapseWhitespace: true
# hexo-yam minifier
neat_enable: true
neat_html:
enable: true
neat_css:
enable: false
neat_js:
enable: false
feed:
type: atom

11207
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -7,7 +7,7 @@
"url": "https://gitlab.com/fediverse/fediverse.gitlab.io.git"
},
"author": "lostinlight",
"license": "AGPL",
"license": "AGPL-3.0-or-later",
"hexo": {
"version": "3.7.1"
},
@ -16,41 +16,41 @@
"hexo": "^3.7.1",
"hexo-autonofollow": "git+https://gitlab.com/lostinlight/hexo-autonofollow.git",
"hexo-browsersync": "^0.3.0",
"hexo-deployer-git": "^0.3.1",
"hexo-deployer-git": "^1.0.0",
"hexo-generator-archive-i18n": "git+https://gitlab.com/lostinlight/hexo-generator-archive-i18n.git",
"hexo-generator-category": "^0.1.3",
"hexo-generator-feed": "^1.2.2",
"hexo-generator-index": "^0.2.1",
"hexo-generator-index-i18n": "^0.2.1",
"hexo-generator-tag": "^0.2.0",
"hexo-html-minifier": "0.0.2",
"hexo-pagination": "^0.1.0",
"hexo-processor-static": "^1.1.0",
"hexo-renderer-ejs": "^0.3.1",
"hexo-renderer-markdown-it": "^3.4.1",
"hexo-server": "^0.3.2"
"hexo-server": "^0.3.2",
"hexo-yam": "^1.0.4"
},
"devDependencies": {
"babel-core": "^6.26.3",
"babel-eslint": "^8.2.3",
"babel-eslint": "^10.0.1",
"babel-preset-es2015": "^6.24.1",
"gulp": "^3.9.1",
"gulp-autoprefixer": "^5.0.0",
"del": "^3.0.0",
"gulp": "^4.0.0",
"gulp-autoprefixer": "^6.0.0",
"gulp-babel": "^7.0.1",
"gulp-concat": "^2.6.1",
"gulp-cssnano": "^2.1.3",
"gulp-eslint": "^4.0.2",
"gulp-eslint": "^5.0.0",
"gulp-notify": "^3.2.0",
"gulp-plumber": "^1.2.0",
"gulp-rename": "^1.2.3",
"gulp-sass": "^4.0.1",
"gulp-sourcemaps": "^2.6.4",
"gulp-stylelint": "^5.0.0",
"gulp-tinypng-extended": "^1.5.0",
"gulp-typeset": "0.0.2",
"gulp-stylelint": "^8.0.0",
"gulp-uglify": "^3.0.0",
"imagemin-jpeg-recompress": "^5.1.0",
"run-sequence": "^2.2.1",
"webpack-stream": "^4.0.3"
"imagemin-jpeg-recompress": "^6.0.0",
"stylelint": "^9.9.0",
"uglifyjs-webpack-plugin": "^2.1.1",
"webpack-stream": "^5.2.1"
}
}

View File

@ -10,11 +10,9 @@
notify = require('../../node_modules/gulp-notify'),
plumber = require('../../node_modules/gulp-plumber'),
rename = require('../../node_modules/gulp-rename'),
runSequence = require('../../node_modules/run-sequence'),
sass = require('../../node_modules/gulp-sass'),
sourcemaps = require('../../node_modules/gulp-sourcemaps'),
stylelint = require('../../node_modules/gulp-stylelint'),
tinypng = require('../../node_modules/gulp-tinypng-extended'),
uglify = require('../../node_modules/gulp-uglify'),
webpack = require('../../node_modules/webpack-stream');
@ -109,46 +107,16 @@
return del(['source/js/*', 'source/css/*']);
});
// Images
// gulp.task('images', function() {
// return gulp.src('../../source/img/**/*')
// .pipe(imagemin([
// imagemin.gifsicle(),
// jpegRecompress({
// loops: 4,
// min: 50,
// max: 95,
// quality:'high'
// }),
// imagemin.optipng(),
// imagemin.svgo()
// ]))
// .pipe(gulp.dest('../../source/img'))
// });
gulp.task('tinypng', function () {
return gulp.src('../../source/img/**/*.{png,jpg,jpeg}')
.pipe(plumber())
.pipe(tinypng({
key: 'API_KEY',
sigFile: 'images/.tinypng-sigs',
log: true
}))
.pipe(gulp.dest('../../source/img'));
});
// Watch
gulp.task('watch', function() {
gulp.watch('./source/assets/scss/**/*.scss', ['styles:serve']);
gulp.watch('./source/assets/scripts/**/*.js', ['scripts:serve']);
gulp.watch('./source/assets/scss/**/*.scss', gulp.series('styles:serve'));
gulp.watch('./source/assets/scripts/**/*.js', gulp.series('scripts:serve'));
});
// Development Mode
gulp.task('default', function () {
runSequence('styles:lint', 'styles:serve', 'webpack', 'scripts:serve', 'vendor', 'watch');
});
gulp.task('default', gulp.series('styles:lint', 'styles:serve', 'webpack', 'scripts:serve', 'vendor', 'watch', function (done) { done();
}));
// Production Mode
gulp.task('build', function (done) {
runSequence('clean', 'styles:build', 'scripts:build', 'webpack', 'vendor', done);
});
gulp.task('build', gulp.series('clean', 'styles:build', 'scripts:build', 'webpack', 'vendor', function (done) { done();
}));

View File

@ -2,6 +2,7 @@
const UglifyJsPlugin = require('../../node_modules/uglifyjs-webpack-plugin');
module.exports = {
mode: 'production',
entry: {
main: './source/assets/scripts/crystalball'
},