Refine context command descriptions
This commit is contained in:
parent
3e467041d7
commit
91d2fd8549
@ -7,7 +7,7 @@ import { UiUtilWrapper } from '../util/uiUtil';
|
||||
|
||||
export const customCommandContext: ChatContext = {
|
||||
name: '<custom command>',
|
||||
description: 'custorm command',
|
||||
description: 'execute your input command and retrieve output',
|
||||
handler: async () => {
|
||||
// popup a dialog to ask for the command line to run
|
||||
const customCommand = await UiUtilWrapper.showInputBox({
|
||||
|
@ -53,7 +53,7 @@ async function getSelectedSymbol(): Promise<vscode.DocumentSymbol | undefined> {
|
||||
|
||||
export const defRefsContext: ChatContext = {
|
||||
name: 'symbol references',
|
||||
description: 'References of symble',
|
||||
description: 'find code sites referencing the selected symbol (class, function, variable, etc.)',
|
||||
handler: async () => {
|
||||
const activeEditor = vscode.window.activeTextEditor;
|
||||
if (!activeEditor) {
|
||||
|
@ -7,7 +7,7 @@ import { logger } from '../util/logger';
|
||||
|
||||
export const gitDiffContext: ChatContext = {
|
||||
name: 'git diff HEAD',
|
||||
description: 'diff for all changes',
|
||||
description: 'all changes since the last commit',
|
||||
handler: async () => {
|
||||
const tempDir = await createTempSubdirectory('devchat/context');
|
||||
const diffFile = path.join(tempDir, 'diff_all.txt');
|
||||
|
@ -7,7 +7,7 @@ import { logger } from '../util/logger';
|
||||
|
||||
export const gitDiffCachedContext: ChatContext = {
|
||||
name: 'git diff --cached',
|
||||
description: 'diff for cached changes',
|
||||
description: 'the staged changes since the last commit',
|
||||
handler: async () => {
|
||||
const tempDir = await createTempSubdirectory('devchat/context');
|
||||
const diffFile = path.join(tempDir, 'diff_cached.txt');
|
||||
|
@ -173,7 +173,7 @@ async function getSymbolDefine(symbolList: string[]): Promise<string[]> {
|
||||
|
||||
export const refDefsContext: ChatContext = {
|
||||
name: 'symbol definitions',
|
||||
description: 'Definitions of symbol',
|
||||
description: 'find related definitions of classes, functions, etc. in selected code',
|
||||
handler: async () => {
|
||||
const selectedText = await getCurrentSelectText();
|
||||
const symbolList = await getUndefinedSymbols(selectedText);
|
||||
|
@ -468,7 +468,7 @@ const InputMessage = observer((props: any) => {
|
||||
borderColor: 'var(--vscode-menu-border)',
|
||||
backgroundColor: 'var(--vscode-menu-background)'
|
||||
}}>
|
||||
<Text sx={{ padding: '5px 5px 5px 10px' }}>DevChat Commands</Text>
|
||||
<Text sx={{ padding: '5px 5px 5px 10px' }}>DevChat Workflows</Text>
|
||||
<ScrollArea.Autosize mah={240} type="always">
|
||||
{commandMenusNode}
|
||||
</ScrollArea.Autosize>
|
||||
|
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "git_log_releasenote",
|
||||
"description": "git log for write release note",
|
||||
"name": "git log for release note",
|
||||
"description": "formatted commit history since the specified commit",
|
||||
"edit": true,
|
||||
"command": ["git log $(git describe --tags --abbrev=0)..HEAD --pretty=format:\"%h - %B\""]
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user