diff --git a/public/BLOCK8_소스코드_전달자료.zip b/public/BLOCK8_소스코드_전달자료.zip new file mode 100644 index 0000000..2c14689 Binary files /dev/null and b/public/BLOCK8_소스코드_전달자료.zip differ diff --git a/scripts/package_handoff.py b/scripts/package_handoff.py new file mode 100644 index 0000000..bb38d69 --- /dev/null +++ b/scripts/package_handoff.py @@ -0,0 +1,53 @@ +#!/usr/bin/env python3 +"""프로젝트 소스와 검토 자료를 전달용 ZIP으로 묶는다.""" + +from pathlib import Path +from zipfile import ZIP_DEFLATED, ZipFile + +ROOT = Path(__file__).resolve().parents[1] +OUTPUT = ROOT / "public/BLOCK8_소스코드_전달자료.zip" +ARCHIVE_ROOT = "광터지하차도_BLOCK8_전달자료" +EXCLUDED = {"BLOCK8_소스코드_전달자료.zip"} + +GUIDE = """# 광터지하차도 BLOCK8 전달 자료 안내 + +이 압축 파일에는 웹 3D 모델의 전체 작성 코드와 결과물, 근거 자료가 들어 있습니다. + +## 실행 방법 + +1. Node.js를 설치합니다. +2. 이 폴더에서 `npm install`을 실행합니다. +3. `npm run dev`를 실행하고 터미널에 나온 주소를 브라우저에서 엽니다. + +## 주요 폴더 + +- `src/`: React 화면, 뷰어, 모델 JSON +- `scripts/`: DXF 모델 추출, SVG 미리보기 생성, 단독 HTML 생성, 전달 ZIP 생성 코드 +- `public/`: 원본 DXF, 분석·작업·커밋 기록, 단독 HTML 결과물 +- `docs/`: 상세 분석과 모델 미리보기 + +## 포함하지 않은 항목 + +`node_modules/`, `dist/`, `.git/`은 포함하지 않았습니다. 의존성은 `npm install`로 설치하고, 빌드 결과는 `npm run build`로 다시 만들 수 있습니다. Git 커밋 목록은 `public/BLOCK8_커밋기록.md`에서 확인하세요. + +현재 기준 커밋: `89065ab` (단독 HTML file 실행 호환성 개선) +""" + + +def main(): + files = [ROOT / "AGENTS.md", ROOT / "README.md", ROOT / "index.html", ROOT / "package.json", ROOT / "package-lock.json", ROOT / "vite.config.js"] + for folder in ("src", "scripts", "docs", "public"): + files.extend(path for path in (ROOT / folder).rglob("*") if path.is_file() and path.name not in EXCLUDED) + files = sorted(set(files)) + + OUTPUT.parent.mkdir(parents=True, exist_ok=True) + with ZipFile(OUTPUT, "w", compression=ZIP_DEFLATED, compresslevel=9) as archive: + archive.writestr(f"{ARCHIVE_ROOT}/전달자료_안내.md", GUIDE) + for path in files: + archive.write(path, f"{ARCHIVE_ROOT}/{path.relative_to(ROOT).as_posix()}") + + print(f"{OUTPUT.relative_to(ROOT)} 생성 완료: {len(files) + 1}개 파일, {OUTPUT.stat().st_size:,} bytes") + + +if __name__ == "__main__": + main() diff --git a/src/App.jsx b/src/App.jsx index bd186b1..caa4b49 100644 --- a/src/App.jsx +++ b/src/App.jsx @@ -59,6 +59,7 @@ export default function App() { 인수인계 파일 ↗ 커밋 기록 ↗ 단독 HTML ↗ + 전체 소스 ZIP ↓ 작업 로그 ↗ 원본 DXF ↓