emdash-cli
하는 일
이 스킬은 EmDash 명령줄 도구를 사용해 콘텐츠와 미디어부터 스키마와 백업까지 EmDash 웹사이트를 확인하고 관리합니다. 터미널에서 작업하는 것을 선호하는 사이트 소유자와 개발자를 위한 스킬입니다.
사용하는 경우
- ✓터미널에서 EmDash 사이트의 콘텐츠를 나열하거나 추가하거나 바꾸고 싶을 때.
- ✓사이트를 내보내거나 다른 곳으로 가져오려고 할 때.
- ✓데이터베이스 마이그레이션을 준비하거나 프로젝트용 타입을 생성해야 할 때.
스킬 링크
https://github.com/emdash-cms/emdash/blob/main/skills/emdash-cli/SKILL.md복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.
사용 방법
가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.
바로 붙여넣을 수 있는 메시지
Claude Code, Codex, Cursor용입니다. 프로젝트 폴더에서 실행하면 스킬이 설치됩니다.
SKILL.md를 다운로드해 에이전트의 스킬 폴더에 넣으세요.
AI에게 요청하는 예시
“명령줄에서 내 EmDash 사이트의 최신 블로그 글을 나열하고, 사이트 전체를 백업으로 내보내 주세요.”
매주 새 스킬 5개. 읽는 데 1분.
작동 방식
에이전트는 요청에 맞는 명령을 실행합니다. 예를 들어 콘텐츠 목록 조회나 사이트 내보내기입니다. 먼저 현재 사이트를 읽어 대상을 확인하고, 사용자가 정한 범위 안에서만 변경합니다.
기술 내용 (원본 SKILL.md)
작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.
EmDash CLI
The EmDash CLI (emdash, with the short alias em) manages EmDash CMS instances. Commands fall into two categories:
- Local commands work with project files or a configured database:
init,doctor,seed,migrate,export-seed, andsecrets. - Remote commands talk to a running EmDash instance:
types,login,logout,whoami,content,schema,media,search,taxonomy,menu, andsite.
Run npx emdash --help and npx emdash <command> --help for the installed version's exact commands and flags. Resolve the current target with a read command before a destructive or bulk mutation; examples in this skill do not authorize changing an instance the user did not place in scope.
Authentication
Remote commands resolve auth automatically:
--tokenflagEMDASH_TOKENenv var- Stored credentials from
emdash login - Dev bypass (localhost only — no token needed)
For a localhost development server with the development bypass enabled, the client can authenticate automatically. For a remote instance, run emdash login --url https://example.com or provide a scoped token.
Custom Headers & Reverse Proxies
Sites behind Cloudflare Access or other reverse proxies need auth headers on every request. The CLI supports this via --header flags and environment variables.
Service tokens for automation
# Provide sensitive headers through the environment in CI.
export EMDASH_HEADERS="CF-Access-Client-Id: xxx
CF-Access-Client-Secret: yyy"
npx emdash whoami --url https://example.com
emdash login --header persists custom headers to ~/.config/emdash/auth.json for later commands. Prefer environment-provided headers in CI so a service secret is not written to the credential file or shell history.
Cloudflare Access Browser Flow
If you don't have service tokens and cloudflared is installed, the CLI will automatically:
- Detect when Access blocks the request
- Try to get a cached JWT via
cloudflared access token - Fall back to
cloudflared access loginfor browser-based auth
This works for interactive use but isn't suitable for CI. Use service tokens for automation.
Generic Reverse Proxy Auth
The --header flag works with any auth scheme:
# Basic auth
npx emdash login --url https://example.com -H "Authorization: Basic dXNlcjpwYXNz"
# Custom auth header
npx emdash login --url https://example.com -H "X-API-Key: secret123"
Quick Reference
Database Setup
For normal site startup, use the project's package script. The first request runs pending migrations and, before setup is completed, applies the bundled seed's schema and structure once; sample content comes from the setup wizard, /_emdash/api/setup/dev-bypass, or emdash seed. The Astro integration generates emdash-env.d.ts when the server starts.
# Start the site with its package script
pnpm dev
# Export an existing database as a seed file
# (the runtime auto-discovers .emdash/seed.json on first boot;
# `mkdir -p` because the directory may not exist yet)
mkdir -p .emdash
npx emdash export-seed > .emdash/seed.json
npx emdash export-seed --with-content=all > .emdash/seed.json
Type Generation
# Generate types from local dev server
npx emdash types
# Generate from remote
npx emdash types --url https://example.com
# Custom output path
npx emdash types --output src/types/cms.ts
Writes .emdash/types.ts (TypeScript interfaces) and .emdash/schema.json.
Authentication
# Login (OAuth Device Flow)
npx emdash login --url https://example.com
# Check current user
npx emdash whoami
# Logout
npx emdash logout
# Generate an encryption key for deployment
npx emdash secrets generate
Content CRUD
The CLI is designed for agents. Create and update auto-publish by default so agents get read-after-write consistency without managing drafts.
# List content
npx emdash content list posts
npx emdash content list posts --status published --limit 10
# Get a single item (Portable Text fields converted to markdown)
# Returns draft data if a pending draft exists
npx emdash content get posts 01ABC123
npx emdash content get posts 01ABC123 --raw # skip PT->markdown conversion
npx emdash content get posts 01ABC123 --published # ignore pending drafts
# Create content (auto-publishes by default)
npx emdash content create posts --data '{"title": "Hello", "body": "# World"}'
npx emdash content create posts --file po
자주 묻는 질문
어떻게 로그인하나요?
저장된 로그인, 사용자가 제공한 토큰, 또는 localhost에서의 개발용 우회를 사용합니다.
프록시 뒤에 있는 사이트에서도 작동하나요?
네. Cloudflare Access 같은 서비스 뒤에 있는 사이트를 위해 사용자 지정 헤더를 지원합니다.
지정하지 않은 사이트를 바꾸나요?
아니요. 스킬이 먼저 대상을 확인하며, 변경은 사용자가 정한 범위 안에서만 이뤄집니다.
상세 정보
작성자의 원본 설명
Use the EmDash CLI to inspect and manage an EmDash instance from the command line, including content, schema, media, taxonomies, menus, search, authentication, seeds, migrations, generated types, and whole-site export and import.
repo: emdash-cms/emdash
인기도
- GitHub 스타
- 14k
- 순위
- #11248
- 라이선스
- MIT
- 업데이트
- 2026. 11. 2.
댓글
- …
이 저장소의 다른 스킬
adversarial-reviewer
14k에이전트가 코드 변경에서 숨은 버그와 안전하지 않은 가정을 찾도록 돕습니다. 요청하면 일반 리뷰를 넘어서는 심층 탐색을 합니다.
agent-browser
14k에이전트가 실제 브라우저에서 웹 페이지를 열어 동작을 확인하고, 증거로 스크린샷을 남기도록 돕습니다.
building-emdash-site
14k에이전트가 Astro 기반 EmDash CMS 프로젝트의 사이트 부분을 만들도록 돕습니다. 콘텐츠, 스키마, 메뉴, 분류, 배포를 다룹니다.
creating-plugins
14k에이전트가 EmDash CMS용 플러그인을 만들도록 돕습니다. 안전한 훅, 경로, 저장소, 관리자 화면을 포함합니다.
비슷한 스킬
openclaw-update
394k에이전트가 설치 방식에 맞는 방법을 골라 기존 OpenClaw Gateway를 업데이트하고, 세션이 계속 작동하도록 돕습니다.
diagnose-gateway
394k에이전트가 설정, 채널, 포트를 확인해 OpenClaw Gateway가 왜 실패하는지 찾되, 아무것도 바꾸지 않도록 돕습니다.
crabbox-apps
394k에이전트가 임시 클라우드 머신에서 앱을 열고 실행한 뒤, 그 화면을 채팅의 측면 패널에 보여 주도록 돕습니다.