fix(build): skip protected deletion check outside git worktree
Some checks are pending
sf self-deploy / build, test, and publish server image (push) Waiting to run
sf self-deploy / upgrade vega source server (push) Blocked by required conditions
sf self-deploy / deploy test and probe (push) Blocked by required conditions
sf self-deploy / promote prod (push) Blocked by required conditions
Some checks are pending
sf self-deploy / build, test, and publish server image (push) Waiting to run
sf self-deploy / upgrade vega source server (push) Blocked by required conditions
sf self-deploy / deploy test and probe (push) Blocked by required conditions
sf self-deploy / promote prod (push) Blocked by required conditions
This commit is contained in:
parent
a6797cf3ae
commit
565cd1069a
1 changed files with 8 additions and 0 deletions
|
|
@ -1,8 +1,16 @@
|
|||
#!/usr/bin/env node
|
||||
import { execFileSync } from "node:child_process";
|
||||
import { existsSync } from "node:fs";
|
||||
|
||||
const PROTECTED_PATHS = [":(glob)src/resources/extensions/**/*.d.ts"];
|
||||
|
||||
if (!existsSync(".git")) {
|
||||
process.stdout.write(
|
||||
"check-protected-deletions: skipped outside git worktree\n",
|
||||
);
|
||||
process.exit(0);
|
||||
}
|
||||
|
||||
function git(args) {
|
||||
return execFileSync("git", args, {
|
||||
stdio: ["ignore", "pipe", "pipe"],
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue