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

Function update_helper

src/codegraphcontext/cli/cli_helpers.py:718–732  ·  view source on GitHub ↗

Update/refresh index for a path (alias for reindex). When *quiet* is True (e.g. when invoked from Git hooks with --quiet), Rich console output, including progress rendering, is suppressed.

(path: str, context: Optional[str] = None, quiet: bool = False)

Source from the content-addressed store, hash-verified

716
717
718def update_helper(path: str, context: Optional[str] = None, quiet: bool = False):
719 """Update/refresh index for a path (alias for reindex).
720
721 When *quiet* is True (e.g. when invoked from Git hooks with --quiet),
722 Rich console output, including progress rendering, is suppressed.
723 """
724 if quiet:
725 console.quiet = True
726 try:
727 reindex_helper(path, context)
728 finally:
729 console.quiet = False
730 return
731 console.print("[cyan]Updating repository index...[/cyan]")
732 reindex_helper(path, context)
733
734
735def clean_helper(context: Optional[str] = None):

Callers 1

updateFunction · 0.85

Calls 2

reindex_helperFunction · 0.85
printMethod · 0.80

Tested by

no test coverage detected