Skip to content

Commit ebab554

Browse files
CG-10387: Mintlify doc fix (#69)
# Motivation Adds Missing Doc Pages # Content <!-- Please include a summary of the change --> # Testing <!-- How was the change tested? --> # Please check the following before marking your PR as ready for review - [x] I have added tests for my changes - [x] I have updated the documentation or added new documentation as needed - [x] I have read and agree to the [Contributor License Agreement](../CLA.md)
1 parent 8f59edc commit ebab554

File tree

172 files changed

+82446
-5
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

172 files changed

+82446
-5
lines changed

.gitignore

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,3 @@ graph-sitter-types/typings/**
6565
coverage.json
6666
tests/verified_codemods/codemod_data/repo_commits.json
6767

68-
# =====[ Docs ]=====
69-
# These are auto-generated
70-
docs/api-reference/core/*
71-
docs/api-reference/python/*
72-
docs/api-reference/typescript/*

docs/api-reference/core/Argument.mdx

Lines changed: 513 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/Assignment.mdx

Lines changed: 669 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/AssignmentStatement.mdx

Lines changed: 471 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/Attribute.mdx

Lines changed: 550 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/AwaitExpression.mdx

Lines changed: 442 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/BinaryExpression.mdx

Lines changed: 440 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/BlockStatement.mdx

Lines changed: 487 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/Boolean.mdx

Lines changed: 416 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/Callable.mdx

Lines changed: 551 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/CatchStatement.mdx

Lines changed: 496 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/ChainedAttribute.mdx

Lines changed: 429 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/Class.mdx

Lines changed: 972 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/CodeBlock.mdx

Lines changed: 589 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/Codebase.mdx

Lines changed: 567 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/Comment.mdx

Lines changed: 451 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/CommentGroup.mdx

Lines changed: 436 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/ComparisonExpression.mdx

Lines changed: 443 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/Decorator.mdx

Lines changed: 467 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/Dict.mdx

Lines changed: 421 additions & 0 deletions
Large diffs are not rendered by default.

docs/api-reference/core/Directory.mdx

Lines changed: 196 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,196 @@
1+
---
2+
title: "Directory"
3+
sidebarTitle: "Directory"
4+
icon: ""
5+
description: "Directory representation for codebase.
6+
GraphSitter abstraction of a file directory that can be used to look for files and symbols within a specific directory.
7+
"
8+
---
9+
import {Parameter} from '/snippets/Parameter.mdx';
10+
import {ParameterWrapper} from '/snippets/ParameterWrapper.mdx';
11+
import {Return} from '/snippets/Return.mdx';
12+
import {HorizontalDivider} from '/snippets/HorizontalDivider.mdx';
13+
import {GithubLinkNote} from '/snippets/GithubLinkNote.mdx';
14+
import {Attribute} from '/snippets/Attribute.mdx';
15+
16+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L30-L216" />
17+
18+
19+
## Attributes
20+
<HorizontalDivider />
21+
### <span className="text-primary">classes</span>
22+
<HorizontalDivider light={true} />
23+
<Attribute type={ <><span className="text-gray-200">list[</span> <a href="/api-reference/core/Class" style={ {fontWeight: "inherit", fontSize: "inherit"} }>Class</a> <span className="text-gray-200">]</span></> } description="Get a recursive list of all classes in the directory and its subdirectories." />
24+
25+
### <span className="text-primary">dirpath</span>
26+
<HorizontalDivider light={true} />
27+
<Attribute type={ <code className="text-sm bg-gray-100 px-2 py-0.5 rounded">str</code> } description="
28+
" />
29+
30+
### <span className="text-primary">files</span>
31+
<HorizontalDivider light={true} />
32+
<Attribute type={ <><span className="text-gray-200">list[</span> <a href="/api-reference/core/File" style={ {fontWeight: "inherit", fontSize: "inherit"} }>File</a> <span className="text-gray-200">]</span></> } description="Get a recursive list of all files in the directory and its subdirectories." />
33+
34+
### <span className="text-primary">functions</span>
35+
<HorizontalDivider light={true} />
36+
<Attribute type={ <><span className="text-gray-200">list[</span> <a href="/api-reference/core/Function" style={ {fontWeight: "inherit", fontSize: "inherit"} }>Function</a> <span className="text-gray-200">]</span></> } description="Get a recursive list of all functions in the directory and its subdirectories." />
37+
38+
### <span className="text-primary">global_vars</span>
39+
<HorizontalDivider light={true} />
40+
<Attribute type={ <><span className="text-gray-200">list[</span> <a href="/api-reference/core/Assignment" style={ {fontWeight: "inherit", fontSize: "inherit"} }>Assignment</a> <span className="text-gray-200">]</span></> } description="Get a recursive list of all global variables in the directory and its subdirectories." />
41+
42+
### <span className="text-primary">import_statements</span>
43+
<HorizontalDivider light={true} />
44+
<Attribute type={ <><span className="text-gray-200">list[</span> <a href="/api-reference/core/ImportStatement" style={ {fontWeight: "inherit", fontSize: "inherit"} }>ImportStatement</a> <span className="text-gray-200">]</span></> } description="Get a recursive list of all import statements in the directory and its subdirectories." />
45+
46+
### <span className="text-primary">items</span>
47+
<HorizontalDivider light={true} />
48+
<Attribute type={ <><span className="text-gray-200">dict[str,</span> <a href="/api-reference/core/File" style={ {fontWeight: "inherit", fontSize: "inherit"} }>File</a> <span className="text-gray-200">|</span> <a href="/api-reference/core/Directory" style={ {fontWeight: "inherit", fontSize: "inherit"} }>Directory</a> <span className="text-gray-200">]</span></> } description="
49+
" />
50+
51+
### <span className="text-primary">name</span>
52+
<HorizontalDivider light={true} />
53+
<Attribute type={ <code className="text-sm bg-gray-100 px-2 py-0.5 rounded">str</code> } description="Get the base name of the directory's path." />
54+
55+
### <span className="text-primary">parent</span>
56+
<HorizontalDivider light={true} />
57+
<Attribute type={ <><a href="/api-reference/core/Directory" style={ {fontWeight: "inherit", fontSize: "inherit"} }>Directory</a> <span className="text-gray-200">| None</span></> } description="
58+
" />
59+
60+
### <span className="text-primary">path</span>
61+
<HorizontalDivider light={true} />
62+
<Attribute type={ <code className="text-sm bg-gray-100 px-2 py-0.5 rounded">Path</code> } description="
63+
" />
64+
65+
### <span className="text-primary">subdirectories</span>
66+
<HorizontalDivider light={true} />
67+
<Attribute type={ <><span className="text-gray-200">list[</span> <a href="/api-reference/core/Directory" style={ {fontWeight: "inherit", fontSize: "inherit"} }>Directory</a> <span className="text-gray-200">]</span></> } description="Get a recursive list of all subdirectories in the directory and its subdirectories." />
68+
69+
### <span className="text-primary">symbols</span>
70+
<HorizontalDivider light={true} />
71+
<Attribute type={ <><span className="text-gray-200">list[</span> <a href="/api-reference/core/Symbol" style={ {fontWeight: "inherit", fontSize: "inherit"} }>Symbol</a> <span className="text-gray-200">]</span></> } description="Get a recursive list of all symbols in the directory and its subdirectories." />
72+
73+
74+
## Methods
75+
<HorizontalDivider />
76+
### <span className="text-primary">add_file</span>
77+
Add a file to the directory.
78+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L156-L159" />
79+
80+
81+
<Return return_type={ <code className="text-sm bg-gray-100 px-2 py-0.5 rounded">None</code> } description=""/>
82+
83+
84+
### <span className="text-primary">add_subdirectory</span>
85+
Add a subdirectory to the directory.
86+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L179-L182" />
87+
88+
89+
<Return return_type={ <code className="text-sm bg-gray-100 px-2 py-0.5 rounded">None</code> } description=""/>
90+
91+
92+
### <span className="text-primary">get_class</span>
93+
Get a class by name in the directory and its subdirectories.
94+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L148-L150" />
95+
96+
97+
<Return return_type={ <><a href="/api-reference/core/Class" style={ {fontWeight: "inherit", fontSize: "inherit"} }>Class</a> <span className="text-gray-200">| None</span></> } description=""/>
98+
99+
100+
### <span className="text-primary">get_file</span>
101+
Get a file by its name relative to the directory.
102+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L171-L177" />
103+
104+
105+
<Return return_type={ <><a href="/api-reference/core/File" style={ {fontWeight: "inherit", fontSize: "inherit"} }>File</a> <span className="text-gray-200">| None</span></> } description=""/>
106+
107+
108+
### <span className="text-primary">get_function</span>
109+
Get a function by name in the directory and its subdirectories.
110+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L152-L154" />
111+
112+
113+
<Return return_type={ <><a href="/api-reference/core/Function" style={ {fontWeight: "inherit", fontSize: "inherit"} }>Function</a> <span className="text-gray-200">| None</span></> } description=""/>
114+
115+
116+
### <span className="text-primary">get_global_var</span>
117+
Get a global variable by name in the directory and its subdirectories.
118+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L144-L146" />
119+
120+
121+
<Return return_type={ <><a href="/api-reference/core/Assignment" style={ {fontWeight: "inherit", fontSize: "inherit"} }>Assignment</a> <span className="text-gray-200">| None</span></> } description=""/>
122+
123+
124+
### <span className="text-primary">get_import_statement</span>
125+
Get an import statement by name in the directory and its subdirectories.
126+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L140-L142" />
127+
128+
129+
<Return return_type={ <><a href="/api-reference/core/ImportStatement" style={ {fontWeight: "inherit", fontSize: "inherit"} }>ImportStatement</a> <span className="text-gray-200">| None</span></> } description=""/>
130+
131+
132+
### <span className="text-primary">get_subdirectory</span>
133+
Get a subdirectory by its path relative to the directory.
134+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L194-L196" />
135+
136+
137+
<Return return_type={ <><a href="/api-reference/core/Directory" style={ {fontWeight: "inherit", fontSize: "inherit"} }>Directory</a> <span className="text-gray-200">| None</span></> } description=""/>
138+
139+
140+
### <span className="text-primary">get_symbol</span>
141+
Get a symbol by name in the directory and its subdirectories.
142+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L136-L138" />
143+
144+
145+
<Return return_type={ <><a href="/api-reference/core/Symbol" style={ {fontWeight: "inherit", fontSize: "inherit"} }>Symbol</a> <span className="text-gray-200">| None</span></> } description=""/>
146+
147+
148+
### <span className="text-primary">remove_file</span>
149+
Remove a file from the directory.
150+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L161-L164" />
151+
152+
153+
<Return return_type={ <code className="text-sm bg-gray-100 px-2 py-0.5 rounded">None</code> } description=""/>
154+
155+
156+
### <span className="text-primary">remove_file_by_path</span>
157+
Remove a file from the directory by its path.
158+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L166-L169" />
159+
160+
161+
<Return return_type={ <code className="text-sm bg-gray-100 px-2 py-0.5 rounded">None</code> } description=""/>
162+
163+
164+
### <span className="text-primary">remove_subdirectory</span>
165+
Remove a subdirectory from the directory.
166+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L184-L187" />
167+
168+
169+
<Return return_type={ <code className="text-sm bg-gray-100 px-2 py-0.5 rounded">None</code> } description=""/>
170+
171+
172+
### <span className="text-primary">remove_subdirectory_by_path</span>
173+
Remove a subdirectory from the directory by its path.
174+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L189-L192" />
175+
176+
177+
<Return return_type={ <code className="text-sm bg-gray-100 px-2 py-0.5 rounded">None</code> } description=""/>
178+
179+
180+
### <span className="text-primary">rename</span>
181+
Rename the directory.
182+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L212-L216" />
183+
184+
185+
<Return return_type={ <code className="text-sm bg-gray-100 px-2 py-0.5 rounded">None</code> } description=""/>
186+
187+
188+
### <span className="text-primary">update_filepath</span>
189+
Update the filepath of the directory.
190+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/mintlify-doc-fix/src/codegen/sdk/core/directory.py#L203-L210" />
191+
192+
193+
<Return return_type={ <code className="text-sm bg-gray-100 px-2 py-0.5 rounded">None</code> } description=""/>
194+
195+
196+

0 commit comments

Comments
 (0)