mirror of
https://github.com/QwenLM/qwen-code.git
synced 2025-12-20 16:57:46 +00:00
25 lines
597 B
TypeScript
25 lines
597 B
TypeScript
/**
|
|
* @license
|
|
* Copyright 2025 Google LLC
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
*/
|
|
|
|
import type { SlashCommand } from './types.js';
|
|
import { CommandKind } from './types.js';
|
|
import { MessageType, type HistoryItemHelp } from '../types.js';
|
|
|
|
export const helpCommand: SlashCommand = {
|
|
name: 'help',
|
|
altNames: ['?'],
|
|
kind: CommandKind.BUILT_IN,
|
|
description: 'for help on Qwen Code',
|
|
action: async (context) => {
|
|
const helpItem: Omit<HistoryItemHelp, 'id'> = {
|
|
type: MessageType.HELP,
|
|
timestamp: new Date(),
|
|
};
|
|
|
|
context.ui.addItem(helpItem, Date.now());
|
|
},
|
|
};
|