MCPcopy Create free account
hub / github.com/echoVic/blade-code / getExecutionDescription

Method getExecutionDescription

src/tools/builtin/git/git-add.ts:170–188  ·  view source on GitHub ↗

* 获取执行描述

(params: Record<string, any>)

Source from the content-addressed store, hash-verified

168 * 获取执行描述
169 */
170 protected getExecutionDescription(params: Record<string, any>): string {
171 const { files, all, update, dryRun } = params;
172
173 let description = '';
174
175 if (dryRun) {
176 description += '预览要添加的文件';
177 } else if (all) {
178 description += '添加所有修改的文件';
179 } else if (update) {
180 description += '添加所有已跟踪的文件';
181 } else if (files) {
182 description += `添加指定文件: ${files}`;
183 } else {
184 description += '添加当前目录下所有文件';
185 }
186
187 return description;
188 }
189
190 /**
191 * 获取执行预览

Callers 1

confirmExecutionFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected