Office Tools v1.0.0

nested-pdf-merger

Use this skill when the task is to merge PDFs from a nested directory tree into a single PDF with hierarchical bookmarks...

lyutenant 更新于 2026-03-15 1 浏览
下载 SKILL

技能说明

Use this skill when the task is to merge PDFs from a nested directory tree into a single PDF with hierarchical bookmarks by invoking the external `nestedpdfmerger` CLI. This skill depends on the `nestedpdfmerger` binary being installed and available on PATH.

使用场景

This repository wraps the external nestedpdfmerger CLI.

直接复制以下提示词,发送给你的 AI 助手即可完成安装。

帮我下载并安装这个SKILL:https://skillhub.cstcloud.cn/download/nested-pdf-merger
  1. 点击上方「下载 SKILL」按钮,获取技能压缩包。
  2. 将压缩包解压到你的 Agent 技能目录。
  3. 重启客户端后即可在技能列表中选择该技能。

技能文件内容

4 个文件 · 13 kB
SKILL.md text/markdown
---
name: nested-pdf-merger
description: Use this skill when the task is to merge PDFs from a nested directory tree into a single PDF with hierarchical bookmarks by invoking the external `nestedpdfmerger` CLI. This skill depends on the `nestedpdfmerger` binary being installed and available on PATH.
metadata: {"openclaw":{"requires":{"bins":["nestedpdfmerger"]},"homepage":"https://github.com/Lyutenant/nested-pdf-merger"}}
---

# Nested PDF Merger

This repository wraps the external `nestedpdfmerger` CLI.

Do not implement PDF merging logic in this repository.
Do not modify anything under `reference/`.

## Requirements

This skill requires the `nestedpdfmerger` command to be installed and available on `PATH`.

Expected installation command:

```bash
pip install nestedpdfmerger
```

Expected CLI entrypoint:

```bash
nestedpdfmerger INPUT_DIR -o OUTPUT.pdf [options]
```

Alternative module invocation:

```bash
python -m nestedpdfmerger INPUT_DIR -o OUTPUT.pdf [options]
```

## When to use

Use this skill when the user wants to:

- Merge PDF files from a folder tree into one output PDF.
- Preserve the folder hierarchy as PDF bookmarks.
- Preview merge order with `--dry-run`.
- Exclude directories, change sort order, or disable bookmarks.

## Workflow

1. Confirm the input directory and desired output path.
2. Prefer `--dry-run` first when the user wants to validate merge order.
3. Run the CLI with the smallest set of flags needed.
4. If the command fails because the binary is missing, tell the user to install it with `pip install nestedpdfmerger`.

## Supported flags

- `-o, --output PATH`
- `--sort {natural,alpha,mtime}`
- `--reverse`
- `--exclude NAME [NAME ...]`
- `--exclude-hidden`
- `--no-bookmarks`
- `--dry-run`
- `--strict`
- `--verbose`
- `--quiet`
- `--version`

## Examples

Preview merge order:

```bash
nestedpdfmerger ./reports --dry-run
```

Merge with explicit output:

```bash
nestedpdfmerger ./reports --output merged.pdf
```

Merge while excluding folders:

```bash
nestedpdfmerger ./reports --output merged.pdf --exclude Backup Data
```

文件内容直接读取自技能仓库,仅供安装前审阅;以实际下载的压缩包为准。