Skip to content

Commit eac52a8

Browse files
committed
add tool name
1 parent 8baadf6 commit eac52a8

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

semgrep_metrics.atd

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -291,6 +291,7 @@ type mcp = {
291291
?git_username <ocaml mutable>: string option;
292292
?git_repo <ocaml mutable>: string option;
293293
?git_branch <ocaml mutable>: string option;
294+
?tool_name <ocaml mutable>: string option;
294295
}
295296

296297
(*****************************************************************************)

semgrep_metrics.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -919,6 +919,7 @@ class Mcp:
919919
git_username: Optional[str] = None
920920
git_repo: Optional[str] = None
921921
git_branch: Optional[str] = None
922+
tool_name: Optional[str] = None
922923

923924
@classmethod
924925
def from_json(cls, x: Any) -> 'Mcp':
@@ -935,6 +936,7 @@ def from_json(cls, x: Any) -> 'Mcp':
935936
git_username=_atd_read_string(x['git_username']) if 'git_username' in x else None,
936937
git_repo=_atd_read_string(x['git_repo']) if 'git_repo' in x else None,
937938
git_branch=_atd_read_string(x['git_branch']) if 'git_branch' in x else None,
939+
tool_name=_atd_read_string(x['tool_name']) if 'tool_name' in x else None,
938940
)
939941
else:
940942
_atd_bad_json('Mcp', x)
@@ -963,6 +965,8 @@ def to_json(self) -> Any:
963965
res['git_repo'] = _atd_write_string(self.git_repo)
964966
if self.git_branch is not None:
965967
res['git_branch'] = _atd_write_string(self.git_branch)
968+
if self.tool_name is not None:
969+
res['tool_name'] = _atd_write_string(self.tool_name)
966970
return res
967971

968972
@classmethod

0 commit comments

Comments
 (0)