feat: adapt pullfrog for gitea + ollama

This commit is contained in:
2026-05-31 01:01:00 -05:00
parent 36ac64a5b6
commit 2aca1a3aa3
183 changed files with 1419 additions and 28292 deletions
+31 -4
View File
@@ -1,7 +1,34 @@
#!/usr/bin/env node
// Self-bootstrapping entry point — only uses Node stdlib so it runs before
// node_modules exists. Installs deps, then dynamically imports the action.
import { runPullfrogCli } from "./runCli.ts";
import { existsSync } from "node:fs";
import { execSync } from "node:child_process";
import { fileURLToPath } from "node:url";
import { dirname } from "node:path";
runPullfrogCli({
cliArgs: ["gha"],
});
const dir = dirname(fileURLToPath(import.meta.url));
if (!existsSync(`${dir}/node_modules`)) {
console.error("» installing dependencies...");
execSync("npm install --no-fund --no-audit", {
cwd: dir,
stdio: "inherit",
timeout: 120_000,
});
}
const [{ main }, core] = await Promise.all([
import(`${dir}/main.ts`),
import("@actions/core"),
]);
main()
.then((result: { success: boolean; error?: string }) => {
if (!result.success) {
core.setFailed(result.error ?? "shockbot run failed");
}
})
.catch((err: unknown) => {
core.setFailed(err instanceof Error ? err.message : String(err));
});