mirror of
https://github.com/QwenLM/qwen-code.git
synced 2025-12-20 16:57:46 +00:00
Adding a full_context command line argument. (#158)
* Adding a full_context command line argument. * Update packages/cli/src/config/config.ts Co-authored-by: N. Taylor Mullen <ntaylormullen@google.com> * lint fix. --------- Co-authored-by: N. Taylor Mullen <ntaylormullen@google.com>
This commit is contained in:
@@ -20,6 +20,7 @@ interface CliArgs {
|
||||
model: string | undefined;
|
||||
debug_mode: boolean | undefined;
|
||||
question: string | undefined;
|
||||
full_context: boolean | undefined;
|
||||
}
|
||||
|
||||
function parseArguments(): CliArgs {
|
||||
@@ -42,6 +43,13 @@ function parseArguments(): CliArgs {
|
||||
description:
|
||||
'The question to pass to the command when using piped input.',
|
||||
})
|
||||
.option('full_context', {
|
||||
alias: 'f',
|
||||
type: 'boolean',
|
||||
description:
|
||||
'Recursively include all files within the current directory as context.',
|
||||
default: false,
|
||||
})
|
||||
.help()
|
||||
.alias('h', 'help')
|
||||
.strict().argv;
|
||||
@@ -72,6 +80,7 @@ export function loadCliConfig(): Config {
|
||||
process.cwd(),
|
||||
argv.debug_mode || false,
|
||||
argv.question || '',
|
||||
// TODO: load passthroughCommands from .env file
|
||||
undefined, // TODO: load passthroughCommands from .env file
|
||||
argv.full_context || false,
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user