mirror of
https://github.com/tobspr/shapez.io.git
synced 2025-06-07 18:14:01 +00:00
Allow having local files with changes for deployments
This commit is contained in:
parent
766d9e943e
commit
c963c961a0
@ -107,9 +107,14 @@ gulp.task("utils.cleanup", $.sequence("utils.cleanBuildFolder", "utils.cleanBuil
|
|||||||
|
|
||||||
// Requires no uncomitted files
|
// Requires no uncomitted files
|
||||||
gulp.task("utils.requireCleanWorkingTree", cb => {
|
gulp.task("utils.requireCleanWorkingTree", cb => {
|
||||||
const output = $.trim(execSync("git status -su").toString("ascii"));
|
let output = $.trim(execSync("git status -su").toString("ascii")).replace(/\r/gi, "").split("\n");
|
||||||
|
|
||||||
|
// Filter files which are OK to be untracked
|
||||||
|
output = output.filter(x => x.indexOf(".local.js") < 0);
|
||||||
if (output.length > 0) {
|
if (output.length > 0) {
|
||||||
console.error("\n\nYou have unstaged changes, please commit everything first!");
|
console.error("\n\nYou have unstaged changes, please commit everything first!");
|
||||||
|
console.error("Unstaged files:");
|
||||||
|
console.error(output.join("\n"));
|
||||||
process.exit(1);
|
process.exit(1);
|
||||||
}
|
}
|
||||||
cb();
|
cb();
|
||||||
|
Loading…
Reference in New Issue
Block a user