moonbit-agent-guide

Organize MoonBit projects with standard module and package layouts.

Updated Feb 6, 2026
One-click install
npx skills add https://github.com/f4ah6o/noraft.mbt --skill moonbit-agent-guide-f4ah6o
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: moonbit-agent-guide
Source: https://github.com/f4ah6o/noraft.mbt/tree/main/.opencode/skills/moonbit-agent-guide
Command: npx skills add https://github.com/f4ah6o/noraft.mbt --skill moonbit-agent-guide-f4ah6o

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

MoonBit project teams often struggle with inconsistent project layouts and tooling adoption. This guide standardizes MoonBit module/package layouts and provides a concrete playbook for organizing files, tests, docs, and tooling usage.

Core Features & Use Cases

  • Project layout conventions: defines top-level moon.mod.json, per-package moon.pkg.json, and subdirectories with moon.mod.json as needed.
  • Tooling best practices: outlines how to use moon commands (check, test, info, doc) for continuous quality.
  • Education and onboarding: accelerates new contributors by providing a clear, shared structure and examples.

Quick Start

  1. Clone the MoonBit project and review the repository structure to identify the module root.
  2. Initialize a new MoonBit package by following the standard layout and adding a moon.mod.json at the module root and moon.pkg.json in directories.
  3. Run moon check and moon test to verify type safety and tests across packages, and consult README.mbt.md for documentation generation.

Frequently Asked Questions about moonbit-agent-guide

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I structure a MoonBit project layout?

Structure a MoonBit project by placing a moon.mod.json at the module root and a moon.pkg.json inside each package directory. This standard layout organizes files, tests, and docs consistently across repositories.

What is the best way to test and check a MoonBit module?

The best way to test and check a MoonBit module is using moon commands. Run `moon check` to verify type safety across packages and `moon test` to execute tests, ensuring continuous code quality throughout development.

How do I generate documentation for a MoonBit package?

Generate documentation for a MoonBit package by using the `moon doc` command and consulting README.mbt.md files. This tooling workflow extracts module documentation automatically based on the standardized project layout.

Does a MoonBit project require a specific module configuration file?

Yes, a MoonBit project requires a moon.mod.json file at the module root to define the project. Individual package directories within the module must also include a moon.pkg.json file for proper package configuration.

Why should our team adopt standard MoonBit project layouts?

Adopting standard MoonBit project layouts solves the problem of inconsistent file organization and tooling adoption. It accelerates new contributor onboarding by providing a clear, shared structure and concrete playbook for development.

Can I use moon commands for continuous integration in MoonBit?

Yes, you can use moon commands for continuous integration in MoonBit. Running `moon check` and `moon test` verifies type safety and executes tests across all packages, ensuring continuous quality during development.