← Back to Skills Marketplace
yangchao228

Markdown 图片直传 R2

by Sundy Yang · GitHub ↗ · v1.0.3 · MIT-0
cross-platform ✓ Security Clean
56
Downloads
0
Stars
0
Active Installs
4
Versions
Install in OpenClaw
/install md-img-r2
Description
Upload local images in Markdown directly to Cloudflare R2 and replace paths with public URLs.
README (SKILL.md)

md-img-r2

将 Markdown 文件中的本地图片直接上传到 Cloudflare R2,并把本地路径替换为公开 URL。

适用场景

  • 你已经有 Cloudflare R2 桶和可公开访问域名
  • 你不想依赖 PicList Desktop
  • 你希望把这个能力作为可分发 skill 交给别人使用

前置条件

  1. 已有可写入的 Cloudflare R2 凭证
  2. 已有桶名和公开访问域名或 CDN 域名
  3. 运行环境有 python3

推荐配置

优先用环境变量或项目根目录的 .env 提供配置:

  • CF_R2_ACCOUNT_ID
  • CF_R2_ACCESS_KEY_ID
  • CF_R2_SECRET_ACCESS_KEY
  • CF_R2_BUCKET
  • CF_R2_PUBLIC_BASE_URL
  • CF_R2_REGION,默认 auto
  • CF_R2_ENDPOINT,默认 https://\x3Caccount_id>.r2.cloudflarestorage.com
  • CF_R2_KEY_PREFIX,默认 md-assets
  • --env-file 可显式指定 .env 路径;不传时会优先读取 skill 目录下的 .env,再从目标目录向上查找

用法

单文件

bash run.sh path/to/article.md

目录批处理

bash run.sh path/to/dir --recursive

Dry run

bash run.sh path/to/article.md --dry-run

临时覆盖 key 前缀

bash run.sh path/to/article.md --key-prefix posts/2026-04

输出

  • 默认原地修改,并生成备份:xxx.md.bak
  • 生成报告:xxx.md.replace-report.json
Usage Guidance
Treat this result as inconclusive: the review found no evidence of suspicious behavior, but the local artifact inspection failed before metadata.json and artifact contents could be read.
Capability Assessment
Purpose & Capability
Artifact files were not readable through the available command sandbox, so purpose and capability coherence could not be verified from SKILL.md or metadata.json.
Instruction Scope
No artifact-backed instruction-scope issue was identified, but the actual skill instructions could not be inspected.
Install Mechanism
No artifact-backed install risk was identified, but install specs and package contents could not be reviewed.
Credentials
No evidence showed disproportionate environment access, but artifact inspection was blocked.
Persistence & Privilege
No evidence showed persistence or privilege abuse, but artifact files were unavailable for review.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install md-img-r2
  3. After installation, invoke the skill by name or use /md-img-r2
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.3
Document bash run.sh usage so ClawHub zip installs work without executable permissions.
v1.0.2
Ship the R2 config template as r2-config.env so it is included in ClawHub packages.
v1.0.1
Include a non-hidden env.example template for ClawHub packages and update setup guidance.
v1.0.0
Initial release: upload local Markdown images to Cloudflare R2 and replace them with public URLs.
Metadata
Slug md-img-r2
Version 1.0.3
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 4
Frequently Asked Questions

What is Markdown 图片直传 R2?

Upload local images in Markdown directly to Cloudflare R2 and replace paths with public URLs. It is an AI Agent Skill for Claude Code / OpenClaw, with 56 downloads so far.

How do I install Markdown 图片直传 R2?

Run "/install md-img-r2" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Markdown 图片直传 R2 free?

Yes, Markdown 图片直传 R2 is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does Markdown 图片直传 R2 support?

Markdown 图片直传 R2 is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Markdown 图片直传 R2?

It is built and maintained by Sundy Yang (@yangchao228); the current version is v1.0.3.

💬 Comments