MCPcopy Create free account
hub / github.com/CodeGraphContext/CodeGraphContext / update

Function update

src/codegraphcontext/cli/main.py:1503–1517  ·  view source on GitHub ↗

Refresh an existing repository index. This command is intentionally small and hook-friendly; Git hooks installed with `cgc hook install` call it after commits and checkouts.

(
    path: Optional[str] = typer.Argument(None, help="Path to refresh. Defaults to current directory."),
    quiet: bool = typer.Option(False, "--quiet", "-q", help="Reduce output when running from automation"),
    context: Optional[str] = typer.Option(None, "--context", "-c", help="Specific context to use (overrides mode/default)"),
)

Source from the content-addressed store, hash-verified

1501
1502@app.command()
1503def update(
1504 path: Optional[str] = typer.Argument(None, help="Path to refresh. Defaults to current directory."),
1505 quiet: bool = typer.Option(False, "--quiet", "-q", help="Reduce output when running from automation"),
1506 context: Optional[str] = typer.Option(None, "--context", "-c", help="Specific context to use (overrides mode/default)"),
1507):
1508 """
1509 Refresh an existing repository index.
1510
1511 This command is intentionally small and hook-friendly; Git hooks installed
1512 with `cgc hook install` call it after commits and checkouts.
1513 """
1514 _load_credentials()
1515 if path is None:
1516 path = str(Path.cwd())
1517 update_helper(path, context, quiet=quiet)
1518
1519@app.command()
1520def clean(

Callers

nothing calls this directly

Calls 2

_load_credentialsFunction · 0.85
update_helperFunction · 0.85

Tested by

no test coverage detected