mirror of
https://github.com/Palm1r/QodeAssist.git
synced 2025-12-01 06:52:53 -05:00
feat: Add execution command tool (#273)
This commit is contained in:
@ -28,6 +28,7 @@
|
||||
#include "BuildProjectTool.hpp"
|
||||
#include "CreateNewFileTool.hpp"
|
||||
#include "EditFileTool.hpp"
|
||||
#include "ExecuteTerminalCommandTool.hpp"
|
||||
#include "FindAndReadFileTool.hpp"
|
||||
#include "GetIssuesListTool.hpp"
|
||||
#include "ListProjectFilesTool.hpp"
|
||||
@ -50,6 +51,7 @@ void ToolsFactory::registerTools()
|
||||
registerTool(new CreateNewFileTool(this));
|
||||
registerTool(new EditFileTool(this));
|
||||
registerTool(new BuildProjectTool(this));
|
||||
registerTool(new ExecuteTerminalCommandTool(this));
|
||||
registerTool(new ProjectSearchTool(this));
|
||||
registerTool(new FindAndReadFileTool(this));
|
||||
|
||||
@ -100,6 +102,11 @@ QJsonArray ToolsFactory::getToolsDefinitions(
|
||||
continue;
|
||||
}
|
||||
|
||||
if (it.value()->name() == "execute_terminal_command"
|
||||
&& !settings.enableTerminalCommandTool()) {
|
||||
continue;
|
||||
}
|
||||
|
||||
const auto requiredPerms = it.value()->requiredPermissions();
|
||||
|
||||
if (filter != LLMCore::RunToolsFilter::ALL) {
|
||||
|
||||
Reference in New Issue
Block a user