Skip to content

pantoken / ai/pantoken-ai/src / installAgentAssets

Swyddogaeth: installAgentAssets()

installAgentAssets(tool, dir?): string[]

Alffa

Ysgrifennu asedau asiant pantoken ar gyfer teclyn i mewn i repo defnyddiwr.

Paramedrau

tool

AgentTool | "all"

Teclyn penodol AgentTool, neu "all" ar gyfer pob ased.

dir?

string = "."

Y cyfeiriadur targed (diofyn ".").

Yn dychwelyd

string[]

Y llwybrau a ysgrifennwyd.

Enghreifftiau

Gosod asedau un declyn i mewn i repo

ts
import { installAgentAssets } from "@pantoken/ai";

const written = installAgentAssets("cursor", "./my-app");
// → ["my-app/.cursor/rules/pantoken.mdc"]

Gosod pob ased i mewn i'r cyfeiriadur cyfredol

ts
import { installAgentAssets } from "@pantoken/ai";

installAgentAssets("all");
// writes AGENTS.md, llms.txt, and the Cursor/Copilot/Windsurf/Claude assets