file-to-download-page

Convert any local file (or multiple files/directories) into an HTML page with a “download” button. The page includes a full information section (problems solved/limitations/environment requirements/use cases), the generated file list shows the .html, and users can click the button to download the original file. Uses blue–orange color scheme with a non-black background and depends only on the Python standard library.

Installation

Review the source and dependencies with a prompt. A package is available to download.

Install with an AI assistant

Copy the prompt so your assistant can review the pinned revision and dependencies first.

View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "file-to-download-page" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-62f973c2c645522d8d30d7c7eda728b287a22f009930c2982b7fd995c5d6ca49. Verify the upstream source and version against https://skillhub.cn/skills/user_1793b15c/file-to-download-page before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.

Source and setup

skillhub.cn

Setup guidance pending

See the original source for supported tools, dependencies, and permissions.

Installation test pending

Convert any local file (or multiple files/directories) into an HTML page with a “download” button. The page includes a full information section (problems solved/limitations/environment requirements/use cases), the generated file list shows the .html, and users can click the button to download the original file. Uses blue–orange color scheme with a non-black background and depends only on the Python standard library.

0 Downloads

Introduction source: third_party · user_1793b15c · 1.0.2 Reference

SkillPi interpretation

Tasks
Translation pending; see source documentation.
Testing
Not tested

Browse files

Browse files at the source ↗

Original SKILL.md

Open original ↗
Frontmatter
name: file-to-download-page
description: 把任意本地文件(或多个文件/目录)变成带"下载"按钮的 HTML 页面,内嵌完整信息区(解决问题/局限性/环境要求/使用场景),产物文件列表会显示该 .html,用户点按钮即可下载原文件。蓝橙配色,非黑色底。仅依赖 Python 标准库。

File → Download Page(文件下载页生成器)

把文件打包成一个带 下载按钮 + 完整信息区 的 HTML 页面。用户打开页面即可了解"这东西干嘛用、有哪些局限、需要什么环境",点按钮直接下载文件。

原理

把文件 base64 编码后写进 <a href="data:<mime>;base64,..." download> 链接里,浏览器点链接直接下载原始字节,文件完整无缺。

  • 单个文件:直接内嵌
  • 多个文件 / 目录:自动先 zipfile 打包成 zip,再内嵌 zip

仅依赖 Python 标准库(base64 / zipfile / html),无需联网、无需第三方包。

用法

# 最简:只有下载按钮
python3 scripts/make_download_page.py comic2video.py -o /tmp/page.html

# 带完整信息区(推荐)
python3 scripts/make_download_page.py comic2video.py \
  -o /tmp/comic2video_download.html \
  --title "comic2video.py · 漫画PDF转翻页视频" \
  --problem "把漫画PDF转成翻页视频|产物文件无法预览|用户无法直接下载.py脚本" \
  --limitations "需要本地Python环境|pip install pymupdf moviepy|超大文件HTML较慢" \
  --requirements "pip install pymupdf moviepy|Windows/Mac/Linux均支持|Python 3.8+" \
  --scenarios "漫画翻页视频|B站/抖音素材|PDF转视频课件|批处理多卷漫画合集"

# 多文件/目录 -> 自动打包成 zip
python3 scripts/make_download_page.py 目录A 文件B.py -o /tmp/page.html --title "我的工具包"

参数

参数 默认值 说明
paths 必填 一个或多个文件 / 目录
-o/--output /workspace/download.html 输出 HTML 路径
--title 文件下载 页面标题(显示在顶部的紫字大标题)
--zip-name files.zip 多文件时打包的 zip 名
--problem 空 🎯 解决什么问题(支持 \| 或换行分隔多条)
--limitations 空 ⚠️ 局限性(支持 \| 或换行分隔多条)
--requirements 空 🔧 环境要求(支持 \| 或换行分隔多条)
--scenarios 空 📖 使用场景(支持 \| 或换行分隔多条)

页面样式

  • 配色:伊顿蓝橙配色(#667eea 紫 + #fa8c16 橙),非黑色底
  • 彩虹分隔线:四种颜色渐变横条分隔各区域
  • 信息区:左侧彩边色条 + 浅色背景,白名单列表展示
  • 下载区:文件卡片横排,文件名 + 大小 + 紫色下载按钮
  • 手机适配:响应式布局,手机上也能正常下载

局限

  • base64 会让 HTML 体积膨胀约 33%。超大文件(>约 8MB 原始)生成的 HTML 会很大,产物文件加载慢;极大型文件建议先用其他方式传输。
  • 浏览器对 data URI 长度有上限(通常数十 MB 级),超大文件可能下载失败,此时应改用分片或外部托管。
  • 多个文件会被合并成单个 zip 下载,而非每个文件独立按钮(保持页面简洁)。

Current listing version

1.0.2

Verify the source revision ↗

Quality assessment

Out of 100 · Assessment report from SkillPi LAB.

Scenario Value78/100

Highlights

  • 解决文件分享时缺乏上下文信息的问题,提升用户体验
  • 支持单文件和多文件/目录处理,适用场景广泛
  • 仅依赖 Python 标准库,部署简单
Trigger Precision92/100

Highlights

  • description 清晰完整,覆盖功能、场景、限制
  • 触发词精准,边界清晰,不易误触
Structure and Standards95/100

Highlights

  • 结构完整,包含原理、用法、参数、样式说明
  • 提供端到端示例,便于用户理解和使用
  • frontmatter 完整,排版规范
Execution Reliability85/100

Areas to improve

  • 输出目录不存在时的处理 Reported severity: Minor

    未明确说明当输出目录不存在时脚本的行为

    Recommendation: 建议在脚本中添加输出目录自动创建逻辑或在文档中明确说明需要确保输出目录存在

Highlights

  • 依赖 Python 标准库,无需第三方包
  • 参数说明清晰,覆盖主要功能点
  • 对超大文件有明确限制说明
Evidence Verifiability (mean of the first four)88/100

The arithmetic mean of the first four original scores, rounded to a whole number.

Static text checks

100 / 100 · skillpi-20261123-no-r3-v1

No current rules matched the text.

This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.

Permissions and checks before use

Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.

  • Install or fetch external dependencies

    Use official sources and pin versions. Check install scripts in an isolated environment. This document check does not cover code downloaded later.

    Mentioned in main document · lines 30, 31

These notices grant no permissions. Your host tool must still confirm file changes, secrets, external transfers or costs as needed.

Security rating and access scope

safe · Static evidence review; not a runtime safety guarantee.

Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.