MCPcopy
hub / github.com/github/awesome-copilot / _line_count

Function _line_count

skills/code-tour/scripts/validate_tour.py:41–46  ·  view source on GitHub ↗
(path: Path)

Source from the content-addressed store, hash-verified

39
40
41def _line_count(path: Path) -> int:
42 try:
43 with open(path, errors="replace") as f:
44 return sum(1 for _ in f)
45 except Exception:
46 return 0
47
48
49def _file_content(path: Path) -> str:

Callers 1

validate_tourFunction · 0.85

Calls 1

openFunction · 0.50

Tested by

no test coverage detected