npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

markdown-to-document-cli

v1.5.13

Published

Professional-grade EPUB/PDF conversion tool for Markdown files. 8 validation modules, auto-fix, typography presets, font subsetting (99% size reduction), ISBN validation, copyright page generation.

Downloads

1,954

Readme

Markdown to Document CLI

🚀 전문 출판 수준의 EPUB/PDF 변환 도구 | v1.5.0

마크다운 문서를 완벽한 품질의 EPUB/PDF로 변환하는 CLI 도구입니다. 옵시디언 플러그인 "Markdown to Document Pro"의 핵심 기능을 NPM/NPX 패키지로 제공합니다.

✨ v1.5.0 업데이트 (2026-01-08):

  • 🔧 코드 품질 개선: 163줄 코드 감소, 모듈화된 구조
  • 📊 파일 미리보기: 경로, 크기, 수정일 자동 표시
  • 🎯 메타데이터 자동 추출: frontmatter 제목/저자 즉시 확인
  • 🔄 변환 후 액션 메뉴: 파일 열기/다른 파일 변환/종료 선택

✨ 주요 기능

📚 핵심 변환 기능

  • EPUB 3.3 / PDF 형식 지원
  • 자동 표지 생성: 테마별 고해상도 SVG(EPUB) 및 HTML(PDF) 표지 자동 삽입
  • 4가지 타이포그래피 프리셋 (소설, 발표, 리뷰, 전자책)
  • 자동 목차 생성 (계층형 네비게이션)
  • 챕터별 파일 분리 (H1 기준)
  • 한글 최적화: Noto Sans/Serif KR 임베딩 및 가독성 높은 레이아웃

🎯 Obsidian Flavored Markdown 완벽 지원

자동 변환되는 Obsidian 문법:

  • Wikilinks: [[Note]], [[Note|Display]], [[Note#Heading]] → 표준 마크다운 링크
  • 이미지 임베드: ![[image.png]], ![[image.png|300]] → 표준 이미지 문법
  • Callouts: > [!note], > [!warning] → 스타일이 적용된 blockquote
  • Highlights: ==text==<mark>text</mark>
  • Comments: %%hidden%% → 자동 제거
  • Block References: ^block-id → 자동 제거
  • Heading Links: [[#Heading]] → 같은 페이지 앵커 링크

자동 감지 및 분석:

  • Task Lists: - [ ], - [x]
  • Math (LaTeX): $inline$, $$block$$
  • Mermaid Diagrams: ```mermaid
  • Tags: #tag, #nested/tag
  • Footnotes: [^1]

🔍 8개 검증 모듈 (자동 수정)

  1. Frontmatter 검증: YAML 구문 오류 자동 수정
  2. 제목 검증: H1 중복 감지, 레벨 갭 수정
  3. 링크 검증: Obsidian 링크 자동 변환 ([[링크]][링크](링크))
  4. 이미지 검증: 파일 존재, 크기, alt 텍스트 확인
  5. 표 검증: 열 일관성, 헤더 자동 추가
  6. 구문 검증: 닫히지 않은 코드 블록 자동 수정
  7. 특수문자 검증: 이모지 처리, ASCII 다이어그램 경고
  8. 접근성 검증: WCAG 2.1 AA 표준 준수

🎨 타이포그래피 프리셋

| 프리셋 | 용도 | 특징 | |--------|------|------| | 소설 | 장편 소설, 에세이 | 16pt, 들여쓰기, 양쪽 정렬, 세리프 폰트 | | 발표 | 프레젠테이션, 강의 | 18pt, 큰 글씨, 넓은 여백, 산세리프 폰트 | | 리뷰 | 검토용 문서 | 15pt, 촘촘한 레이아웃, 코드 블록 강조 | | 전자책 | 일반 전자책 | 14pt, 균형잡힌 레이아웃, 산세리프 폰트 |

🔧 고급 기능

TypographyService

  • 11개 프리셋 지원: Basic(4), Content-focused(4), Document Type(3) 카테고리별 레이아웃 최적화
  • 동적 CSS 생성: 타이포그래피 프리셋 기반 자동 스타일링
  • 한국어 최적화: word-break: keep-all, orphans/widows 제어 등 전문 출판 수준의 가독성
  • 한국어 폰트 스택: Noto Sans CJK KR, Noto Serif CJK KR 지원
  • 페이지 마진 설정: 각 프리셋별 최적화된 여백
  • 제목 스케일: H1-H6 비율 자동 계산
  • 하이픈 처리: 단어 끊기 옵션 지원

CoverService

  • 15개 테마 지원: Basic(6), Professional(3), Creative(4), Seasonal(3) 카테고리별 다양한 디자인
  • EPUB 최적화: 고해상도 벡터 SVG 표지 생성 및 임베딩
  • PDF 최적화: HTML Fragment 기술을 이용한 전면 페이지 레이아웃 구현
  • 메타데이터 연동: 입력된 제목과 저자명을 표지에 자동 반영
  • 99% 크기 감소: 사용된 문자만 포함하여 폰트 최적화
  • 캐싱 메커니즘: 재사용을 위한 폰트 캐시
  • 다양한 형식: WOFF2, TTF, OTF 지원
  • 문자 분석: 문서 내 사용된 문자 자동 추출

PandocService 통합

  • 자동 CSS 적용: 변환 시 타이포그래피 CSS 자동 적용
  • 임시 디렉토리 관리: 안전한 임시 파일 처리
  • 버전 호환성: Pandoc 2.x 및 3.x 지원

🪟 Windows 완전 초보자 가이드

🎯 목표: 컴퓨터에 아무것도 없는 상태에서 전자책을 만들 수 있는 환경 구축

🍳 요리로 이해하기

| 비유 | 실제 | 역할 | |------|------|------| | 🔥 가스레인지 | Node.js | 프로그램 실행 환경 | | 🍳 프라이팬 | Pandoc | 문서 변환 도구 | | 🧑‍🍳 요리사 | NpxMagicDoc | 모든 것을 조합하는 셰프 | | 🖨️ 오븐 | Python + WeasyPrint | PDF 만들 때만 필요 |

💡 핵심: Node.js + Pandoc만 있으면 EPUB 변환 가능!
PDF도 원하면 Python + WeasyPrint 추가 설치

1️⃣ Node.js 설치 (가스레인지)

  1. nodejs.org 방문
  2. LTS 버전 (왼쪽 초록 버튼) 다운로드
  3. 설치 시 "Automatically install the necessary tools" 체크 ☑️
  4. 설치 완료 후 컴퓨터 재시작
# 확인 (PowerShell에서)
node --version   # v20.x.x 나오면 성공!

2️⃣ Pandoc 설치 (프라이팬)

  1. pandoc.org/installing.html 방문
  2. Windows 설치 파일 다운로드 (.msi)
  3. 더블클릭해서 설치
# 확인 (새 PowerShell 창에서)
pandoc --version   # pandoc 3.x.x 나오면 성공!

🎉 여기까지 하면 EPUB 변환 가능!

npx markdown-to-document-cli@latest interactive

3️⃣ Python 설치 (PDF용 오븐)

⚠️ PDF 변환에 필요합니다! (EPUB만 필요하면 건너뛰세요)

  1. python.org/downloads 방문
  2. "Download Python 3.x.x" 클릭
  3. ⚠️ 매우 중요! 설치 시 "Add python.exe to PATH" 반드시 체크 ☑️
  4. "Install Now" 클릭
  5. 컴퓨터 재시작
# 확인
python --version   # Python 3.x.x 나오면 성공!

4️⃣ [필수] WeasyPrint 설치 (PDF 엔진)

⚠️ PDF 변환에 필수! v1.5.7부터 Windows에서 WeasyPrint 없이 PDF 변환 시 에러가 발생합니다.

pip install weasyprint
weasyprint --version   # 성공 확인

왜 필수인가요?

  • WeasyPrint: Mac과 100% 동일한 고품질 PDF 생성
  • LaTeX (MiKTeX): HTML 태그 노출, 레이아웃 깨짐 발생
  • v1.5.7부터 Windows에서 LaTeX 자동 선택이 차단됩니다

🧯 Windows 설치 오류 (libgobject-2.0-0)

# 오류 메시지 예시
WeasyPrint could not import some external libraries...
OSError: cannot load library 'libgobject-2.0-0'

| 원인 | 해결 방법 | |------|-----------| | GTK/Pango DLL 미설치 | 1) MSYS2 설치 2) MSYS2 UCRT64 터미널에서 pacman -Syu 3) pacman -S mingw-w64-ucrt-x86_64-gtk3 mingw-w64-ucrt-x86_64-pango mingw-w64-ucrt-x86_64-cairo | | PATH에 DLL 없음 | C:\msys64\ucrt64\bin 경로를 시스템 PATH에 추가 후 PowerShell 재시작 |

# 설치 후 다시 확인
weasyprint --version

🚀 바로 사용하기

# EPUB 변환 (Node.js + Pandoc만 필요)
npx markdown-to-document-cli@latest "C:\Users\사용자\문서.md" --format epub

# PDF 변환 (Python + WeasyPrint 필요)
npx markdown-to-document-cli@latest "C:\Users\사용자\문서.md" --format pdf

# 대화형 모드 (가장 쉬움!)
npx markdown-to-document-cli@latest interactive

💡 Windows 터미널 붙여넣기 팁

Ctrl+V가 안 될 때: | 방법 | 설명 | |------|------| | 마우스 오른쪽 클릭 | 가장 확실한 방법! 클릭만 하면 붙여넣기 | | Ctrl+Shift+V | 일부 최신 터미널에서 작동 | | Windows Terminal 설치 | Microsoft Store에서 설치, Ctrl+V 기본 지원 |

💡 CMD 창 제목 표시줄 우클릭 → 속성 → "Ctrl 키 바로 가기 사용" 체크하면 Ctrl+V 활성화!

❓ 문제 해결

| 오류 | 해결 방법 | |------|-----------| | 'm2d' 인식 안됨 | npx 사용: npx markdown-to-document-cli@latest interactive | | 'node' 인식 안됨 | 컴퓨터 재시작 후 새 PowerShell 열기 | | 'python' 인식 안됨 | Python 삭제 → 재설치 시 PATH 체크 | | 'pip' 인식 안됨 | Python 재설치 필요 | | Ctrl+V 안됨 | 마우스 오른쪽 클릭으로 붙여넣기 |

📚 상세 가이드: TroubleShooting.md의 "Windows 완전 초보자를 위한 설치 가이드" 참조


📦 설치

NPX로 바로 사용 (권장)

npx markdown-to-document-cli@latest input.md

전역 설치

npm install -g markdown-to-document-cli

⚠️ Windows 사용자 주의: 전역 설치 후 m2d 명령어가 인식되지 않을 수 있습니다!

해결 방법 (택 1):

  1. npx 사용 (권장): npx markdown-to-document-cli@latest interactive
  2. PATH 추가: %APPDATA%\npm을 시스템 PATH에 추가 후 새 터미널 열기
  3. 전체 경로: "%APPDATA%\npm\m2d.cmd" interactive

📚 상세 가이드: TroubleShooting.md → "Windows에서 'm2d' 인식 안됨" 참조

로컬 설치

npm install markdown-to-document-cli

🚀 사용법

📁 파일 경로 입력 방법

올바른 경로 입력 (권장):

# 방법 1: 드래그 앤 드롭 (가장 쉬움)
# 파일을 터미널 창으로 드래그하면 경로가 자동 입력됩니다

# 방법 2: 절대 경로
# macOS/Linux
m2d /Users/username/documents/my-document.md
# Windows 로컬
m2d C:\Users\username\documents\my-document.md
# Windows 네트워크 공유 (UNC 경로)
m2d \\Mac\Home\documents\my-document.md

# 방법 3: 상대 경로
m2d ./docs/document.md
m2d ../project/README.md

⚠️ 피해야 할 경로 입력:

# ❌ 백슬래시 이스케이프가 포함된 경로
m2d /Users/username/My\ Documents/file.md

# ✅ 대신 이렇게 (따옴표 사용 또는 드래그 앤 드롭)
m2d "/Users/username/My Documents/file.md"

자동 경로 정리 기능:

  • 백슬래시 이스케이프 자동 제거
  • 따옴표 자동 제거
  • 공백이 포함된 경로 자동 처리
  • 상대 경로를 절대 경로로 자동 변환

Interactive Mode (권장)

# 대화형 모드로 실행
npx markdown-to-document-cli@latest interactive
# 또는
m2d i

간소화된 3단계 워크플로우:

| Step | 내용 | |------|------| | Step 1 | 📄 파일 선택 | | Step 2 | 🚀 변환 모드 선택 + 자동 문서 분석 | | Step 3 | ⚡ 변환 실행 |

2가지 변환 모드:

  • ⚡ 빠른 변환 - 출력 형식만 선택, 스마트 기본값 자동 적용 (권장)
  • ⚙️ 상세 설정 - 프리셋, 테마, 제목/저자 직접 선택

스마트 기능:

  • 문서 분석 기반 프리셋 자동 추천
  • frontmatter에서 title/author 자동 추출
  • Obsidian 문법 감지 시 자동 전처리

기본 사용법

# 기본 변환 (권장: EPUB + PDF)
npx markdown-to-document-cli@latest document.md

# PDF 변환
npx markdown-to-document-cli@latest document.md --format pdf

# EPUB + PDF 동시 변환
npx markdown-to-document-cli@latest document.md --format both

# 전역 설치 후 사용
m2d document.md

옵션

m2d document.md [options]

옵션:
  -o, --output <path>          출력 디렉토리
  --title <title>              책 제목 (frontmatter title 또는 파일명 기본값)
  --author <author>            저자명 (frontmatter author 기본값)
  -f, --format <format>        출력 형식 (epub, pdf, both) [기본값: both]
  -t, --typography <preset>    타이포그래피 프리셋 (auto 포함) [기본값: auto]
                               Basic: novel, presentation, review, ebook
                               Content: text_heavy, table_heavy, image_heavy, balanced
                               Document: report, manual, magazine
  -c, --cover <theme>          표지 테마
                               Basic: apple, modern_gradient, dark_tech, nature, classic_book, minimalist
                               Professional: corporate, academic, magazine
                               Creative: sunset, ocean, aurora, rose_gold
                               Seasonal: spring, autumn, winter
  --no-validate                콘텐츠 검증 건너뛰기
  --no-auto-fix                자동 수정 비활성화
  --toc-depth <number>         목차 깊이 [기본값: 2]
  --no-toc                     목차 비활성화
  --pdf-engine <engine>        PDF 엔진 (auto, pdflatex, xelatex, weasyprint) [기본값: auto]
  --paper-size <size>          용지 크기 (a4, letter) [기본값: a4]
  --font-subsetting            폰트 서브세팅 활성화
  --css <path>                 커스텀 CSS 파일 경로
  --pandoc-path <path>         Pandoc 실행 파일 경로
  -v, --verbose                상세 출력
  -h, --help                   도움말 표시

예제

# 소설용 타이포그래피로 EPUB 변환
m2d novel.md --format epub --typography novel

# 발표용 PDF 생성
m2d presentation.md --format pdf --typography presentation --pdf-engine weasyprint

# 출력 디렉토리 지정
m2d document.md --output ./output

# 커스텀 CSS 적용
m2d document.md --css ./custom.css

# 검증 없이 빠르게 변환
m2d document.md --no-validate --no-auto-fix

# 상세 로그 출력
m2d document.md --verbose

인터랙티브 모드

m2d interactive
# 또는
m2d i

인터랙티브 모드는 사용자 친화적인 프롬프트를 통해 변환 옵션을 선택할 수 있습니다:

  • ✅ 따옴표가 포함된 파일 경로 자동 처리
  • 🎨 색상 코딩된 프롬프트와 이모지
  • 📊 개선된 스피너 애니메이션
  • 📦 더 나은 출력 포맷팅
  • 📖 책 제목과 저자명 직접 입력 가능

가이드에 따라 옵션을 선택할 수 있습니다.

프리셋 및 테마 목록

# 타이포그래피 프리셋 목록
m2d list-presets

# 표지 테마 목록
m2d list-themes

의존성 확인 (권장)

변환을 시작하기 전에 필요한 도구들이 모두 설치되어 있는지 확인하세요:

m2d check

자동으로 확인하는 항목:

  • ✅ Node.js (필수)
  • ✅ Pandoc (필수)
  • ✅ PDF 엔진: WeasyPrint, XeLaTeX, PDFLaTeX 중 최소 1개
  • ⚪ Python (WeasyPrint 사용 시 필요)

설치되지 않은 도구가 있으면:

  • 플랫폼별(macOS, Linux, Windows) 맞춤 설치 명령어 제공
  • 복사해서 바로 사용할 수 있는 명령어
  • 각 도구의 역할 설명

예시 출력:

🔍 의존성 확인 중...

필수 의존성:
  ✅ Node.js (v20.10.0)
  ✅ Pandoc (v3.1.2)

PDF 생성 엔진 (최소 1개 필요):
  ✅ WeasyPrint (v60.1)
  ⚪ XeLaTeX - 미설치
  ⚪ PDFLaTeX - 미설치

✅ 모든 의존성이 준비되었습니다!

🚀 준비 완료! 지금 바로 문서 변환을 시작할 수 있습니다.

⚙️ 필수 요구사항

Pandoc 설치

Pandoc 2.19+ 이상이 필요합니다.

macOS

brew install pandoc

Windows

choco install pandoc

Linux (Ubuntu/Debian)

sudo apt-get update
sudo apt-get install pandoc

Linux (Fedora/RHEL)

sudo dnf install pandoc

WeasyPrint (PDF 생성, 선택사항)

pip install weasyprint

⚠️ Windows 사용자: WeasyPrint는 GTK 런타임이 필요합니다!

# MSYS2 설치 후 (https://www.msys2.org/)
# MSYS2 UCRT64 터미널에서:
pacman -S mingw-w64-ucrt-x86_64-gtk3

# PATH에 C:\msys64\ucrt64\bin 추가 필요

자세한 내용: TroubleShooting.md

📝 프로그래밍 방식 사용

import { MarkdownToDocument } from 'markdown-to-document-cli';

const converter = new MarkdownToDocument();

// 초기화
await converter.initialize();

// 변환
const result = await converter.convert({
  inputPath: './document.md',
  outputPath: './output',
  format: 'epub',
  typographyPreset: 'ebook',
  validateContent: true,
  autoFix: true,
});

if (result.success) {
  console.log('변환 성공!', result.epubPath);
} else {
  console.error('변환 실패:', result.errors);
}

🎯 YAML Frontmatter

문서 상단에 메타데이터를 추가할 수 있습니다:

---
title: 문서 제목
subtitle: 부제목
author: 저자명
language: ko
date: 2025-01-05
description: 문서 설명
isbn: 978-0-1234-5678-9
publisher: 출판사명
---

# 문서 내용

🔬 검증 리포트 예시

=== 검증 완료 ===

✅ 수정됨: 5건
  • Obsidian 링크 3개 변환
  • 코드 블록 1개 자동 닫기
  • 제목 공백 1개 조정

⚠️ 경고: 2건
  • 긴 제목 감지 (자동 조정됨)
  • ASCII 다이어그램 (이미지 권장)

❌ 오류: 0건

총 7개 문제 발견, 5개 자동 수정

📊 기술 스택

  • 언어: TypeScript 5.3+
  • 런타임: Node.js 18+
  • 변환 엔진: Pandoc 2.19+
  • CLI 프레임워크: Commander.js
  • PDF 엔진: WeasyPrint (선택사항)

🐛 문제 해결

❌ PDF 변환 실패: "xelatex not found" 또는 "PDF 엔진을 찾을 수 없습니다"

🤔 왜 이런 오류가 나올까요?

PDF를 만들려면 **"PDF 제작 엔진"**이 필요합니다. 마치 빵을 굽기 위해 오븐이 필요한 것처럼요!

이 오류는 "오븐이 없어서 빵을 구울 수 없어요"라는 뜻입니다. 아래 방법 중 하나를 선택해서 해결하세요.

옵션 1: WeasyPrint 설치 (추천 ⭐)

가장 쉽고 빠른 방법! 한글도 완벽하게 지원합니다.

# Python pip 사용
pip install weasyprint

# 또는 Python 3
pip3 install weasyprint

💡 Python이 없다면? python.org에서 먼저 설치하세요.

옵션 2: XeLaTeX 설치 (한글 최적화)

한글 폰트를 아름답게! 전문 출판 수준의 품질을 원한다면 이걸로!

# macOS (Homebrew)
brew install --cask basictex
# 설치 후 PATH 업데이트
eval "$(/usr/libexec/path_helper)"

# 또는 전체 TeX Live 설치
brew install --cask mactex

# Windows
choco install miktex

# Linux (Ubuntu/Debian)
sudo apt-get install texlive-xetex texlive-fonts-recommended

# Linux (Fedora)
sudo dnf install texlive-xetex

⚠️ 중요: 설치 후 터미널을 다시 시작하세요!
🪟 Windows: MiKTeX 설치 후 첫 실행 시 패키지 자동 설치를 허용하세요.

옵션 3: PDFLaTeX 설치

# macOS
brew install --cask basictex

# Linux (Ubuntu/Debian)
sudo apt-get install texlive-latex-base

✓ 설치 확인하기

오븐이 제대로 설치되었는지 확인해 봅시다:

# WeasyPrint 확인
weasyprint --version

# XeLaTeX 확인
xelatex --version

# PDFLaTeX 확인
pdflatex --version

버전 번호가 나오면 성공! 🎉

💡 프로 팁: 특정 엔진 지정하기

여러 개를 설치했다면, 원하는 엔진을 직접 선택할 수 있습니다:

# 자동 선택 (기본값 - 권장)
m2d document.md --pdf-engine auto

# WeasyPrint로 PDF 만들기
m2d document.md --pdf-engine weasyprint

# XeLaTeX로 PDF 만들기
m2d document.md --pdf-engine xelatex

# PDFLaTeX로 PDF 만들기
m2d document.md --pdf-engine pdflatex

❌ 변환 실패: "require is not defined"

증상:

✖ 변환 실패

❌ 오류:
   • require is not defined

원인:

  • v1.5.2 이하 버전의 ESM/CommonJS 호환성 문제

해결 방법:

최신 버전(v1.5.3 이상)으로 업데이트하세요:

# 캐시 클리어 후 최신 버전 실행
npx clear-npx-cache
npx markdown-to-document-cli@latest interactive

# 또는 전역 설치 업데이트
npm uninstall -g markdown-to-document-cli
npm install -g markdown-to-document-cli

자세한 내용은 TroubleShooting.md를 참조하세요.


Pandoc을 찾을 수 없음

# Pandoc 설치 확인
pandoc --version

# 커스텀 경로 지정
m2d document.md --pandoc-path /path/to/pandoc

설치 방법:

  • macOS: brew install pandoc
  • Windows: choco install pandoc
  • Linux (Ubuntu/Debian): sudo apt-get update && sudo apt-get install pandoc
  • Linux (Fedora/RHEL): sudo dnf install pandoc

Windows PowerShell 실행 정책 오류

증상: Windows PowerShell에서 npx 또는 m2d 실행 시 다음 오류 발생

npx : File C:\Program Files\nodejs\npx.ps1 cannot be loaded because running scripts is disabled on this system.

원인:

  • Windows PowerShell의 기본 실행 정책이 스크립트 실행을 차단함
  • 보안 설정으로 인해 Node.js 스크립트 실행 불가

해결 방법:

옵션 1: CMD 사용 (가장 빠름, 권장)

PowerShell 대신 명령 프롬프트(CMD)를 사용하면 실행 정책 문제가 없습니다:

# CMD(명령 프롬프트) 실행 후
npx markdown-to-document-cli@latest interactive

# 또는 전역 설치 후
m2d interactive

옵션 2: 실행 정책 변경 (영구적 해결)

PowerShell을 관리자 권한으로 실행한 후:

# 현재 사용자에 대해 실행 정책 변경
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser

# 확인 메시지가 나오면 'Y' 입력

그 다음 일반 PowerShell에서 다시 시도:

npx markdown-to-document-cli@latest interactive

옵션 3: 일회성 우회 (임시 해결)

관리자 권한 없이 현재 세션에서만 허용:

Set-ExecutionPolicy -ExecutionPolicy Bypass -Scope Process
npx markdown-to-document-cli@latest interactive

💡 권장: Windows 사용자는 **CMD(명령 프롬프트)**를 사용하는 것이 가장 간단합니다.


파일 경로 오류

증상: "파일을 찾을 수 없습니다" 또는 경로에 백슬래시(\)가 포함됨

해결 방법:

  1. 드래그 앤 드롭 사용 (가장 쉬움)

    • 파일을 터미널 창으로 드래그하세요
    • 경로가 자동으로 입력됩니다
  2. 따옴표로 감싸기

    m2d "/Users/username/My Documents/file.md"
  3. 백슬래시 제거

    # ❌ 잘못된 예
    m2d /Users/username/My\ Documents/file.md
       
    # ✅ 올바른 예
    m2d "/Users/username/My Documents/file.md"

자동 수정 기능: CLI가 자동으로 경로를 정리하고 검증합니다.

이미지를 찾을 수 없음

이미지 파일이 마크다운 파일과 동일한 디렉토리 또는 images/, attachments/, assets/, media/ 폴더에 있는지 확인하세요.

지원하는 이미지 형식: PNG, JPG/JPEG, GIF, SVG, WebP


📚 더 많은 문제 해결

이미지 오류, 한글 깨짐, 검증 문제 등 다양한 상황에 대한 해결책은 전체 문제 해결 가이드를 참고하세요.

📄 라이선스

MIT License - LICENSE 파일 참조

🙏 감사의 말

📧 문의


Made with ❤️ by 잘생김프로쌤