mirror of
https://github.com/tobspr/shapez.io.git
synced 2025-12-10 00:31:51 +00:00
build fixes
This commit is contained in:
parent
24ceb6664d
commit
bd781f8750
7
.github/workflows/ci.yml
vendored
7
.github/workflows/ci.yml
vendored
@ -38,13 +38,6 @@ jobs:
|
|||||||
- name: Lint
|
- name: Lint
|
||||||
run: |
|
run: |
|
||||||
yarn lint
|
yarn lint
|
||||||
- name: TSLint
|
|
||||||
run: |
|
|
||||||
cd gulp
|
|
||||||
yarn gulp translations.fullBuild
|
|
||||||
yarn gulp localConfig.findOrCreate
|
|
||||||
cd ..
|
|
||||||
yarn tslint
|
|
||||||
|
|
||||||
yaml-lint:
|
yaml-lint:
|
||||||
name: yaml-lint
|
name: yaml-lint
|
||||||
|
|||||||
@ -2,6 +2,7 @@ import gulp from "gulp";
|
|||||||
import BrowserSync from "browser-sync";
|
import BrowserSync from "browser-sync";
|
||||||
const browserSync = BrowserSync.create({});
|
const browserSync = BrowserSync.create({});
|
||||||
import path from "path/posix";
|
import path from "path/posix";
|
||||||
|
import pathNative from "path";
|
||||||
import deleteEmpty from "delete-empty";
|
import deleteEmpty from "delete-empty";
|
||||||
import { execSync } from "child_process";
|
import { execSync } from "child_process";
|
||||||
|
|
||||||
@ -189,12 +190,16 @@ function serveHTML({ version = "web-dev" }) {
|
|||||||
|
|
||||||
// Watch the build folder and reload when anything changed
|
// Watch the build folder and reload when anything changed
|
||||||
const extensions = ["html", "js", "png", "gif", "jpg", "svg", "mp3", "ico", "woff2", "json"];
|
const extensions = ["html", "js", "png", "gif", "jpg", "svg", "mp3", "ico", "woff2", "json"];
|
||||||
gulp.watch(extensions.map(ext => path.join(buildFolder, "**", "*." + ext))).on("change", function (path) {
|
gulp.watch(extensions.map(ext => path.join(buildFolder, "**", "*." + ext))).on("change", function (p) {
|
||||||
return gulp.src(path).pipe(browserSync.reload({ stream: true }));
|
return gulp
|
||||||
|
.src(pathNative.resolve(p).replaceAll(pathNative.sep, path.sep))
|
||||||
|
.pipe(browserSync.reload({ stream: true }));
|
||||||
});
|
});
|
||||||
|
|
||||||
gulp.watch("../src/js/built-temp/*.json").on("change", function (path) {
|
gulp.watch("../src/js/built-temp/*.json").on("change", function (p) {
|
||||||
return gulp.src(path).pipe(browserSync.reload({ stream: true }));
|
return gulp
|
||||||
|
.src(pathNative.resolve(p).replaceAll(pathNative.sep, path.sep))
|
||||||
|
.pipe(browserSync.reload({ stream: true }));
|
||||||
});
|
});
|
||||||
|
|
||||||
gulp.series("js." + version + ".dev.watch")(() => true);
|
gulp.series("js." + version + ".dev.watch")(() => true);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user