agent-afk 5.50.0 → 5.51.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5,6 +5,7 @@ export interface ExecuteCommandOptions {
5
5
  agentCwd: string;
6
6
  sessionId?: string;
7
7
  timeoutMs: number;
8
+ pluginRoot?: string;
8
9
  }
9
10
  export interface CommandExecutorResult {
10
11
  decision: HookDecision;
@@ -14,17 +14,19 @@ export interface ResolvedCommandHook {
14
14
  type: 'command';
15
15
  command: string;
16
16
  timeoutMs: number;
17
+ pluginRoot?: string;
17
18
  }
18
19
  export interface ResolvedMatcherGroup {
19
20
  matcher?: string;
20
21
  hooks: ResolvedCommandHook[];
21
- tier?: 'user-global' | 'project-local';
22
+ tier?: 'user-global' | 'project-local' | 'plugin';
22
23
  }
23
24
  export type ResolvedHooksConfig = Partial<Record<HarnessHookEvent, ResolvedMatcherGroup[]>>;
24
25
  export interface LoadedHooksConfig {
25
26
  hooks: ResolvedHooksConfig;
26
27
  userGlobalEnabled: boolean;
27
28
  allowProjectHooks: boolean;
29
+ pluginHooksEnabled: boolean;
28
30
  sources: string[];
29
31
  warnings: string[];
30
32
  }
@@ -33,12 +35,18 @@ interface SingleFileResult {
33
35
  hooks: ResolvedHooksConfig;
34
36
  enableShellHooks: boolean;
35
37
  allowProjectHooks: boolean;
38
+ enablePluginHooks: boolean;
36
39
  sources: string[];
37
40
  warnings: string[];
38
41
  }
39
- export declare function loadHooksConfigFile(path: string, tier: 'user-global' | 'project-local'): SingleFileResult;
42
+ export declare function loadHooksConfigFile(path: string, tier: 'user-global' | 'project-local' | 'plugin', pluginRoot?: string): SingleFileResult;
43
+ export declare function discoverPluginHooksConfigs(pluginsRoot?: string): Array<{
44
+ path: string;
45
+ pluginRoot: string;
46
+ }>;
40
47
  export interface LoadHooksConfigOptions {
41
48
  cwd?: string;
49
+ pluginsDir?: string;
42
50
  }
43
51
  export declare function loadHooksConfig(opts?: LoadHooksConfigOptions): LoadedHooksConfig;
44
52
  export {};
@@ -55,6 +55,7 @@ export interface CliConfig {
55
55
  maxSummaryCallsPerSession?: number;
56
56
  hooks?: RawHooksConfig;
57
57
  enableShellHooks?: boolean;
58
+ enablePluginHooks?: boolean;
58
59
  importFrom?: ImportFromConfig;
59
60
  }
60
61
  export interface ModelSlotConfigEntry {
@@ -115,6 +116,7 @@ export interface ConfigFileSchema {
115
116
  maxSummaryCallsPerSession?: number;
116
117
  hooks?: RawHooksConfig;
117
118
  enableShellHooks?: boolean;
119
+ enablePluginHooks?: boolean;
118
120
  importFrom?: Partial<Record<ImportSourceBinary, boolean | {
119
121
  plugins?: boolean;
120
122
  skills?: boolean;