mirror of
https://github.com/QwenLM/qwen-code.git
synced 2026-04-28 11:41:04 +00:00
feat(cli): prompt completion (#4691)
Co-authored-by: Jacob Richman <jacob314@gmail.com>
This commit is contained in:
parent
ba5309c405
commit
589f5e6823
11 changed files with 540 additions and 43 deletions
|
|
@ -200,6 +200,7 @@ export interface ConfigParameters {
|
|||
trustedFolder?: boolean;
|
||||
shouldUseNodePtyShell?: boolean;
|
||||
skipNextSpeakerCheck?: boolean;
|
||||
enablePromptCompletion?: boolean;
|
||||
}
|
||||
|
||||
export class Config {
|
||||
|
|
@ -267,6 +268,7 @@ export class Config {
|
|||
private readonly trustedFolder: boolean | undefined;
|
||||
private readonly shouldUseNodePtyShell: boolean;
|
||||
private readonly skipNextSpeakerCheck: boolean;
|
||||
private readonly enablePromptCompletion: boolean = false;
|
||||
private initialized: boolean = false;
|
||||
readonly storage: Storage;
|
||||
|
||||
|
|
@ -338,6 +340,7 @@ export class Config {
|
|||
this.shouldUseNodePtyShell = params.shouldUseNodePtyShell ?? false;
|
||||
this.skipNextSpeakerCheck = params.skipNextSpeakerCheck ?? false;
|
||||
this.storage = new Storage(this.targetDir);
|
||||
this.enablePromptCompletion = params.enablePromptCompletion ?? false;
|
||||
|
||||
if (params.contextFileName) {
|
||||
setGeminiMdFilename(params.contextFileName);
|
||||
|
|
@ -731,6 +734,10 @@ export class Config {
|
|||
return this.skipNextSpeakerCheck;
|
||||
}
|
||||
|
||||
getEnablePromptCompletion(): boolean {
|
||||
return this.enablePromptCompletion;
|
||||
}
|
||||
|
||||
async getGitService(): Promise<GitService> {
|
||||
if (!this.gitService) {
|
||||
this.gitService = new GitService(this.targetDir, this.storage);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue