initial commit

This commit is contained in:
2025-11-16 15:57:18 +01:00
parent f97b165008
commit edd6c028e5
21 changed files with 673 additions and 15 deletions

21
src/efibootmgr.service.ts Normal file
View File

@@ -0,0 +1,21 @@
import { $ } from "bun";
import type z from "zod";
import type { BootEntries } from "./efibootmgr.schema";
export class EfiBootMgrService {
async reboot() {
await $`reboot`;
}
async setNextBoot(bootNum: string) {
await $`efibootmgr -n ${bootNum}`;
}
async listBootEntries(): Promise<z.output<typeof BootEntries>> {
const output = await $`efibootmgr`.text();
console.log(output);
return [];
}
}