fpack ships a package skill named fpack-cli
in its pub package (skills/fpack-cli/SKILL.md). It gives AI coding agents (Cursor, Claude Code, Gemini, Copilot, Cline, Codex…) concise, authoritative instructions for fpack: installation,
fpack init, doctor and list, every build target, configuration keys and
FPACK_* variables, Android/macOS/Windows signing, macOS notarization, CI and troubleshooting, with links back to this site.
Install the skill in your project#
Skills are installed from your project's dependencies, so add fpack as a dev dependency (it doesn't affect your app) and run the
skills tool:
dart pub add dev:fpack
dart run skills@ get --package fpack # pick your agent interactively
dart run skills@ get --package fpack --agent cursor # or name it: claude, codex, copilot, cline, …
dart run skills@ get --package fpack --skill fpack-cli # non-interactive (CI/scripts)
The skill is copied into your project's agent folder (for example .agents/skills/fpack-cli/); commit it if your team uses the same agent. Re-run the command after upgrading fpack: the skill is versioned with the package.
You still run fpack itself from the global install (dart pub global activate fpack).
What agents do with it#
When you ask an agent to “build a signed APK and AAB”, “notarize the DMG” or “add a release workflow”, the skill tells it to:
-
use
fpack build <targets>(with--dry-runfirst) instead of hand-writtenflutter buildand packaging scripts; - keep secrets in environment variables, never in
fpack.yaml; -
use only real configuration keys (
fpack init,fpack schema, Configuration); -
use
--jsonand the exit codes in CI, andfpack doctorwhen prerequisites are missing.
Without installing anything, you can also point an agent at the file directly: skills/fpack-cli/SKILL.md.
fpack 在 pub 包中附带一个名为 fpack-cli 的包技能(package skill)(skills/fpack-cli/SKILL.md)。它为 AI 编程助手(Cursor、Claude Code、Gemini、Copilot、Cline、Codex 等)提供简洁、权威的 fpack 使用说明:安装、fpack init、doctor
与 list、所有构建目标、配置键与 FPACK_* 环境变量、Android / macOS / Windows 签名、macOS 公证、CI 和故障排查,并链接回本站的详细文档。
在项目中安装技能#
技能从项目的依赖中安装,因此先把 fpack 添加为开发依赖(不会影响你的应用),再运行 skills
工具:
dart pub add dev:fpack
dart run skills@ get --package fpack # 交互式选择你的 AI 助手
dart run skills@ get --package fpack --agent cursor # 或直接指定:claude、codex、copilot、cline……
dart run skills@ get --package fpack --skill fpack-cli # 非交互式(CI / 脚本)
技能会被复制到项目的智能体目录(例如 .agents/skills/fpack-cli/);如果团队使用同一种助手,可以把它提交到仓库。升级 fpack 后重新运行该命令即可:技能随包的版本一起更新。
fpack 本身仍然通过全局安装运行(dart pub global activate fpack)。
助手会怎么用它#
当你让助手“构建签名的 APK 和 AAB”“公证 DMG”或“添加发布工作流”时,技能会让它:
-
使用
fpack build <目标>(先加--dry-run),而不是手写flutter build和打包脚本; - 密钥只放在环境变量里,绝不写进
fpack.yaml; - 只使用真实存在的配置键(
fpack init、fpack schema、配置); - 在 CI 中使用
--json和退出码,缺少依赖时运行fpack doctor。
不安装也可以直接把这个文件交给助手:skills/fpack-cli/SKILL.md。