Skip to content

Commit 3553788

Browse files
committed
docs: updated API reference
1 parent ef1dba8 commit 3553788

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

docs/api-reference/core/Codebase.mdx

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import {HorizontalDivider} from '/snippets/HorizontalDivider.mdx';
1111
import {GithubLinkNote} from '/snippets/GithubLinkNote.mdx';
1212
import {Attribute} from '/snippets/Attribute.mdx';
1313

14-
<GithubLinkNote link="https://github.com/codegen-sh/codegen/blob/develop/src/codegen/sdk/core/codebase.py#L117-L1539" />
14+
<GithubLinkNote link="https://github.com/codegen-sh/codegen/blob/develop/src/codegen/sdk/core/codebase.py#L117-L1540" />
1515

1616

1717
## Attributes
@@ -257,15 +257,15 @@ Creates a pull request from the current branch to the repository's default branc
257257

258258
### <span className="text-primary">create_pr_comment</span>
259259
Create a comment on a pull request
260-
<GithubLinkNote link="https://github.com/codegen-sh/codegen/blob/develop/src/codegen/sdk/core/codebase.py#L1511-L1513" />
260+
<GithubLinkNote link="https://github.com/codegen-sh/codegen/blob/develop/src/codegen/sdk/core/codebase.py#L1512-L1514" />
261261

262262

263263
<Return return_type={ <code className="text-sm bg-gray-100 px-2 py-0.5 rounded">None</code> } description=""/>
264264

265265

266266
### <span className="text-primary">create_pr_review_comment</span>
267267
Create a review comment on a pull request.
268-
<GithubLinkNote link="https://github.com/codegen-sh/codegen/blob/develop/src/codegen/sdk/core/codebase.py#L1515-L1539" />
268+
<GithubLinkNote link="https://github.com/codegen-sh/codegen/blob/develop/src/codegen/sdk/core/codebase.py#L1516-L1540" />
269269

270270

271271
<Return return_type={ <code className="text-sm bg-gray-100 px-2 py-0.5 rounded">None</code> } description=""/>
@@ -298,15 +298,15 @@ Finds editable objects that overlap with the given source code span.
298298

299299
### <span className="text-primary">from_files</span>
300300
Creates a Codebase instance from multiple files.
301-
<GithubLinkNote link="https://github.com/codegen-sh/codegen/blob/develop/src/codegen/sdk/core/codebase.py#L1421-L1501" />
301+
<GithubLinkNote link="https://github.com/codegen-sh/codegen/blob/develop/src/codegen/sdk/core/codebase.py#L1422-L1502" />
302302

303303

304304
<Return return_type={ <><a href="/api-reference/core/Codebase" style={ {fontWeight: "inherit", fontSize: "inherit"} }>Codebase</a></> } description="A Codebase instance initialized with the provided files"/>
305305

306306

307307
### <span className="text-primary">from_repo</span>
308308
Fetches a codebase from GitHub and returns a Codebase instance.
309-
<GithubLinkNote link="https://github.com/codegen-sh/codegen/blob/develop/src/codegen/sdk/core/codebase.py#L1306-L1372" />
309+
<GithubLinkNote link="https://github.com/codegen-sh/codegen/blob/develop/src/codegen/sdk/core/codebase.py#L1306-L1373" />
310310

311311
<ParameterWrapper>
312312
<Parameter
@@ -328,10 +328,10 @@ Fetches a codebase from GitHub and returns a Codebase instance.
328328
defaultValue="None"
329329
/>
330330
<Parameter
331-
name="full_history"
331+
name="shallow"
332332
type={ <code className="text-sm bg-gray-100 px-2 py-0.5 rounded">bool</code> }
333-
description="Whether to clone the full git history. Defaults to False"
334-
defaultValue="False"
333+
description="Whether to do a shallow clone. Defaults to True"
334+
defaultValue=""
335335
/>
336336
<Parameter
337337
name="language"
@@ -359,7 +359,7 @@ Fetches a codebase from GitHub and returns a Codebase instance.
359359

360360
### <span className="text-primary">from_string</span>
361361
Creates a Codebase instance from a string of code.
362-
<GithubLinkNote link="https://github.com/codegen-sh/codegen/blob/develop/src/codegen/sdk/core/codebase.py#L1375-L1418" />
362+
<GithubLinkNote link="https://github.com/codegen-sh/codegen/blob/develop/src/codegen/sdk/core/codebase.py#L1376-L1419" />
363363

364364

365365
<Return return_type={ <><a href="/api-reference/core/Codebase" style={ {fontWeight: "inherit", fontSize: "inherit"} }>Codebase</a></> } description="A Codebase instance initialized with the provided code Example: >>> # Python code >>> code = &quot;def add(a, b): return a + b&quot; >>> codebase = Codebase.from_string(code, language=&quot;python&quot;) >>> # TypeScript code >>> code = &quot;function add(a: number, b: number): number { return a + b; }&quot; >>> codebase = Codebase.from_string(code, language=&quot;typescript&quot;)"/>
@@ -465,7 +465,7 @@ Retrieves a function from the codebase by its name.
465465

466466
### <span className="text-primary">get_modified_symbols_in_pr</span>
467467
Get all modified symbols in a pull request
468-
<GithubLinkNote link="https://github.com/codegen-sh/codegen/blob/develop/src/codegen/sdk/core/codebase.py#L1503-L1509" />
468+
<GithubLinkNote link="https://github.com/codegen-sh/codegen/blob/develop/src/codegen/sdk/core/codebase.py#L1504-L1510" />
469469

470470

471471
<Return return_type={ <code className="text-sm bg-gray-100 px-2 py-0.5 rounded">tuple[str, dict[str, str], list[str]]</code> } description=""/>

0 commit comments

Comments
 (0)