Community코딩 & 개발github.com

umairmsm/wp-build

wp-site-kit WordPress 빌드의 3단계 - 로컬 DDEV 사이트, 핵심 머스트-유즈 플러그인(모듈), 스킨이 포함된 프레젠테이션 전용 차일드 테마, 콘텐츠 모델(커스텀 포스트 타입, 메타, WP_Query, 렌더 함수), 리드 저장 후 전달하는 문의 파이프라인. wp-site-kit 사이트에서 기능, 템플릿, 콘텐츠 유형, 폼 또는 플러그인 모듈을 빌드하거나 변경할 때 사용합니다.

wp-build란 무엇인가요?

이 스킬은 wp-site-kit 프레임워크를 사용하여 WordPress 사이트를 구축하는 3단계(빌드 단계)를 자동화합니다. 주요 목표는 로컬 DDEV 환경에서 사이트를 실행하고, 모든 실제 콘텐츠 아이템이 핵심 플러그인 함수를 통해 렌더링되며, 문의 데이터가 안전하게 저장, 전달, 삭제되도록 보장하고, 구조 테스트가 통과하도록 하는 것입니다. 이 스킬은 DDEV, wp-site-kit, PHP, WordPress, TypeScript 환경에서 작동하며, `AGENTS.md` 및 `references/architecture.md` 문서를 먼저 읽을 것을 권장합니다. 9단계 프로세스를 통해 로컬 사이트 설정, 예제 콘텐츠 유형 이름 변경, 포스트 메타를 통한 콘텐츠 모델링, 데이터 파일 생성기 스크립트 작성, 템플릿에서 핵심 함수 호출, 문의 파이프라인 구축, 정책 텍스트 중앙화, 새 모듈 추가, 코드 검토 및 커밋을 수행합니다. 'Never' 섹션에서 비즈니스 로직, WP_Query, 가격, pll_* 호출 또는 정책 텍스트를 테마에 넣지 말고, 원시 `$_POST`/`$_GET`을 사용하지 말며, 서드파티 API 키를 노출하지 않는 등 중요한 규칙을 제시합니다. 게이트 조건 체크리스트(SITE_STATUS.md)를 제공하여 단계 완료 여부를 확인할 수 있습니다.

지원 대상~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/umairmsm/wp-site-kit/tree/HEAD/skills/wp-build

Installed? Explore more 코딩 & 개발 skills: steipete/bluebubbles, steipete/eightctl, steipete/blucli · View all 6 →

즐겨 사용하는 AI에게 물어보기

이 에이전트 스킬이 미리 로드된 새 채팅을 엽니다.

문서

3단계: 빌드

목표: 사이트가 로컬에서 실행됩니다. 실제 아이템이 핵심 함수를 통해 렌더링됩니다. 문의가 저장된 후 전달된 후 삭제됩니다. 구조 테스트가 통과합니다.

먼저 읽을 문서: 프로젝트의 AGENTS.md, 그 다음 references/architecture.md.

단계

  1. 로컬 사이트. 프로젝트의 README.md, "첫 실행" 섹션을 따르세요. 그런 다음 확인: ddev wp eval 'echo wp_get_environment_type();'가 local을 출력해야 합니다. 그렇지 않으면 references/local-env.md를 참조하세요. local이 출력될 때까지 사이트는 프로덕션 환경으로 인식합니다: 색인될 수 있고 실제 고객에게 이메일을 보낼 수 있습니다.
  2. 예제 콘텐츠 유형 이름 바꾸기. 콘텐츠가 존재하기 전에 수행하세요. <prefix>_offer가 비즈니스 단어(투어, 서비스, 코스)로 변경됩니다: modules/content.php의 포스트 타입, rewrite 슬러그, 레이블, 함수 이름(_get_offers, _render_offer_card), parts/offer-card.php 파일 및 테스트. 포스트 타입 이름은 20자 제한이 있습니다.
  3. 콘텐츠 모델링. 브리프에 필요한 모든 필드를 찾으세요. 각 필드를 sanitize 콜백과 auth 콜백이 있는 포스트 메타로 등록하세요. 가격은 메타의 숫자입니다. 0은 "요청 시"를 의미하며, 절대 "무료"가 아닙니다. 편집자가 더 풍부한 필드 화면이 필요하면 ACF(무료)를 추가할 수 있지만, 값은 핵심 함수를 통해서만 읽으세요.
  4. 데이터 파일 → 생성기 (소유자가 많은 아이템을 제공하는 경우):
    • 각 아이템당 하나의 Markdown 또는 JSON 파일을 docs/data/<type>/에 유지하세요;
    • 해당 파일에서 포스트를 생성하거나 업데이트하는 멱등성 WP-CLI 스크립트를 작성하세요;
    • --dry-run 옵션을 제공하세요;
    • ddev wp eval-file - < scripts/<name>.php로 실행하세요.
    • 파일이 검토 가능한 진실이며, DB는 복사본입니다.
  5. 템플릿은 섹션당 하나의 핵심 함수를 호출합니다.
    • 레이아웃은 테마에 있습니다: 템플릿, parts/, 스킨 오버라이드.
    • 데이터, 쿼리, 가격, 정책 문장 및 폼은 핵심에서 제공됩니다.
    • 각 호출을 function_exists()로 감싸서, 플러그인이 없어도 템플릿이 치명적 오류를 발생시키지 않도록 하세요.
  6. 문의. 파이프라인을 modules/enquiry.php에 유지하세요 (references/forms-and-leads.md).
    • 세 군데(폼, 핸들러, 세부 정보 상자)에 함께 필드를 추가하세요.
    • 받은 편지함과 발신자를 wp-config.php 상수에 설정하고, 절대 코드에 하드코딩하지 마세요.
  7. 정책 텍스트 (약관, 보증금, 취소): 하나의 함수(예: <prefix>_policy( 'cancellation' ))로 핵심에 넣으세요. 템플릿이 그 함수를 출력하고, 템플릿이 정책 문장을 하드코딩하면 테스트가 실패합니다.
  8. 새 모듈? modules/에 파일 하나, 부트스트랩에 require_once 줄 하나를 추가하고, 같은 커밋에서 tests/structure/core.spec.ts를 업데이트하세요.
  9. 확인 및 커밋.
    • npm run test:structure와 npm run lint:php를 실행하세요 (오류 0).
    • wp-rules-reviewer 에이전트에게 diff를 검토하도록 요청하세요.
    • 커밋하세요 (Conventional Commits).

게이트 (SITE_STATUS.md에 체크)

  • wp_get_environment_type() = local
  • 핵심 플러그인과 차일드 테마 활성화; 스킨 로드
  • 실제 아이템이 핵심 함수를 통해 렌더링됨; 하드코딩된 카드, 가격 또는 슬러그 없음
  • 문의: 저장됨 → 이메일 전송 → 재시도 → 삭제됨; Mailpit에서 종단 간 테스트 완료
  • 구조 테스트 통과; PHPCS 오류 0

절대 하지 말 것

  • 비즈니스 로직, WP_Query, 가격, pll_* 호출 또는 정책 텍스트를 테마에 넣지 마세요.
  • wp_unslash + sanitize 함수 없이 원시 $_POST 또는 $_GET 사용 금지; esc_* 없이 출력 금지.
  • 서드파티 API 키 또는 엔드포인트를 HTML이나 JS에 넣지 마세요. 서버에서 전달하세요.
  • 원시 wp option update로 플러그인 모듈을 토글하지 마세요. 플러그인 자체 UI 또는 CLI를 사용한 후, 영향을 받는 모든 페이지를 다시 확인하세요.
  • 접두사가 없는 함수, 옵션, 훅, 메타 키 또는 nonce를 사용하지 마세요.

Individual skills in this repo

This repo contains 7 individual skills — each has its own dedicated page.

umairmsm/wp-content

Stage 4 of a wp-site-kit WordPress build - real copy and photos. Content truth (facts only from the owner), AI drafts and owner approval, claims audits, banned words and fake proof, legal pages, the photo pipeline (dedupe, real-only, EXIF strip, WebP sizes, alt text, AI image register), and recorded content changes. Use for "write the copy", "add photos", "the owner sent new photos", "check for duplicates", "update prices or text on the live site", "legal pages".

umairmsm/wp-design

Stage 2 of a wp-site-kit WordPress build - design direction, a static HTML/CSS prototype with design tokens, owner sign-off with screenshots, self-hosted fonts, and porting the approved look into a swappable WordPress skin. Use for "design the site", "new look", "redesign", "change colours or fonts", "make a new skin", "port the prototype to WordPress".

umairmsm/wp-kickoff

Stage 1 of a wp-site-kit WordPress build. Use when starting a new WordPress website or taking over or rebuilding an existing one - discovery brief, stack decision, creating the project with bin/wp-site-new, locked decisions, private repo and credentials inventory. Triggers - "new WordPress site", "start a client website", "rebuild this site", "take over this WordPress site".

umairmsm/wp-operate

Stage 8 of a wp-site-kit WordPress build and everything after launch - backups with an off-machine copy, restore drills, the disaster-recovery runbook, credentials inventory, update policy, alerts, and working from more than one machine (bridge file, workstation doctor, encrypted state bundle, rescuing unpushed work). Use for "backup", "restore", "move to a new machine/server", "update plugins", "what if the server dies", "work from the cloud box", "set up a second machine".

umairmsm/wp-seo

Stage 5 of a wp-site-kit WordPress build - titles and descriptions, canonical URLs, one schema owner and JSON-LD, sitemaps, robots.txt and llms.txt, AI crawler access, redirects (301 vs 302), legacy URL maps, Search Console, and adding languages one pilot at a time with Polylang (hreflang, .po/.mo strings, native review). Use for "SEO", "schema", "redirect", "old URLs", "translate the site", "add French/Spanish", "hreflang", "canonical".

umairmsm/wp-ship

Stage 7 of a wp-site-kit WordPress build - staging behind Cloudflare Access, server hardening, safe deploys from a commit (scripts/deploy-safe.sh), database content changes, the launch audit, DNS cutover without breaking a running business, and the first week after launch. Use for "deploy", "set up staging", "go live", "launch", "cutover", "move DNS", "harden the server".

umairmsm/wp-site

Start here for any WordPress website built with wp-site-kit, from an empty folder to a live site. Use when someone says "build a WordPress site", "new website for a client", "where are we on the site", "what is next before launch", or asks to continue a site project. Finds the current stage from SITE_STATUS.md, applies the hard rules, and hands over to the right stage skill.

관련 스킬