MCPcopy Create free account
hub / github.com/Noumena-Network/code / hookSourceDescriptionDisplayString

Function hookSourceDescriptionDisplayString

src/utils/hooks/hooksSettings.ts:170–190  ·  view source on GitHub ↗
(source: HookSource)

Source from the content-addressed store, hash-verified

168}
169
170export function hookSourceDescriptionDisplayString(source: HookSource): string {
171 switch (source) {
172 case 'userSettings':
173 return 'User settings (~/.ncode/settings.json; legacy ~/.claude/settings.json)'
174 case 'projectSettings':
175 return 'Project settings (.ncode/settings.json; legacy .claude/settings.json)'
176 case 'localSettings':
177 return 'Local settings (.ncode/settings.local.json; legacy .claude/settings.local.json)'
178 case 'pluginHook':
179 // TODO: Get the actual plugin hook file paths instead of using glob pattern
180 // We should capture the specific plugin paths during hook registration and display them here
181 // e.g., "Plugin hooks (~/.ncode/plugins/repos/source/example-plugin/example-plugin/hooks/hooks.json)"
182 return 'Plugin hooks (~/.ncode/plugins/*/hooks/hooks.json; legacy ~/.claude/plugins/*/hooks/hooks.json)'
183 case 'sessionHook':
184 return 'Session hooks (in-memory, temporary)'
185 case 'builtinHook':
186 return 'Built-in hooks (registered internally by Code)'
187 default:
188 return source as string
189 }
190}
191
192export function hookSourceHeaderDisplayString(source: HookSource): string {
193 switch (source) {

Callers 1

ViewHookModeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected