@eldrforge/kodrdriv 0.0.51 → 0.1.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.
- package/README.md +2 -1
- package/dist/application.js +5 -3
- package/dist/application.js.map +1 -1
- package/dist/arguments.js +97 -70
- package/dist/arguments.js.map +1 -1
- package/dist/commands/audio-commit.js +7 -7
- package/dist/commands/audio-commit.js.map +1 -1
- package/dist/commands/audio-review.js +13 -13
- package/dist/commands/audio-review.js.map +1 -1
- package/dist/commands/clean.js +2 -2
- package/dist/commands/clean.js.map +1 -1
- package/dist/commands/commit.js +301 -36
- package/dist/commands/commit.js.map +1 -1
- package/dist/commands/link.js +7 -7
- package/dist/commands/link.js.map +1 -1
- package/dist/commands/publish.js +285 -306
- package/dist/commands/publish.js.map +1 -1
- package/dist/commands/release.js +171 -14
- package/dist/commands/release.js.map +1 -1
- package/dist/commands/review.js +52 -40
- package/dist/commands/review.js.map +1 -1
- package/dist/commands/select-audio.js +4 -4
- package/dist/commands/select-audio.js.map +1 -1
- package/dist/commands/tree.js +347 -34
- package/dist/commands/tree.js.map +1 -1
- package/dist/commands/unlink.js +5 -5
- package/dist/commands/unlink.js.map +1 -1
- package/dist/constants.js +28 -9
- package/dist/constants.js.map +1 -1
- package/dist/content/diff.js +122 -1
- package/dist/content/diff.js.map +1 -1
- package/dist/content/issues.js +17 -46
- package/dist/content/issues.js.map +1 -1
- package/dist/logging.js +3 -3
- package/dist/logging.js.map +1 -1
- package/dist/prompt/commit.js +2 -2
- package/dist/prompt/commit.js.map +1 -1
- package/dist/prompt/release.js +2 -2
- package/dist/prompt/release.js.map +1 -1
- package/dist/prompt/review.js +2 -2
- package/dist/prompt/review.js.map +1 -1
- package/dist/types.js +18 -5
- package/dist/types.js.map +1 -1
- package/dist/util/child.js +60 -4
- package/dist/util/child.js.map +1 -1
- package/dist/util/general.js +149 -13
- package/dist/util/general.js.map +1 -1
- package/dist/util/github.js +12 -8
- package/dist/util/github.js.map +1 -1
- package/dist/util/interactive.js +297 -0
- package/dist/util/interactive.js.map +1 -0
- package/dist/util/openai.js +87 -8
- package/dist/util/openai.js.map +1 -1
- package/dist/util/performance.js +8 -8
- package/dist/util/performance.js.map +1 -1
- package/dist/util/safety.js +4 -4
- package/dist/util/safety.js.map +1 -1
- package/dist/util/storage.js +2 -2
- package/dist/util/storage.js.map +1 -1
- package/package.json +6 -6
- package/test-increment.js +0 -0
package/README.md
CHANGED
|
@@ -42,9 +42,10 @@ kodrdriv audio-commit # Record audio to generate commit messages
|
|
|
42
42
|
## Key Features
|
|
43
43
|
|
|
44
44
|
- **AI-Powered Analysis** - Uses OpenAI models to understand your code changes
|
|
45
|
+
- **Adaptive Diff Management** - Automatically handles large diffs with intelligent truncation and retry logic to ensure reliable LLM processing
|
|
45
46
|
- **Comprehensive Release Automation** - Handles dependency updates, version bumping, PR creation, and GitHub releases
|
|
46
47
|
- **Audio-Driven Workflows** - Record audio to provide context for commits and reviews
|
|
47
|
-
- **Intelligent Workspace Management** -
|
|
48
|
+
- **Intelligent Workspace Management** - Provides tools for linking and managing related packages in monorepos
|
|
48
49
|
- **Flexible Configuration** - Hierarchical configuration with command-line overrides
|
|
49
50
|
|
|
50
51
|
## Configuration
|
package/dist/application.js
CHANGED
|
@@ -12,7 +12,7 @@ import { execute as execute$2 } from './commands/release.js';
|
|
|
12
12
|
import { execute as execute$9 } from './commands/review.js';
|
|
13
13
|
import { execute as execute$a } from './commands/select-audio.js';
|
|
14
14
|
import { execute as execute$6 } from './commands/unlink.js';
|
|
15
|
-
import { DEFAULT_CONFIG_DIR, COMMAND_CHECK_CONFIG, COMMAND_INIT_CONFIG, COMMAND_COMMIT, COMMAND_AUDIO_COMMIT, COMMAND_RELEASE, COMMAND_PUBLISH, COMMAND_TREE, COMMAND_LINK, COMMAND_UNLINK, COMMAND_AUDIO_REVIEW, COMMAND_CLEAN, COMMAND_REVIEW, COMMAND_SELECT_AUDIO } from './constants.js';
|
|
15
|
+
import { DEFAULT_CONFIG_DIR, VERSION, COMMAND_CHECK_CONFIG, COMMAND_INIT_CONFIG, COMMAND_COMMIT, COMMAND_AUDIO_COMMIT, COMMAND_RELEASE, COMMAND_PUBLISH, COMMAND_TREE, COMMAND_LINK, COMMAND_UNLINK, COMMAND_AUDIO_REVIEW, COMMAND_CLEAN, COMMAND_REVIEW, COMMAND_SELECT_AUDIO } from './constants.js';
|
|
16
16
|
import { getLogger, setLogLevel } from './logging.js';
|
|
17
17
|
import { ConfigSchema } from './types.js';
|
|
18
18
|
import { UserCancellationError } from './error/CommandErrors.js';
|
|
@@ -37,8 +37,8 @@ import { UserCancellationError } from './error/CommandErrors.js';
|
|
|
37
37
|
async function runApplication() {
|
|
38
38
|
// Configure logging early, before CardiganTime initialization
|
|
39
39
|
configureEarlyLogging();
|
|
40
|
-
|
|
41
|
-
const createCardigantime =
|
|
40
|
+
const cardigantimeModule = Cardigantime;
|
|
41
|
+
const createCardigantime = cardigantimeModule.create;
|
|
42
42
|
const cardigantime = createCardigantime({
|
|
43
43
|
defaults: {
|
|
44
44
|
configDirectory: DEFAULT_CONFIG_DIR,
|
|
@@ -71,6 +71,8 @@ async function runApplication() {
|
|
|
71
71
|
}
|
|
72
72
|
const logger = getLogger();
|
|
73
73
|
cardigantime.setLogger(logger);
|
|
74
|
+
// Display version information
|
|
75
|
+
logger.info('🚀 kodrdriv %s', VERSION);
|
|
74
76
|
// Handle check-config command first
|
|
75
77
|
if (commandConfig.commandName === COMMAND_CHECK_CONFIG) {
|
|
76
78
|
// CardiganTime's checkConfig has already been called in Arguments.configure()
|
package/dist/application.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"application.js","sources":["../src/application.ts"],"sourcesContent":["import * as Cardigantime from '@theunwalked/cardigantime';\nimport 'dotenv/config';\nimport { CommandConfig } from 'types';\nimport * as Arguments from './arguments';\nimport * as AudioCommit from './commands/audio-commit';\nimport * as AudioReview from './commands/audio-review';\nimport * as Clean from './commands/clean';\nimport * as Commit from './commands/commit';\nimport * as Link from './commands/link';\nimport * as Publish from './commands/publish';\nimport * as Tree from './commands/tree';\nimport * as Release from './commands/release';\nimport * as Review from './commands/review';\nimport * as SelectAudio from './commands/select-audio';\nimport * as Unlink from './commands/unlink';\nimport { COMMAND_AUDIO_COMMIT, COMMAND_AUDIO_REVIEW, COMMAND_CHECK_CONFIG, COMMAND_CLEAN, COMMAND_COMMIT, COMMAND_INIT_CONFIG, COMMAND_LINK, COMMAND_PUBLISH, COMMAND_TREE, COMMAND_RELEASE, COMMAND_REVIEW, COMMAND_SELECT_AUDIO, COMMAND_UNLINK, DEFAULT_CONFIG_DIR } from './constants';\nimport { getLogger, setLogLevel } from './logging';\nimport { Config, ConfigSchema, SecureConfig } from './types';\nimport { UserCancellationError } from './error/CommandErrors';\n\n/**\n * Configure early logging based on command line flags.\n *\n * Hey we need this because we need to be able to debug CardiganTime.\n * This method checks for --verbose and --debug flags early in the process\n * before CardiganTime is configured, allowing us to capture debug output\n * from the CardiganTime initialization itself.\n */\nexport function configureEarlyLogging(): void {\n const hasVerbose = process.argv.includes('--verbose');\n const hasDebug = process.argv.includes('--debug');\n\n // Set log level based on early flag detection\n if (hasDebug) {\n setLogLevel('debug');\n } else if (hasVerbose) {\n setLogLevel('verbose');\n }\n}\n\nexport async function runApplication(): Promise<void> {\n // Configure logging early, before CardiganTime initialization\n configureEarlyLogging();\n\n // Cast create to `any` to avoid excessive type instantiation issues in TS compiler\n const createCardigantime: any = (Cardigantime as unknown as { create: unknown }).create as any;\n\n const cardigantime = createCardigantime({\n defaults: {\n configDirectory: DEFAULT_CONFIG_DIR,\n // Move pathResolution INSIDE defaults\n pathResolution: {\n resolvePathArray: ['contextDirectories'], // Resolve contextDirectories array elements as paths\n },\n // Use fieldOverlaps instead of mergeStrategy, INSIDE defaults\n fieldOverlaps: {\n 'contextDirectories': 'prepend', // Use prepend strategy for contextDirectories array\n // Add other field overlap configurations as needed\n },\n },\n features: ['config', 'hierarchical'],\n configShape: ConfigSchema.shape, // No need for 'as any' now\n logger: getLogger(),\n }); // No need for 'as any' at the end\n\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const [runConfig, secureConfig, commandConfig]: [Config, SecureConfig, CommandConfig] = await Arguments.configure(cardigantime); // Pass cardigantime instance\n\n // Set log level based on verbose flag\n if (runConfig.verbose) {\n setLogLevel('verbose');\n }\n if (runConfig.debug) {\n setLogLevel('debug');\n }\n\n const logger = getLogger();\n cardigantime.setLogger(logger);\n\n // Handle check-config command first\n if (commandConfig.commandName === COMMAND_CHECK_CONFIG) {\n // CardiganTime's checkConfig has already been called in Arguments.configure()\n // No additional processing needed here\n return;\n }\n\n // Handle init-config command\n if (commandConfig.commandName === COMMAND_INIT_CONFIG) {\n // CardiganTime's initConfig has already been called in Arguments.configure()\n // No additional processing needed here\n return;\n }\n\n // Get the command from Commander\n const command = process.argv[2];\n let commandName = commandConfig.commandName;\n\n // Handle special case for tree command with built-in command argument\n if (command === 'tree' && process.argv[3]) {\n const treeBuiltInCommand = process.argv[3];\n const supportedBuiltInCommands = ['commit', 'publish', 'link', 'unlink'];\n if (supportedBuiltInCommands.includes(treeBuiltInCommand)) {\n // This is a tree command with built-in command, keep commandName as 'tree'\n commandName = 'tree';\n } else {\n // Unknown tree argument, let it fail naturally in tree.ts\n commandName = 'tree';\n }\n }\n // If we have a specific command argument, use that\n else if (command === 'commit' || command === 'audio-commit' || command === 'release' || command === 'publish' || command === 'tree' || command === 'link' || command === 'unlink' || command === 'audio-review' || command === 'clean' || command === 'review' || command === 'select-audio') {\n commandName = command;\n }\n\n let summary: string = '';\n\n try {\n if (commandName === COMMAND_COMMIT) {\n summary = await Commit.execute(runConfig);\n } else if (commandName === COMMAND_AUDIO_COMMIT) {\n summary = await AudioCommit.execute(runConfig);\n } else if (commandName === COMMAND_RELEASE) {\n const releaseSummary = await Release.execute(runConfig);\n summary = `${releaseSummary.title}\\n\\n${releaseSummary.body}`;\n } else if (commandName === COMMAND_PUBLISH) {\n await Publish.execute(runConfig);\n } else if (commandName === COMMAND_TREE) {\n // Handle tree directories mapping from command-specific arguments\n if (runConfig.audioReview?.directory && !runConfig.tree?.directories) {\n runConfig.tree = runConfig.tree || {};\n runConfig.tree.directories = [runConfig.audioReview.directory];\n }\n // Handle tree exclusion patterns - use global excludedPatterns for tree\n if (runConfig.excludedPatterns && !runConfig.tree?.excludedPatterns) {\n runConfig.tree = runConfig.tree || {};\n runConfig.tree.excludedPatterns = runConfig.excludedPatterns;\n }\n summary = await Tree.execute(runConfig);\n } else if (commandName === COMMAND_LINK) {\n summary = await Link.execute(runConfig);\n } else if (commandName === COMMAND_UNLINK) {\n summary = await Unlink.execute(runConfig);\n } else if (commandName === COMMAND_AUDIO_REVIEW) {\n summary = await AudioReview.execute(runConfig);\n } else if (commandName === COMMAND_CLEAN) {\n await Clean.execute(runConfig);\n summary = 'Output directory cleaned successfully.';\n } else if (commandName === COMMAND_REVIEW) {\n summary = await Review.execute(runConfig);\n } else if (commandName === COMMAND_SELECT_AUDIO) {\n await SelectAudio.execute(runConfig);\n summary = 'Audio selection completed successfully.';\n }\n\n // eslint-disable-next-line no-console\n console.log(`\\n\\n${summary}\\n\\n`);\n } catch (error: any) {\n // Handle user cancellation gracefully\n if (error instanceof UserCancellationError) {\n logger.info(error.message);\n process.exit(0);\n }\n\n // Re-throw other errors to be handled by main.ts\n throw error;\n }\n}\n"],"names":["configureEarlyLogging","hasVerbose","process","argv","includes","hasDebug","setLogLevel","runApplication","createCardigantime","Cardigantime","create","cardigantime","defaults","configDirectory","DEFAULT_CONFIG_DIR","pathResolution","resolvePathArray","fieldOverlaps","features","configShape","ConfigSchema","shape","logger","getLogger","runConfig","secureConfig","commandConfig","Arguments","verbose","debug","setLogger","commandName","COMMAND_CHECK_CONFIG","COMMAND_INIT_CONFIG","command","treeBuiltInCommand","supportedBuiltInCommands","summary","COMMAND_COMMIT","Commit","COMMAND_AUDIO_COMMIT","AudioCommit","COMMAND_RELEASE","releaseSummary","Release","title","body","COMMAND_PUBLISH","Publish","COMMAND_TREE","audioReview","directory","tree","directories","excludedPatterns","Tree","COMMAND_LINK","Link","COMMAND_UNLINK","Unlink","COMMAND_AUDIO_REVIEW","AudioReview","COMMAND_CLEAN","Clean","COMMAND_REVIEW","Review","COMMAND_SELECT_AUDIO","SelectAudio","console","log","error","UserCancellationError","info","message","exit"],"mappings":";;;;;;;;;;;;;;;;;;;AAoBA;;;;;;;AAOC,IACM,SAASA,qBAAAA,GAAAA;AACZ,IAAA,MAAMC,UAAAA,GAAaC,OAAAA,CAAQC,IAAI,CAACC,QAAQ,CAAC,WAAA,CAAA;AACzC,IAAA,MAAMC,QAAAA,GAAWH,OAAAA,CAAQC,IAAI,CAACC,QAAQ,CAAC,SAAA,CAAA;;AAGvC,IAAA,IAAIC,QAAAA,EAAU;QACVC,WAAAA,CAAY,OAAA,CAAA;AAChB,IAAA,CAAA,MAAO,IAAIL,UAAAA,EAAY;QACnBK,WAAAA,CAAY,SAAA,CAAA;AAChB,IAAA;AACJ;AAEO,eAAeC,cAAAA,GAAAA;;AAElBP,IAAAA,qBAAAA,EAAAA;;IAGA,MAAMQ,kBAAAA,GAA0B,YAACC,CAAgDC,MAAM;AAEvF,IAAA,MAAMC,eAAeH,kBAAAA,CAAmB;QACpCI,QAAAA,EAAU;YACNC,eAAAA,EAAiBC,kBAAAA;;YAEjBC,cAAAA,EAAgB;gBACZC,gBAAAA,EAAkB;AAAC,oBAAA;AAAqB;AAC5C,aAAA;;YAEAC,aAAAA,EAAe;gBACX,oBAAA,EAAsB;AAE1B;AACJ,SAAA;QACAC,QAAAA,EAAU;AAAC,YAAA,QAAA;AAAU,YAAA;AAAe,SAAA;AACpCC,QAAAA,WAAAA,EAAaC,aAAaC,KAAK;QAC/BC,MAAAA,EAAQC,SAAAA;AACZ,KAAA,CAAA,CAAA;;IAGA,MAAM,CAACC,SAAAA,EAAWC,YAAAA,EAAcC,aAAAA,CAAc,GAA0C,MAAMC,SAAmB,CAAChB,YA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,IAAI,CAAC,CAAA;AACpC,IAAA,CAAA,CAAE,OAAOiC,KAAAA,EAAY;;AAEjB,QAAA,IAAIA,iBAAiBC,qBAAAA,EAAuB;YACxCjD,MAAAA,CAAOkD,IAAI,CAACF,KAAAA,CAAMG,OAAO,CAAA;AACzBvE,YAAAA,OAAAA,CAAQwE,IAAI,CAAC,CAAA,CAAA;AACjB,QAAA;;QAGA,MAAMJ,KAAAA;AACV,IAAA;AACJ;;;;"}
|
|
1
|
+
{"version":3,"file":"application.js","sources":["../src/application.ts"],"sourcesContent":["import * as Cardigantime from '@theunwalked/cardigantime';\nimport 'dotenv/config';\nimport { CommandConfig } from 'types';\nimport * as Arguments from './arguments';\nimport * as AudioCommit from './commands/audio-commit';\nimport * as AudioReview from './commands/audio-review';\nimport * as Clean from './commands/clean';\nimport * as Commit from './commands/commit';\nimport * as Link from './commands/link';\nimport * as Publish from './commands/publish';\nimport * as Tree from './commands/tree';\nimport * as Release from './commands/release';\nimport * as Review from './commands/review';\nimport * as SelectAudio from './commands/select-audio';\nimport * as Unlink from './commands/unlink';\nimport { COMMAND_AUDIO_COMMIT, COMMAND_AUDIO_REVIEW, COMMAND_CHECK_CONFIG, COMMAND_CLEAN, COMMAND_COMMIT, COMMAND_INIT_CONFIG, COMMAND_LINK, COMMAND_PUBLISH, COMMAND_TREE, COMMAND_RELEASE, COMMAND_REVIEW, COMMAND_SELECT_AUDIO, COMMAND_UNLINK, DEFAULT_CONFIG_DIR } from './constants';\nimport { getLogger, setLogLevel } from './logging';\nimport { Config, ConfigSchema, SecureConfig } from './types';\nimport { UserCancellationError } from './error/CommandErrors';\nimport { VERSION } from './constants';\n\n/**\n * Configure early logging based on command line flags.\n *\n * Hey we need this because we need to be able to debug CardiganTime.\n * This method checks for --verbose and --debug flags early in the process\n * before CardiganTime is configured, allowing us to capture debug output\n * from the CardiganTime initialization itself.\n */\nexport function configureEarlyLogging(): void {\n const hasVerbose = process.argv.includes('--verbose');\n const hasDebug = process.argv.includes('--debug');\n\n // Set log level based on early flag detection\n if (hasDebug) {\n setLogLevel('debug');\n } else if (hasVerbose) {\n setLogLevel('verbose');\n }\n}\n\nexport async function runApplication(): Promise<void> {\n // Configure logging early, before CardiganTime initialization\n configureEarlyLogging();\n\n // Use proper typing for CardiganTime create function\n interface CardigantimeCreateParams {\n defaults?: any;\n features?: string[];\n configShape?: any;\n logger?: any;\n }\n\n interface CardigantimeInstance {\n read: (args: any) => Promise<any>;\n checkConfig: () => Promise<void>;\n generateConfig: (dir: string) => Promise<void>;\n setLogger: (logger: any) => void;\n }\n\n const cardigantimeModule = Cardigantime as any;\n const createCardigantime = cardigantimeModule.create as (params: CardigantimeCreateParams) => CardigantimeInstance;\n\n const cardigantime = createCardigantime({\n defaults: {\n configDirectory: DEFAULT_CONFIG_DIR,\n // Move pathResolution INSIDE defaults\n pathResolution: {\n resolvePathArray: ['contextDirectories'], // Resolve contextDirectories array elements as paths\n },\n // Use fieldOverlaps instead of mergeStrategy, INSIDE defaults\n fieldOverlaps: {\n 'contextDirectories': 'prepend', // Use prepend strategy for contextDirectories array\n // Add other field overlap configurations as needed\n },\n },\n features: ['config', 'hierarchical'],\n configShape: ConfigSchema.shape, // No need for 'as any' now\n logger: getLogger(),\n }); // No need for 'as any' at the end\n\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const [runConfig, secureConfig, commandConfig]: [Config, SecureConfig, CommandConfig] = await Arguments.configure(cardigantime); // Pass cardigantime instance\n\n // Set log level based on verbose flag\n if (runConfig.verbose) {\n setLogLevel('verbose');\n }\n if (runConfig.debug) {\n setLogLevel('debug');\n }\n\n const logger = getLogger();\n cardigantime.setLogger(logger);\n\n // Display version information\n logger.info('🚀 kodrdriv %s', VERSION);\n\n // Handle check-config command first\n if (commandConfig.commandName === COMMAND_CHECK_CONFIG) {\n // CardiganTime's checkConfig has already been called in Arguments.configure()\n // No additional processing needed here\n return;\n }\n\n // Handle init-config command\n if (commandConfig.commandName === COMMAND_INIT_CONFIG) {\n // CardiganTime's initConfig has already been called in Arguments.configure()\n // No additional processing needed here\n return;\n }\n\n // Get the command from Commander\n const command = process.argv[2];\n let commandName = commandConfig.commandName;\n\n // Handle special case for tree command with built-in command argument\n if (command === 'tree' && process.argv[3]) {\n const treeBuiltInCommand = process.argv[3];\n const supportedBuiltInCommands = ['commit', 'publish', 'link', 'unlink'];\n if (supportedBuiltInCommands.includes(treeBuiltInCommand)) {\n // This is a tree command with built-in command, keep commandName as 'tree'\n commandName = 'tree';\n } else {\n // Unknown tree argument, let it fail naturally in tree.ts\n commandName = 'tree';\n }\n }\n // If we have a specific command argument, use that\n else if (command === 'commit' || command === 'audio-commit' || command === 'release' || command === 'publish' || command === 'tree' || command === 'link' || command === 'unlink' || command === 'audio-review' || command === 'clean' || command === 'review' || command === 'select-audio') {\n commandName = command;\n }\n\n let summary: string = '';\n\n try {\n if (commandName === COMMAND_COMMIT) {\n summary = await Commit.execute(runConfig);\n } else if (commandName === COMMAND_AUDIO_COMMIT) {\n summary = await AudioCommit.execute(runConfig);\n } else if (commandName === COMMAND_RELEASE) {\n const releaseSummary = await Release.execute(runConfig);\n summary = `${releaseSummary.title}\\n\\n${releaseSummary.body}`;\n } else if (commandName === COMMAND_PUBLISH) {\n await Publish.execute(runConfig);\n } else if (commandName === COMMAND_TREE) {\n // Handle tree directories mapping from command-specific arguments\n if (runConfig.audioReview?.directory && !runConfig.tree?.directories) {\n runConfig.tree = runConfig.tree || {};\n runConfig.tree.directories = [runConfig.audioReview.directory];\n }\n // Handle tree exclusion patterns - use global excludedPatterns for tree\n if (runConfig.excludedPatterns && !runConfig.tree?.excludedPatterns) {\n runConfig.tree = runConfig.tree || {};\n runConfig.tree.excludedPatterns = runConfig.excludedPatterns;\n }\n summary = await Tree.execute(runConfig);\n } else if (commandName === COMMAND_LINK) {\n summary = await Link.execute(runConfig);\n } else if (commandName === COMMAND_UNLINK) {\n summary = await Unlink.execute(runConfig);\n } else if (commandName === COMMAND_AUDIO_REVIEW) {\n summary = await AudioReview.execute(runConfig);\n } else if (commandName === COMMAND_CLEAN) {\n await Clean.execute(runConfig);\n summary = 'Output directory cleaned successfully.';\n } else if (commandName === COMMAND_REVIEW) {\n summary = await Review.execute(runConfig);\n } else if (commandName === COMMAND_SELECT_AUDIO) {\n await SelectAudio.execute(runConfig);\n summary = 'Audio selection completed successfully.';\n }\n\n // eslint-disable-next-line no-console\n console.log(`\\n\\n${summary}\\n\\n`);\n } catch (error: any) {\n // Handle user cancellation gracefully\n if (error instanceof UserCancellationError) {\n logger.info(error.message);\n process.exit(0);\n }\n\n // Re-throw other errors to be handled by main.ts\n throw error;\n }\n}\n"],"names":["configureEarlyLogging","hasVerbose","process","argv","includes","hasDebug","setLogLevel","runApplication","cardigantimeModule","Cardigantime","createCardigantime","create","cardigantime","defaults","configDirectory","DEFAULT_CONFIG_DIR","pathResolution","resolvePathArray","fieldOverlaps","features","configShape","ConfigSchema","shape","logger","getLogger","runConfig","secureConfig","commandConfig","Arguments","verbose","debug","setLogger","info","VERSION","commandName","COMMAND_CHECK_CONFIG","COMMAND_INIT_CONFIG","command","treeBuiltInCommand","supportedBuiltInCommands","summary","COMMAND_COMMIT","Commit","COMMAND_AUDIO_COMMIT","AudioCommit","COMMAND_RELEASE","releaseSummary","Release","title","body","COMMAND_PUBLISH","Publish","COMMAND_TREE","audioReview","directory","tree","directories","excludedPatterns","Tree","COMMAND_LINK","Link","COMMAND_UNLINK","Unlink","COMMAND_AUDIO_REVIEW","AudioReview","COMMAND_CLEAN","Clean","COMMAND_REVIEW","Review","COMMAND_SELECT_AUDIO","SelectAudio","console","log","error","UserCancellationError","message","exit"],"mappings":";;;;;;;;;;;;;;;;;;;AAqBA;;;;;;;AAOC,IACM,SAASA,qBAAAA,GAAAA;AACZ,IAAA,MAAMC,UAAAA,GAAaC,OAAAA,CAAQC,IAAI,CAACC,QAAQ,CAAC,WAAA,CAAA;AACzC,IAAA,MAAMC,QAAAA,GAAWH,OAAAA,CAAQC,IAAI,CAACC,QAAQ,C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|
cached: z.boolean().optional(),
|
|
22
22
|
add: z.boolean().optional(),
|
|
23
23
|
sendit: z.boolean().optional(),
|
|
24
|
+
interactive: z.boolean().optional(),
|
|
25
|
+
amend: z.boolean().optional(),
|
|
24
26
|
from: z.string().optional(),
|
|
25
27
|
to: z.string().optional(),
|
|
28
|
+
targetVersion: z.string().optional(),
|
|
26
29
|
excludedPatterns: z.array(z.string()).optional(),
|
|
27
30
|
excludedPaths: z.array(z.string()).optional(),
|
|
28
31
|
context: z.string().optional(),
|
|
@@ -30,6 +33,7 @@ z.object({
|
|
|
30
33
|
direction: z.string().optional(),
|
|
31
34
|
messageLimit: z.number().optional(),
|
|
32
35
|
skipFileCheck: z.boolean().optional(),
|
|
36
|
+
maxDiffBytes: z.number().optional(),
|
|
33
37
|
mergeMethod: z.enum([
|
|
34
38
|
'merge',
|
|
35
39
|
'squash',
|
|
@@ -41,8 +45,10 @@ z.object({
|
|
|
41
45
|
cmd: z.string().optional(),
|
|
42
46
|
publish: z.boolean().optional(),
|
|
43
47
|
parallel: z.boolean().optional(),
|
|
48
|
+
continue: z.boolean().optional(),
|
|
44
49
|
includeCommitHistory: z.boolean().optional(),
|
|
45
50
|
includeRecentDiffs: z.boolean().optional(),
|
|
51
|
+
editorTimeout: z.number().optional(),
|
|
46
52
|
includeReleaseNotes: z.boolean().optional(),
|
|
47
53
|
includeGithubIssues: z.boolean().optional(),
|
|
48
54
|
commitHistoryLimit: z.number().optional(),
|
|
@@ -71,15 +77,18 @@ const transformCliArgs = (finalCliArgs, commandName)=>{
|
|
|
71
77
|
// Map preferencesDir (CLI) to preferencesDirectory (Config standard)
|
|
72
78
|
if (finalCliArgs.preferencesDir !== undefined) transformedCliArgs.preferencesDirectory = finalCliArgs.preferencesDir;
|
|
73
79
|
// Nested mappings for 'commit' options
|
|
74
|
-
if (finalCliArgs.cached !== undefined || finalCliArgs.sendit !== undefined || finalCliArgs.add !== undefined || finalCliArgs.skipFileCheck !== undefined) {
|
|
80
|
+
if (finalCliArgs.cached !== undefined || finalCliArgs.sendit !== undefined || finalCliArgs.add !== undefined || finalCliArgs.skipFileCheck !== undefined || finalCliArgs.maxDiffBytes !== undefined || finalCliArgs.interactive !== undefined || finalCliArgs.amend !== undefined) {
|
|
75
81
|
transformedCliArgs.commit = {};
|
|
76
82
|
if (finalCliArgs.add !== undefined) transformedCliArgs.commit.add = finalCliArgs.add;
|
|
77
83
|
if (finalCliArgs.cached !== undefined) transformedCliArgs.commit.cached = finalCliArgs.cached;
|
|
78
84
|
if (finalCliArgs.sendit !== undefined) transformedCliArgs.commit.sendit = finalCliArgs.sendit;
|
|
85
|
+
if (finalCliArgs.interactive !== undefined) transformedCliArgs.commit.interactive = finalCliArgs.interactive;
|
|
86
|
+
if (finalCliArgs.amend !== undefined) transformedCliArgs.commit.amend = finalCliArgs.amend;
|
|
79
87
|
if (finalCliArgs.messageLimit !== undefined) transformedCliArgs.commit.messageLimit = finalCliArgs.messageLimit;
|
|
80
88
|
if (finalCliArgs.context !== undefined) transformedCliArgs.commit.context = finalCliArgs.context;
|
|
81
89
|
if (finalCliArgs.direction !== undefined) transformedCliArgs.commit.direction = finalCliArgs.direction;
|
|
82
90
|
if (finalCliArgs.skipFileCheck !== undefined) transformedCliArgs.commit.skipFileCheck = finalCliArgs.skipFileCheck;
|
|
91
|
+
if (finalCliArgs.maxDiffBytes !== undefined) transformedCliArgs.commit.maxDiffBytes = finalCliArgs.maxDiffBytes;
|
|
83
92
|
}
|
|
84
93
|
// Nested mappings for 'audioCommit' options
|
|
85
94
|
if (finalCliArgs.file !== undefined || finalCliArgs.keepTemp !== undefined) {
|
|
@@ -88,17 +97,22 @@ const transformCliArgs = (finalCliArgs, commandName)=>{
|
|
|
88
97
|
if (finalCliArgs.keepTemp !== undefined) transformedCliArgs.audioCommit.keepTemp = finalCliArgs.keepTemp;
|
|
89
98
|
}
|
|
90
99
|
// Nested mappings for 'release' options
|
|
91
|
-
if (finalCliArgs.from !== undefined || finalCliArgs.to !== undefined) {
|
|
100
|
+
if (finalCliArgs.from !== undefined || finalCliArgs.to !== undefined || finalCliArgs.maxDiffBytes !== undefined || finalCliArgs.interactive !== undefined) {
|
|
92
101
|
transformedCliArgs.release = {};
|
|
93
102
|
if (finalCliArgs.from !== undefined) transformedCliArgs.release.from = finalCliArgs.from;
|
|
94
103
|
if (finalCliArgs.to !== undefined) transformedCliArgs.release.to = finalCliArgs.to;
|
|
95
104
|
if (finalCliArgs.context !== undefined) transformedCliArgs.release.context = finalCliArgs.context;
|
|
105
|
+
if (finalCliArgs.interactive !== undefined) transformedCliArgs.release.interactive = finalCliArgs.interactive;
|
|
96
106
|
if (finalCliArgs.messageLimit !== undefined) transformedCliArgs.release.messageLimit = finalCliArgs.messageLimit;
|
|
107
|
+
if (finalCliArgs.maxDiffBytes !== undefined) transformedCliArgs.release.maxDiffBytes = finalCliArgs.maxDiffBytes;
|
|
97
108
|
}
|
|
98
|
-
// Nested mappings for 'publish' options
|
|
99
|
-
if (finalCliArgs.mergeMethod !== undefined) {
|
|
109
|
+
// Nested mappings for 'publish' options (only when it's actually a publish command or has publish-specific options)
|
|
110
|
+
if (finalCliArgs.mergeMethod !== undefined || finalCliArgs.targetVersion !== undefined || commandName === 'publish' && (finalCliArgs.from !== undefined || finalCliArgs.interactive !== undefined)) {
|
|
100
111
|
transformedCliArgs.publish = {};
|
|
101
112
|
if (finalCliArgs.mergeMethod !== undefined) transformedCliArgs.publish.mergeMethod = finalCliArgs.mergeMethod;
|
|
113
|
+
if (finalCliArgs.from !== undefined) transformedCliArgs.publish.from = finalCliArgs.from;
|
|
114
|
+
if (finalCliArgs.targetVersion !== undefined) transformedCliArgs.publish.targetVersion = finalCliArgs.targetVersion;
|
|
115
|
+
if (finalCliArgs.interactive !== undefined) transformedCliArgs.publish.interactive = finalCliArgs.interactive;
|
|
102
116
|
}
|
|
103
117
|
// Nested mappings for 'link' and 'unlink' options (both use the same configuration)
|
|
104
118
|
if (finalCliArgs.scopeRoots !== undefined) {
|
|
@@ -143,12 +157,13 @@ const transformCliArgs = (finalCliArgs, commandName)=>{
|
|
|
143
157
|
if (finalCliArgs.githubIssuesLimit !== undefined) transformedCliArgs.review.githubIssuesLimit = finalCliArgs.githubIssuesLimit;
|
|
144
158
|
if (finalCliArgs.context !== undefined) transformedCliArgs.review.context = finalCliArgs.context;
|
|
145
159
|
if (finalCliArgs.sendit !== undefined) transformedCliArgs.review.sendit = finalCliArgs.sendit;
|
|
160
|
+
if (finalCliArgs.editorTimeout !== undefined) transformedCliArgs.review.editorTimeout = finalCliArgs.editorTimeout;
|
|
146
161
|
}
|
|
147
162
|
// Nested mappings for 'tree' options (add when relevant args present)
|
|
148
163
|
if (commandName === 'tree') {
|
|
149
164
|
const treeExcludedPatterns = finalCliArgs.excludedPatterns || finalCliArgs.excludedPaths;
|
|
150
165
|
const builtInCommand = finalCliArgs.builtInCommand;
|
|
151
|
-
if (finalCliArgs.directory !== undefined || finalCliArgs.directories !== undefined || treeExcludedPatterns !== undefined || finalCliArgs.startFrom !== undefined || finalCliArgs.cmd !== undefined || finalCliArgs.parallel !== undefined || builtInCommand !== undefined) {
|
|
166
|
+
if (finalCliArgs.directory !== undefined || finalCliArgs.directories !== undefined || treeExcludedPatterns !== undefined || finalCliArgs.startFrom !== undefined || finalCliArgs.cmd !== undefined || finalCliArgs.parallel !== undefined || builtInCommand !== undefined || finalCliArgs.continue !== undefined) {
|
|
152
167
|
transformedCliArgs.tree = {};
|
|
153
168
|
if (finalCliArgs.directories !== undefined) transformedCliArgs.tree.directories = finalCliArgs.directories;
|
|
154
169
|
else if (finalCliArgs.directory !== undefined) transformedCliArgs.tree.directories = [
|
|
@@ -159,6 +174,7 @@ const transformCliArgs = (finalCliArgs, commandName)=>{
|
|
|
159
174
|
if (finalCliArgs.cmd !== undefined) transformedCliArgs.tree.cmd = finalCliArgs.cmd;
|
|
160
175
|
if (finalCliArgs.parallel !== undefined) transformedCliArgs.tree.parallel = finalCliArgs.parallel;
|
|
161
176
|
if (builtInCommand !== undefined) transformedCliArgs.tree.builtInCommand = builtInCommand;
|
|
177
|
+
if (finalCliArgs.continue !== undefined) transformedCliArgs.tree.continue = finalCliArgs.continue;
|
|
162
178
|
}
|
|
163
179
|
}
|
|
164
180
|
// Handle excluded patterns (Commander.js converts --excluded-paths to excludedPaths)
|
|
@@ -228,17 +244,60 @@ const configure = async (cardigantime)=>{
|
|
|
228
244
|
// Get values from config file using Cardigantime's hierarchical configuration
|
|
229
245
|
const fileValues = await cardigantime.read(transformedCliArgs);
|
|
230
246
|
// Merge configurations: Defaults -> File -> CLI
|
|
231
|
-
// Properly merge
|
|
247
|
+
// Properly merge nested sections to preserve config file values when CLI args are partial
|
|
232
248
|
const mergedLink = {
|
|
233
249
|
...KODRDRIV_DEFAULTS.link,
|
|
234
250
|
...fileValues.link,
|
|
235
251
|
...transformedCliArgs.link
|
|
236
252
|
};
|
|
253
|
+
const mergedCommit = {
|
|
254
|
+
...KODRDRIV_DEFAULTS.commit,
|
|
255
|
+
...fileValues.commit,
|
|
256
|
+
...transformedCliArgs.commit
|
|
257
|
+
};
|
|
258
|
+
const mergedRelease = {
|
|
259
|
+
...KODRDRIV_DEFAULTS.release,
|
|
260
|
+
...fileValues.release,
|
|
261
|
+
...transformedCliArgs.release
|
|
262
|
+
};
|
|
263
|
+
const mergedPublish = {
|
|
264
|
+
...KODRDRIV_DEFAULTS.publish,
|
|
265
|
+
...fileValues.publish,
|
|
266
|
+
...transformedCliArgs.publish
|
|
267
|
+
};
|
|
268
|
+
const mergedAudioCommit = {
|
|
269
|
+
...KODRDRIV_DEFAULTS.audioCommit,
|
|
270
|
+
...fileValues.audioCommit,
|
|
271
|
+
...transformedCliArgs.audioCommit
|
|
272
|
+
};
|
|
273
|
+
const mergedAudioReview = {
|
|
274
|
+
...KODRDRIV_DEFAULTS.audioReview,
|
|
275
|
+
...fileValues.audioReview,
|
|
276
|
+
...transformedCliArgs.audioReview
|
|
277
|
+
};
|
|
278
|
+
const mergedReview = {
|
|
279
|
+
...KODRDRIV_DEFAULTS.review,
|
|
280
|
+
...fileValues.review,
|
|
281
|
+
...transformedCliArgs.review
|
|
282
|
+
};
|
|
283
|
+
const mergedTree = {
|
|
284
|
+
...KODRDRIV_DEFAULTS.tree,
|
|
285
|
+
...fileValues.tree,
|
|
286
|
+
...transformedCliArgs.tree
|
|
287
|
+
};
|
|
237
288
|
const partialConfig = {
|
|
238
289
|
...KODRDRIV_DEFAULTS,
|
|
239
290
|
...fileValues,
|
|
240
291
|
...transformedCliArgs,
|
|
241
|
-
|
|
292
|
+
// Override with properly merged nested sections
|
|
293
|
+
link: mergedLink,
|
|
294
|
+
commit: mergedCommit,
|
|
295
|
+
release: mergedRelease,
|
|
296
|
+
publish: mergedPublish,
|
|
297
|
+
audioCommit: mergedAudioCommit,
|
|
298
|
+
audioReview: mergedAudioReview,
|
|
299
|
+
review: mergedReview,
|
|
300
|
+
tree: mergedTree
|
|
242
301
|
}; // Cast to Partial<Config> initially
|
|
243
302
|
// Specific validation and processing after merge
|
|
244
303
|
const config = await validateAndProcessOptions(partialConfig);
|
|
@@ -276,7 +335,7 @@ async function getCliConfig(program) {
|
|
|
276
335
|
// Add global options to the main program
|
|
277
336
|
// (cardigantime already adds most global options like --verbose, --debug, --config-dir)
|
|
278
337
|
// Add subcommands
|
|
279
|
-
const commitCommand = program.command('commit').argument('[direction]', 'direction or guidance for the commit message').description('Generate commit notes').option('--context <context>', 'context for the commit message').option('--cached', 'use cached diff').option('--add', 'add all changes before committing').option('--sendit', 'Commit with the message generated. No review.').option('--message-limit <messageLimit>', 'limit the number of messages to generate').option('--skip-file-check', 'skip check for file: dependencies before committing');
|
|
338
|
+
const commitCommand = program.command('commit').argument('[direction]', 'direction or guidance for the commit message').description('Generate commit notes').option('--context <context>', 'context for the commit message').option('--cached', 'use cached diff').option('--add', 'add all changes before committing').option('--sendit', 'Commit with the message generated. No review.').option('--interactive', 'Present commit message for interactive review and editing').option('--amend', 'Amend the last commit with the generated message').option('--message-limit <messageLimit>', 'limit the number of messages to generate').option('--skip-file-check', 'skip check for file: dependencies before committing').option('--max-diff-bytes <maxDiffBytes>', 'maximum bytes per file in diff (default: 2048)');
|
|
280
339
|
// Add shared options to commit command
|
|
281
340
|
addSharedOptions(commitCommand);
|
|
282
341
|
// Customize help output for commit command
|
|
@@ -302,6 +361,14 @@ async function getCliConfig(program) {
|
|
|
302
361
|
'--sendit',
|
|
303
362
|
'Commit with the message generated. No review.'
|
|
304
363
|
],
|
|
364
|
+
[
|
|
365
|
+
'--interactive',
|
|
366
|
+
'Present commit message for interactive review and editing'
|
|
367
|
+
],
|
|
368
|
+
[
|
|
369
|
+
'--amend',
|
|
370
|
+
'Amend the last commit with the generated message'
|
|
371
|
+
],
|
|
305
372
|
[
|
|
306
373
|
'--message-limit <messageLimit>',
|
|
307
374
|
'limit the number of messages to generate'
|
|
@@ -354,11 +421,11 @@ async function getCliConfig(program) {
|
|
|
354
421
|
});
|
|
355
422
|
const audioCommitCommand = program.command('audio-commit').option('--cached', 'use cached diff').option('--add', 'add all changes before committing').option('--sendit', 'Commit with the message generated. No review.').option('--direction <direction>', 'direction or guidance for the commit message').option('--message-limit <messageLimit>', 'limit the number of messages to generate').option('--file <file>', 'audio file path').description('Record audio to provide context, then generate and optionally commit with AI-generated message');
|
|
356
423
|
addSharedOptions(audioCommitCommand);
|
|
357
|
-
const releaseCommand = program.command('release').option('--from <from>', 'branch to generate release notes from').option('--to <to>', 'branch to generate release notes to').option('--context <context>', 'context for the commit message').description('Generate release notes');
|
|
424
|
+
const releaseCommand = program.command('release').option('--from <from>', 'branch to generate release notes from').option('--to <to>', 'branch to generate release notes to').option('--context <context>', 'context for the commit message').option('--interactive', 'Present release notes for interactive review and editing').option('--max-diff-bytes <maxDiffBytes>', 'maximum bytes per file in diff (default: 2048)').description('Generate release notes');
|
|
358
425
|
addSharedOptions(releaseCommand);
|
|
359
|
-
const publishCommand = program.command('publish').option('--merge-method <method>', 'method to merge PR (merge, squash, rebase)', 'squash').option('--sendit', 'skip all confirmation prompts and proceed automatically').description('Publish a release');
|
|
426
|
+
const publishCommand = program.command('publish').option('--merge-method <method>', 'method to merge PR (merge, squash, rebase)', 'squash').option('--from <from>', 'branch/tag to generate release notes from (default: main)').option('--target-version <targetVersion>', 'target version for release (explicit version like "4.30.0" or semantic bump: "patch", "minor", "major")').option('--interactive', 'present release notes for interactive review and editing').option('--sendit', 'skip all confirmation prompts and proceed automatically').description('Publish a release');
|
|
360
427
|
addSharedOptions(publishCommand);
|
|
361
|
-
const treeCommand = program.command('tree [command]').option('--directory <directory>', 'target directory containing multiple packages (defaults to current directory)').option('--directories [directories...]', 'target directories containing multiple packages (defaults to current directory)').option('--start-from <startFrom>', 'resume execution from this package directory name (useful for restarting failed builds)').option('--cmd <cmd>', 'shell command to execute in each package directory (e.g., "npm install", "git status")').option('--parallel', 'execute packages in parallel when dependencies allow (packages with no interdependencies run simultaneously)').option('--excluded-patterns [excludedPatterns...]', 'patterns to exclude packages from processing (e.g., "**/node_modules/**", "dist/*")').description('Analyze package dependencies in workspace and execute commands in dependency order. Supports built-in commands: commit, publish, link, unlink');
|
|
428
|
+
const treeCommand = program.command('tree [command]').option('--directory <directory>', 'target directory containing multiple packages (defaults to current directory)').option('--directories [directories...]', 'target directories containing multiple packages (defaults to current directory)').option('--start-from <startFrom>', 'resume execution from this package directory name (useful for restarting failed builds)').option('--cmd <cmd>', 'shell command to execute in each package directory (e.g., "npm install", "git status")').option('--parallel', 'execute packages in parallel when dependencies allow (packages with no interdependencies run simultaneously)').option('--excluded-patterns [excludedPatterns...]', 'patterns to exclude packages from processing (e.g., "**/node_modules/**", "dist/*")').option('--continue', 'continue from previous tree publish execution').description('Analyze package dependencies in workspace and execute commands in dependency order. Supports built-in commands: commit, publish, link, unlink');
|
|
362
429
|
addSharedOptions(treeCommand);
|
|
363
430
|
const linkCommand = program.command('link').option('--scope-roots <scopeRoots>', 'JSON mapping of scopes to root directories (e.g., \'{"@company": "../"}\')').description('Create npm file: dependencies for local development');
|
|
364
431
|
addSharedOptions(linkCommand);
|
|
@@ -366,7 +433,7 @@ async function getCliConfig(program) {
|
|
|
366
433
|
addSharedOptions(unlinkCommand);
|
|
367
434
|
const audioReviewCommand = program.command('audio-review').option('--include-commit-history', 'include recent commit log messages in context (default: true)').option('--no-include-commit-history', 'exclude commit log messages from context').option('--include-recent-diffs', 'include recent commit diffs in context (default: true)').option('--no-include-recent-diffs', 'exclude recent diffs from context').option('--include-release-notes', 'include recent release notes in context (default: false)').option('--no-include-release-notes', 'exclude release notes from context').option('--include-github-issues', 'include open GitHub issues in context (default: true)').option('--no-include-github-issues', 'exclude GitHub issues from context').option('--commit-history-limit <limit>', 'number of recent commits to include', parseInt).option('--diff-history-limit <limit>', 'number of recent commit diffs to include', parseInt).option('--release-notes-limit <limit>', 'number of recent release notes to include', parseInt).option('--github-issues-limit <limit>', 'number of open GitHub issues to include (max 20)', parseInt).option('--context <context>', 'additional context for the audio review').option('--file <file>', 'audio file path').option('--directory <directory>', 'directory containing audio files to process').option('--max-recording-time <time>', 'maximum recording time in seconds', parseInt).option('--sendit', 'Create GitHub issues automatically without confirmation').description('Record audio, transcribe with Whisper, and analyze for project issues using AI');
|
|
368
435
|
addSharedOptions(audioReviewCommand);
|
|
369
|
-
const reviewCommand = program.command('review').argument('[note]', 'review note to analyze for project issues').option('--include-commit-history', 'include recent commit log messages in context (default: true)').option('--no-include-commit-history', 'exclude commit log messages from context').option('--include-recent-diffs', 'include recent commit diffs in context (default: true)').option('--no-include-recent-diffs', 'exclude recent diffs from context').option('--include-release-notes', 'include recent release notes in context (default: false)').option('--no-include-release-notes', 'exclude release notes from context').option('--include-github-issues', 'include open GitHub issues in context (default: true)').option('--no-include-github-issues', 'exclude GitHub issues from context').option('--commit-history-limit <limit>', 'number of recent commits to include', parseInt).option('--diff-history-limit <limit>', 'number of recent commit diffs to include', parseInt).option('--release-notes-limit <limit>', 'number of recent release notes to include', parseInt).option('--github-issues-limit <limit>', 'number of open GitHub issues to include (max 20)', parseInt).option('--context <context>', 'additional context for the review').option('--sendit', 'Create GitHub issues automatically without confirmation').description('Analyze review note for project issues using AI');
|
|
436
|
+
const reviewCommand = program.command('review').argument('[note]', 'review note to analyze for project issues').option('--include-commit-history', 'include recent commit log messages in context (default: true)').option('--no-include-commit-history', 'exclude commit log messages from context').option('--include-recent-diffs', 'include recent commit diffs in context (default: true)').option('--no-include-recent-diffs', 'exclude recent diffs from context').option('--include-release-notes', 'include recent release notes in context (default: false)').option('--no-include-release-notes', 'exclude release notes from context').option('--include-github-issues', 'include open GitHub issues in context (default: true)').option('--no-include-github-issues', 'exclude GitHub issues from context').option('--commit-history-limit <limit>', 'number of recent commits to include', parseInt).option('--diff-history-limit <limit>', 'number of recent commit diffs to include', parseInt).option('--release-notes-limit <limit>', 'number of recent release notes to include', parseInt).option('--github-issues-limit <limit>', 'number of open GitHub issues to include (max 20)', parseInt).option('--context <context>', 'additional context for the review').option('--sendit', 'Create GitHub issues automatically without confirmation').option('--editor-timeout <timeout>', 'timeout for editor in milliseconds (default: no timeout)', parseInt).description('Analyze review note for project issues using AI');
|
|
370
437
|
addSharedOptions(reviewCommand);
|
|
371
438
|
// Customize help output for review command
|
|
372
439
|
reviewCommand.configureHelp({
|
|
@@ -583,10 +650,9 @@ async function validateAndProcessSecureOptions() {
|
|
|
583
650
|
}
|
|
584
651
|
// Renamed validation function to reflect its broader role
|
|
585
652
|
async function validateAndProcessOptions(options) {
|
|
586
|
-
var _options_commit, _options_commit1, _options_commit2, _options_commit3, _options_commit4, _options_commit5, _options_commit6, _options_audioCommit, _options_audioCommit1, _options_audioCommit2, _options_audioCommit3, _options_release, _options_release1, _options_release2, _options_release3, _options_audioReview, _options_audioReview1, _options_audioReview2, _options_audioReview3, _options_audioReview4, _options_audioReview5, _options_audioReview6, _options_audioReview7, _options_audioReview8, _options_audioReview9, _options_audioReview10, _options_audioReview11, _options_audioReview12, _options_audioReview13, _options_audioReview14, _options_review, _options_review1, _options_review2, _options_review3, _options_review4, _options_review5, _options_review6, _options_review7, _options_review8, _options_review9, _options_review10, _options_publish, _options_publish1, _options_publish2, _options_publish3, _options_publish4, _options_publish5, _options_link, _options_link1, _options_tree, _options_tree1, _options_tree2, _options_tree3, _options_tree4, _options_tree5;
|
|
587
653
|
const contextDirectories = await validateContextDirectories(options.contextDirectories || KODRDRIV_DEFAULTS.contextDirectories);
|
|
588
654
|
const configDir = options.configDirectory || KODRDRIV_DEFAULTS.configDirectory;
|
|
589
|
-
var _options_dryRun, _options_verbose, _options_debug, _options_overrides, _options_model, _options_outputDirectory, _options_preferencesDirectory, _options_discoveredConfigDirs, _options_resolvedConfigDirs,
|
|
655
|
+
var _options_dryRun, _options_verbose, _options_debug, _options_overrides, _options_model, _options_outputDirectory, _options_preferencesDirectory, _options_discoveredConfigDirs, _options_resolvedConfigDirs, _options_excludedPatterns;
|
|
590
656
|
// Skip config directory validation since Cardigantime handles hierarchical lookup
|
|
591
657
|
// Ensure all required fields are present and have correct types after merging
|
|
592
658
|
const finalConfig = {
|
|
@@ -602,77 +668,38 @@ async function validateAndProcessOptions(options) {
|
|
|
602
668
|
// Cardigantime-specific properties (from fileValues or defaults)
|
|
603
669
|
discoveredConfigDirs: (_options_discoveredConfigDirs = options.discoveredConfigDirs) !== null && _options_discoveredConfigDirs !== void 0 ? _options_discoveredConfigDirs : [],
|
|
604
670
|
resolvedConfigDirs: (_options_resolvedConfigDirs = options.resolvedConfigDirs) !== null && _options_resolvedConfigDirs !== void 0 ? _options_resolvedConfigDirs : [],
|
|
605
|
-
// Command-specific options
|
|
671
|
+
// Command-specific options - ensure all defaults are present even for partial configs
|
|
606
672
|
commit: {
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
sendit: (_options_commit_sendit = (_options_commit2 = options.commit) === null || _options_commit2 === void 0 ? void 0 : _options_commit2.sendit) !== null && _options_commit_sendit !== void 0 ? _options_commit_sendit : KODRDRIV_DEFAULTS.commit.sendit,
|
|
610
|
-
messageLimit: (_options_commit_messageLimit = (_options_commit3 = options.commit) === null || _options_commit3 === void 0 ? void 0 : _options_commit3.messageLimit) !== null && _options_commit_messageLimit !== void 0 ? _options_commit_messageLimit : KODRDRIV_DEFAULTS.commit.messageLimit,
|
|
611
|
-
context: (_options_commit4 = options.commit) === null || _options_commit4 === void 0 ? void 0 : _options_commit4.context,
|
|
612
|
-
direction: (_options_commit5 = options.commit) === null || _options_commit5 === void 0 ? void 0 : _options_commit5.direction,
|
|
613
|
-
skipFileCheck: (_options_commit_skipFileCheck = (_options_commit6 = options.commit) === null || _options_commit6 === void 0 ? void 0 : _options_commit6.skipFileCheck) !== null && _options_commit_skipFileCheck !== void 0 ? _options_commit_skipFileCheck : KODRDRIV_DEFAULTS.commit.skipFileCheck
|
|
673
|
+
...KODRDRIV_DEFAULTS.commit,
|
|
674
|
+
...Object.fromEntries(Object.entries(options.commit || {}).filter(([_, v])=>v !== undefined))
|
|
614
675
|
},
|
|
615
676
|
audioCommit: {
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
file: (_options_audioCommit2 = options.audioCommit) === null || _options_audioCommit2 === void 0 ? void 0 : _options_audioCommit2.file,
|
|
619
|
-
keepTemp: (_options_audioCommit3 = options.audioCommit) === null || _options_audioCommit3 === void 0 ? void 0 : _options_audioCommit3.keepTemp
|
|
677
|
+
...KODRDRIV_DEFAULTS.audioCommit,
|
|
678
|
+
...options.audioCommit
|
|
620
679
|
},
|
|
621
680
|
release: {
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
messageLimit: (_options_release_messageLimit = (_options_release2 = options.release) === null || _options_release2 === void 0 ? void 0 : _options_release2.messageLimit) !== null && _options_release_messageLimit !== void 0 ? _options_release_messageLimit : KODRDRIV_DEFAULTS.release.messageLimit,
|
|
625
|
-
context: (_options_release3 = options.release) === null || _options_release3 === void 0 ? void 0 : _options_release3.context
|
|
681
|
+
...KODRDRIV_DEFAULTS.release,
|
|
682
|
+
...options.release
|
|
626
683
|
},
|
|
627
684
|
audioReview: {
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
includeReleaseNotes: (_options_audioReview_includeReleaseNotes = (_options_audioReview2 = options.audioReview) === null || _options_audioReview2 === void 0 ? void 0 : _options_audioReview2.includeReleaseNotes) !== null && _options_audioReview_includeReleaseNotes !== void 0 ? _options_audioReview_includeReleaseNotes : KODRDRIV_DEFAULTS.audioReview.includeReleaseNotes,
|
|
631
|
-
includeGithubIssues: (_options_audioReview_includeGithubIssues = (_options_audioReview3 = options.audioReview) === null || _options_audioReview3 === void 0 ? void 0 : _options_audioReview3.includeGithubIssues) !== null && _options_audioReview_includeGithubIssues !== void 0 ? _options_audioReview_includeGithubIssues : KODRDRIV_DEFAULTS.audioReview.includeGithubIssues,
|
|
632
|
-
commitHistoryLimit: (_options_audioReview_commitHistoryLimit = (_options_audioReview4 = options.audioReview) === null || _options_audioReview4 === void 0 ? void 0 : _options_audioReview4.commitHistoryLimit) !== null && _options_audioReview_commitHistoryLimit !== void 0 ? _options_audioReview_commitHistoryLimit : KODRDRIV_DEFAULTS.audioReview.commitHistoryLimit,
|
|
633
|
-
diffHistoryLimit: (_options_audioReview_diffHistoryLimit = (_options_audioReview5 = options.audioReview) === null || _options_audioReview5 === void 0 ? void 0 : _options_audioReview5.diffHistoryLimit) !== null && _options_audioReview_diffHistoryLimit !== void 0 ? _options_audioReview_diffHistoryLimit : KODRDRIV_DEFAULTS.audioReview.diffHistoryLimit,
|
|
634
|
-
releaseNotesLimit: (_options_audioReview_releaseNotesLimit = (_options_audioReview6 = options.audioReview) === null || _options_audioReview6 === void 0 ? void 0 : _options_audioReview6.releaseNotesLimit) !== null && _options_audioReview_releaseNotesLimit !== void 0 ? _options_audioReview_releaseNotesLimit : KODRDRIV_DEFAULTS.audioReview.releaseNotesLimit,
|
|
635
|
-
githubIssuesLimit: (_options_audioReview_githubIssuesLimit = (_options_audioReview7 = options.audioReview) === null || _options_audioReview7 === void 0 ? void 0 : _options_audioReview7.githubIssuesLimit) !== null && _options_audioReview_githubIssuesLimit !== void 0 ? _options_audioReview_githubIssuesLimit : KODRDRIV_DEFAULTS.audioReview.githubIssuesLimit,
|
|
636
|
-
context: (_options_audioReview8 = options.audioReview) === null || _options_audioReview8 === void 0 ? void 0 : _options_audioReview8.context,
|
|
637
|
-
sendit: (_options_audioReview_sendit = (_options_audioReview9 = options.audioReview) === null || _options_audioReview9 === void 0 ? void 0 : _options_audioReview9.sendit) !== null && _options_audioReview_sendit !== void 0 ? _options_audioReview_sendit : KODRDRIV_DEFAULTS.audioReview.sendit,
|
|
638
|
-
maxRecordingTime: (_options_audioReview_maxRecordingTime = (_options_audioReview10 = options.audioReview) === null || _options_audioReview10 === void 0 ? void 0 : _options_audioReview10.maxRecordingTime) !== null && _options_audioReview_maxRecordingTime !== void 0 ? _options_audioReview_maxRecordingTime : KODRDRIV_DEFAULTS.audioReview.maxRecordingTime,
|
|
639
|
-
audioDevice: (_options_audioReview_audioDevice = (_options_audioReview11 = options.audioReview) === null || _options_audioReview11 === void 0 ? void 0 : _options_audioReview11.audioDevice) !== null && _options_audioReview_audioDevice !== void 0 ? _options_audioReview_audioDevice : KODRDRIV_DEFAULTS.audioReview.audioDevice,
|
|
640
|
-
file: (_options_audioReview12 = options.audioReview) === null || _options_audioReview12 === void 0 ? void 0 : _options_audioReview12.file,
|
|
641
|
-
directory: (_options_audioReview13 = options.audioReview) === null || _options_audioReview13 === void 0 ? void 0 : _options_audioReview13.directory,
|
|
642
|
-
keepTemp: (_options_audioReview14 = options.audioReview) === null || _options_audioReview14 === void 0 ? void 0 : _options_audioReview14.keepTemp
|
|
685
|
+
...KODRDRIV_DEFAULTS.audioReview,
|
|
686
|
+
...options.audioReview
|
|
643
687
|
},
|
|
644
688
|
review: {
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
includeReleaseNotes: (_options_review_includeReleaseNotes = (_options_review2 = options.review) === null || _options_review2 === void 0 ? void 0 : _options_review2.includeReleaseNotes) !== null && _options_review_includeReleaseNotes !== void 0 ? _options_review_includeReleaseNotes : KODRDRIV_DEFAULTS.review.includeReleaseNotes,
|
|
648
|
-
includeGithubIssues: (_options_review_includeGithubIssues = (_options_review3 = options.review) === null || _options_review3 === void 0 ? void 0 : _options_review3.includeGithubIssues) !== null && _options_review_includeGithubIssues !== void 0 ? _options_review_includeGithubIssues : KODRDRIV_DEFAULTS.review.includeGithubIssues,
|
|
649
|
-
commitHistoryLimit: (_options_review_commitHistoryLimit = (_options_review4 = options.review) === null || _options_review4 === void 0 ? void 0 : _options_review4.commitHistoryLimit) !== null && _options_review_commitHistoryLimit !== void 0 ? _options_review_commitHistoryLimit : KODRDRIV_DEFAULTS.review.commitHistoryLimit,
|
|
650
|
-
diffHistoryLimit: (_options_review_diffHistoryLimit = (_options_review5 = options.review) === null || _options_review5 === void 0 ? void 0 : _options_review5.diffHistoryLimit) !== null && _options_review_diffHistoryLimit !== void 0 ? _options_review_diffHistoryLimit : KODRDRIV_DEFAULTS.review.diffHistoryLimit,
|
|
651
|
-
releaseNotesLimit: (_options_review_releaseNotesLimit = (_options_review6 = options.review) === null || _options_review6 === void 0 ? void 0 : _options_review6.releaseNotesLimit) !== null && _options_review_releaseNotesLimit !== void 0 ? _options_review_releaseNotesLimit : KODRDRIV_DEFAULTS.review.releaseNotesLimit,
|
|
652
|
-
githubIssuesLimit: (_options_review_githubIssuesLimit = (_options_review7 = options.review) === null || _options_review7 === void 0 ? void 0 : _options_review7.githubIssuesLimit) !== null && _options_review_githubIssuesLimit !== void 0 ? _options_review_githubIssuesLimit : KODRDRIV_DEFAULTS.review.githubIssuesLimit,
|
|
653
|
-
context: (_options_review8 = options.review) === null || _options_review8 === void 0 ? void 0 : _options_review8.context,
|
|
654
|
-
sendit: (_options_review_sendit = (_options_review9 = options.review) === null || _options_review9 === void 0 ? void 0 : _options_review9.sendit) !== null && _options_review_sendit !== void 0 ? _options_review_sendit : KODRDRIV_DEFAULTS.review.sendit,
|
|
655
|
-
note: (_options_review10 = options.review) === null || _options_review10 === void 0 ? void 0 : _options_review10.note
|
|
689
|
+
...KODRDRIV_DEFAULTS.review,
|
|
690
|
+
...options.review
|
|
656
691
|
},
|
|
657
692
|
publish: {
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
requiredEnvVars: (_options_publish_requiredEnvVars = (_options_publish2 = options.publish) === null || _options_publish2 === void 0 ? void 0 : _options_publish2.requiredEnvVars) !== null && _options_publish_requiredEnvVars !== void 0 ? _options_publish_requiredEnvVars : KODRDRIV_DEFAULTS.publish.requiredEnvVars,
|
|
661
|
-
linkWorkspacePackages: (_options_publish_linkWorkspacePackages = (_options_publish3 = options.publish) === null || _options_publish3 === void 0 ? void 0 : _options_publish3.linkWorkspacePackages) !== null && _options_publish_linkWorkspacePackages !== void 0 ? _options_publish_linkWorkspacePackages : KODRDRIV_DEFAULTS.publish.linkWorkspacePackages,
|
|
662
|
-
unlinkWorkspacePackages: (_options_publish_unlinkWorkspacePackages = (_options_publish4 = options.publish) === null || _options_publish4 === void 0 ? void 0 : _options_publish4.unlinkWorkspacePackages) !== null && _options_publish_unlinkWorkspacePackages !== void 0 ? _options_publish_unlinkWorkspacePackages : KODRDRIV_DEFAULTS.publish.unlinkWorkspacePackages,
|
|
663
|
-
sendit: (_options_publish_sendit = (_options_publish5 = options.publish) === null || _options_publish5 === void 0 ? void 0 : _options_publish5.sendit) !== null && _options_publish_sendit !== void 0 ? _options_publish_sendit : KODRDRIV_DEFAULTS.publish.sendit
|
|
693
|
+
...KODRDRIV_DEFAULTS.publish,
|
|
694
|
+
...options.publish
|
|
664
695
|
},
|
|
665
696
|
link: {
|
|
666
|
-
|
|
667
|
-
|
|
697
|
+
...KODRDRIV_DEFAULTS.link,
|
|
698
|
+
...options.link
|
|
668
699
|
},
|
|
669
700
|
tree: {
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
startFrom: (_options_tree_startFrom = (_options_tree2 = options.tree) === null || _options_tree2 === void 0 ? void 0 : _options_tree2.startFrom) !== null && _options_tree_startFrom !== void 0 ? _options_tree_startFrom : KODRDRIV_DEFAULTS.tree.startFrom,
|
|
673
|
-
cmd: (_options_tree_cmd = (_options_tree3 = options.tree) === null || _options_tree3 === void 0 ? void 0 : _options_tree3.cmd) !== null && _options_tree_cmd !== void 0 ? _options_tree_cmd : KODRDRIV_DEFAULTS.tree.cmd,
|
|
674
|
-
parallel: (_options_tree_parallel = (_options_tree4 = options.tree) === null || _options_tree4 === void 0 ? void 0 : _options_tree4.parallel) !== null && _options_tree_parallel !== void 0 ? _options_tree_parallel : KODRDRIV_DEFAULTS.tree.parallel,
|
|
675
|
-
builtInCommand: (_options_tree_builtInCommand = (_options_tree5 = options.tree) === null || _options_tree5 === void 0 ? void 0 : _options_tree5.builtInCommand) !== null && _options_tree_builtInCommand !== void 0 ? _options_tree_builtInCommand : KODRDRIV_DEFAULTS.tree.builtInCommand
|
|
701
|
+
...KODRDRIV_DEFAULTS.tree,
|
|
702
|
+
...options.tree
|
|
676
703
|
},
|
|
677
704
|
excludedPatterns: (_options_excludedPatterns = options.excludedPatterns) !== null && _options_excludedPatterns !== void 0 ? _options_excludedPatterns : KODRDRIV_DEFAULTS.excludedPatterns
|
|
678
705
|
};
|