knowledge (구 Aislo-law 독립 저장소 → resources/knowledge 이관, 저장소 폐지): - 법령·행정규칙·표준시방서·교본 원문 + 기술문서 55건 + 실무 분석·종합비교 - 루트 지침 체계: README(지도)·00_운영지침·01_수집지침·02_분석지침· 03_미결_및_확인사항(교본 충돌 리스트 포함)·04_참조_법령기준_목록 - 기술문서 55건 원문 전수 검증 완료 (사방 설계홍수량 법정 기준 등 반영) - 정리: CAD·오피스 잔재 142건, 중복 zip 7건(413MB), 빈 폴더 30개 제거 resources 그룹 재편 (이름순 그룹핑): - app_branding(구 prog_icon.jpg)·app_policies(구 legal)· data_global_contours(구 grobal_contours)·data_rainfall_idf_cache(구 wamis_contours)· template_2dDrawing(구 dwg_analysis/templete — 오타 교정, 상수·경로 동기화) - dwg_analysis(분석 완료 1.8GB)·templates(빈 폴더)·templete_calc_cost.xlsx 삭제 - 참조 코드 5파일 경로 수정 + 프론트 재빌드 (구 경로 잔존 0) - .gitignore: resources 추적 전환, national_contours.gpkg(22GB) 영구 제외 - .env: knowledge 수집용 API 정보 주석 통합 (KCSC·법령센터·조달청 제비율) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
38 lines
1.3 KiB
Python
38 lines
1.3 KiB
Python
# -*- coding: utf-8 -*-
|
|
"""[압축] 폴더마다 _목록.md 생성 — 내부 HWP→md 파일 트리 색인."""
|
|
import sys
|
|
from pathlib import Path
|
|
|
|
ROOT = Path(__file__).resolve().parent.parent
|
|
|
|
def build(folder):
|
|
mds = sorted(p for p in folder.rglob("*.md") if p.name != "_목록.md")
|
|
lines = [f"# {folder.name} — 압축 해제 문서 목록", "",
|
|
f"> 원본 zip을 해제해 HWP를 md로 변환. 총 {len(mds)}건.", ""]
|
|
# 하위 폴더 구조 반영
|
|
tree = {}
|
|
for m in mds:
|
|
rel = m.relative_to(folder)
|
|
parts = rel.parts
|
|
grp = "/".join(parts[:-1]) if len(parts) > 1 else ""
|
|
tree.setdefault(grp, []).append(m)
|
|
for grp in sorted(tree):
|
|
if grp:
|
|
lines.append(f"## {grp}")
|
|
lines.append("")
|
|
for m in tree[grp]:
|
|
rel = m.relative_to(folder).as_posix()
|
|
lines.append(f"- [{m.stem}](<{rel}>)")
|
|
lines.append("")
|
|
(folder / "_목록.md").write_text("\n".join(lines), encoding="utf-8")
|
|
return len(mds)
|
|
|
|
if __name__ == "__main__":
|
|
n = 0
|
|
for folder in ROOT.rglob("[[]압축[]]*"):
|
|
if folder.is_dir():
|
|
c = build(folder)
|
|
n += 1
|
|
print(f" {c:4d}건 {folder.name}")
|
|
print(f"\n압축 색인 {n}개 생성")
|