Feat: Implemented advanced settings for Claude Code AI provider (#872)

* Feat: Implemented advanced settings for Claude Code AI provider

- Added new 'claudeCode' property to default config
- Added getters and validation functions to 'config-manager.js'
- Added new 'isEmpty' utility to 'utils.js'
- Added new constants file 'commands.js' for AI_COMMAND_NAMES
- Updated Claude Code AI provider to use new config functions
- Updated 'claude-code-usage.md' documentation
- Added 'config-manager.test.js' tests to cover new settings

* chore: run format

---------

Co-authored-by: Ralph Khreish <35776126+Crunchyman-ralph@users.noreply.github.com>
This commit is contained in:
Geoff Hammond
2025-07-03 06:43:46 +10:00
committed by GitHub
parent c99df64f65
commit f7fbdd6755
8 changed files with 426 additions and 90 deletions

View File

@@ -1012,6 +1012,21 @@ function truncate(text, maxLength) {
return `${text.slice(0, maxLength - 3)}...`;
}
/**
* Checks if array or object are empty
* @param {*} value - The value to check
* @returns {boolean} True if empty, false otherwise
*/
function isEmpty(value) {
if (Array.isArray(value)) {
return value.length === 0;
} else if (typeof value === 'object' && value !== null) {
return Object.keys(value).length === 0;
}
return false; // Not an array or object, or is null
}
/**
* Find cycles in a dependency graph using DFS
* @param {string} subtaskId - Current subtask ID
@@ -1373,6 +1388,7 @@ export {
formatTaskId,
findTaskById,
truncate,
isEmpty,
findCycles,
toKebabCase,
detectCamelCaseFlags,