- 표준(diadmin/AI_Wiki_Platform 38f17d7)을 new_project.py 방식으로 복사: PROJECT.md(개발용 · windows, mac, linux), CLAUDE.md, .claude, .obsidian, raw, assets, tools, wiki/00~09·99 (08_화면은 빈 구조, 포탈 예시 제외) - 프로젝트 문서 wiki/10_JJ_Ollama_Manager/: 00_홈(예전 wiki/00 홈.md 갱신 - host 방식·포트 전달), 01_설치, 02_메뉴_사용법, 03_ComfyUI, 04_문제_해결, 05_변경_기록, 06_작업_현황 (Gitea 위키 6페이지 + 10/29~11/3 내용 통합) - 사용자 지시 기록 20261103_1657_위키_정리 - .gitignore/.gitattributes 표준 규칙 합침, README에 위키 안내 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01K3UWnbHEdCxxWhyNx7Cpd2
14 lines
726 B
Python
14 lines
726 B
Python
"""소스 줄 수 검사: 700줄 초과(오류), 400줄 초과(경고) 파일을 출력한다.
|
|
사용: python tools/check_lines.py <폴더>"""
|
|
import sys, pathlib
|
|
EXT = {".py",".kt",".java",".swift",".dart",".c",".cc",".cpp",".h",".hpp",".rs",".cs",".js",".ts",".tsx",".go",".m",".mm"}
|
|
root = pathlib.Path(sys.argv[1] if len(sys.argv) > 1 else "src")
|
|
bad = 0
|
|
for f in sorted(root.rglob("*")):
|
|
if f.suffix.lower() in EXT and f.is_file():
|
|
n = sum(1 for _ in f.open(encoding="utf-8", errors="ignore"))
|
|
if n > 700: print(f"[오류 {n}줄] {f}"); bad += 1
|
|
elif n > 400: print(f"[경고 {n}줄] {f}")
|
|
print("완료" if bad == 0 else f"700줄 초과 {bad}개 — 분리 필요")
|
|
sys.exit(1 if bad else 0)
|