MCPcopy Index your code
hub / github.com/anomalyco/opencode / evalPerm

Function evalPerm

packages/opencode/test/agent/agent.test.ts:28–31  ·  view source on GitHub ↗
(agent: Agent.Info | undefined, permission: string)

Source from the content-addressed store, hash-verified

26
27// Helper to evaluate permission for a tool with wildcard pattern
28function evalPerm(agent: Agent.Info | undefined, permission: string): PermissionV1.Action | undefined {
29 if (!agent) return undefined
30 return Permission.evaluate(permission, "*", agent.permission).action
31}
32
33function load<A>(fn: (svc: Agent.Interface) => Effect.Effect<A>) {
34 return Agent.Service.use(fn)

Callers 1

agent.test.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected