Files
llm-wiki/raw/official-docs/scaffolding-github-template-repository.md

8.0 KiB

title, source_type, url, archive_url, status, confidence, tags, related_projects, related_branches, created, last_reviewed
title source_type url archive_url status confidence tags related_projects related_branches created last_reviewed
GitHub Template Repository — "Use this template" 기반 스캐폴딩 기능 official-doc https://docs.github.com/en/repositories/creating-and-managing-repositories/creating-a-template-repository raw high
ca-tmpl
scaffolding
sample-removal
github-template
repository-feature
official-doc
ca-tmpl
feature-sample-removal-adoption-contract
2026-05-22 2026-05-27

GitHub Template Repository — "Use this template" 기반 스캐폴딩 기능

Layer: raw/official-docs/ — GitHub 공식 문서 "Creating a template repository" 발췌. ca-tmpl Group H — Sample removal / adoption 의 대안 5 (GitHub 자체 scaffolding 메커니즘) 1차 근거.

Parent / 활용 branch (필수)

Branch 이 자료가 정당화하는 결정
raw/branch-notes/feature-sample-removal-adoption-contract Group H 대안 5 — GitHub Template Repository 기능이 ca-tmpl dual-mode CI matrix 와 결합 가능한지 비교의 근거

상위 프로젝트: raw/project-notes/ca-skeleton-operational-contract.

컨텍스트 / 왜 저장했는지

ca-tmpl sample removal / adoption 결정 대안 4. GitHub 자체가 제공하는 가장 단순한 scaffolding 메커니즘. ca-tmpl repo 자체를 "Template repository"로 표시하면 사용자가 GitHub UI에서 "Use this template"로 새 repo를 생성 가능. dual-mode CI / 7-step adoption checklist와의 결합 가능성을 확인.

출처 / Source

핵심 인용 / Key quotes (verbatim)

[§Creating a template repository — Overview] "You can make an existing repository a template, so you and others can generate new repositories with the same directory structure, branches, and files."

[§Creating a template repository — Access] "Anyone with read access to a template repository can create a repository from that template."

[§Creating a repository from a template — Behavior] "A repository created from a template starts with a single commit and isn't a fork of the original repository."

[§Creating a repository from a template — Behavior] "When you create a repository from a template, the new repository has all the files and folders from the template repository, but no commit history."

Claims Extracted / 추출된 주장

Claim ID Claim (이 자료가 직접 말하는 것) Evidence quote Strength Applies to Does not prove
SCAF-GH-C1 기존 저장소를 "template" 으로 표시하면 자신과 타인이 동일한 디렉토리 구조 / 브랜치 / 파일을 가진 새 저장소를 생성할 수 있다 [§Creating a template repository — Overview] "You can make an existing repository a template, so you and others can generate new repositories with the same directory structure, branches, and files." official-vendor-doc GitHub repo 를 scaffolding 출처로 노출하는 시나리오 template 화가 dependency / placeholder 치환을 자동화한다는 뜻은 아님
SCAF-GH-C2 template repository 에 read access 가 있는 누구나 그 template 으로 새 저장소를 생성할 수 있다 [§Creating a template repository — Access] "Anyone with read access to a template repository can create a repository from that template." official-vendor-doc public/internal/private template 의 사용자 접근 모델 "Use this template" 사용에 별도 permission elevation 이 필요한지 / 조직 정책 override 가 가능한지는 본 인용 범위 밖
SCAF-GH-C3 template 으로부터 생성된 repository 는 single commit 으로 시작하며 원본의 fork 가 아니다 [§Creating a repository from a template — Behavior] "A repository created from a template starts with a single commit and isn't a fork of the original repository." official-vendor-doc template 으로 만든 repo 의 git 이력 모델 upstream sync (template 변경 자동 반영) 가 가능하다는 뜻은 아님 — fork 가 아니므로 별도 메커니즘 필요
SCAF-GH-C4 template 으로 생성된 새 repo 는 template 의 모든 파일/폴더를 가지지만 commit history 는 없다 [§Creating a repository from a template — Behavior] "When you create a repository from a template, the new repository has all the files and folders from the template repository, but no commit history." official-vendor-doc template 으로 만든 repo 의 초기 상태 template 의 GitHub Actions / Secrets / Branch protection 같은 repo-level 설정이 모두 함께 복제된다는 뜻은 아님 (파일/폴더 한정)

Usage Boundaries / 적용 경계

  • 이 자료가 직접 증명하는 것:
    • SCAF-GH-C1: template 화 메커니즘의 정의 (same directory structure / branches / files)
    • SCAF-GH-C2: read access 보유자가 사용 가능하다는 접근 모델
    • SCAF-GH-C3: 새 repo 가 single commit + non-fork 라는 git history 모델
    • SCAF-GH-C4: 파일/폴더는 복제되지만 commit history 는 없다는 사실
  • 이 자료가 증명하지 않는 것:
    • GitHub Actions workflow 가 template 화와 함께 무조건 자동 복제·실행된다는 보장 (workflow 파일은 복제되지만 신규 repo 의 secrets / permissions 와의 결합은 별도 확인 필요)
    • 변수 치환 / placeholder 자동 rename 기능 (인용 범위에 없음 — 도입 직후 수동 변경 필요)
    • upstream template 의 후속 업데이트를 자동으로 받을 수 있다는 뜻 (fork 가 아니므로 sync 메커니즘 별도)
    • 7-step adoption checklist 의 모든 항목 (domain rename, package rename) 이 GitHub Actions init workflow 만으로 완전 자동화 가능하다는 뜻은 아님
  • 내 프로젝트에 적용하려면 추가 확인이 필요한 것:
    • ca-tmpl 의 sample-on / sample-off dual-mode CI matrix 가 template repo 의 .github/workflows/ 에 있으면 새 repo 에서도 그대로 실행되는지 (workflow 파일은 따라가지만 sample profile toggle 의 default 가 무엇인지)
    • GitHub Actions 의 "template init workflow" (예: checkout + sed) 로 7-step checklist 일부 자동화 시 권한 모델
    • GitHub template + degit / Initializr 와의 layered scaffolding 시 UX 비교

메모

  • 동작: repo Settings → "Template repository" 체크 → "Use this template" 버튼이 UI에 노출 → 새 repo는 단일 commit으로 시작 (fork 아님).
  • ca-tmpl과의 차이: degit과 유사하게 "복제만". sample-ticket이 그대로 복제됨 → ca-tmpl 2-step removal 필요.
  • 강점: GitHub UI만으로 가능. CI/PR/Actions 설정까지 함께 복제 → ca-tmpl dual-mode CI matrix(sample-on/sample-off)가 그대로 따라옴.
  • 약점: 변수 치환 없음. 도입 직후 패키지명/도메인명/profile 이름은 수동 변경.
  • adoption checklist 자동화: GitHub Actions의 "template repo init workflow"(예: actions/checkout + sed 스크립트)를 결합하면 ca-tmpl 7-step checklist 일부 자동화 가능.
  • 다른 도구와 조합: GitHub template + degit, GitHub template + Initializr custom UI 등 layered scaffolding 가능.
  • 신뢰도: GitHub 공식 문서. official-doc.