feat: convert wake-on-lan into a plugin (B20)

This commit is contained in:
LukeGus committed 2026-09-24 15:49:55 -05:00
1 parent d4ec444558
commit 2ac7779eda
50 files changed
+17844 -199

No files matched your search

@@ -0,0 +1,15 @@
import { Zap } from "lucide-react";
import type { TermixApp } from "@termix/plugin-sdk/frontend";
import { hasMacAddress, wakeHost } from "./host-action.js";
export function activate(app: TermixApp): void {
app.registerHostAction({
id: "wake-on-lan",
titleKey: "hostAction.title",
icon: Zap,
kind: "open",
order: 50,
when: (host) => hasMacAddress(host as Record<string, unknown>),
run: (host) => wakeHost(app.api, app.t, String(host.id)),
});
}