This is a MoonBit project.
You can browse and install extra skills here: https://github.com/moonbitlang/skills
-
MoonBit packages are organized per directory; each directory contains a
moon.pkgfile listing its dependencies. Each package has its files and blackbox test files (ending in_test.mbt) and whitebox test files (ending in_wbtest.mbt). -
In the toplevel directory, there is a
moon.modfile listing module metadata.moon.mod.jsonis the legacy manifest format.
-
MoonBit code is organized in block style, each block is separated by
///|, the order of each block is irrelevant. In some refactorings, you can process block by block independently. -
Try to keep deprecated blocks in file called
deprecated.mbtin each directory.
-
moon fmtis used to format your code properly. -
moon ideprovides project navigation helpers likepeek-def,outline, andfind-references. See $moonbit-agent-guide for details. -
moon infois used to update the generated interface of the package, each package has a generated interface file.mbti, it is a brief formal description of the package. If nothing in.mbtichanges, this means your change does not bring the visible changes to the external package users, it is typically a safe refactoring. -
In the last step, run
moon info && moon fmtto update the interface and format the code. Check the diffs of.mbtifile to see if the changes are expected. -
Use
moon testfor package- or workspace-scoped MoonBit tests. MoonBit supports snapshot testing; when changes affect outputs, runmoon test --updateto refresh snapshots. -
From the repository root, the integration gates are
just check,just test, andjust build. They cover the root workspace's native and JS targets;just testalso runs the offline OpenSeek cram tests. For changes undereditor/, also runjust editor-testfor its all-target suite; for browser behavior, runjust editor-test-browseras well. -
OpenSeek's desktop file editor is the primary downstream, user-facing editor host. Use
editor/internal/shellas the fast build-and-preview loop for editor UI work. Existing Viewer UI improvements should flow into OpenSeek through its current public APIs with little or no host adaptation. When a new editor UI is intended for OpenSeek, implement the correspondingdesktop/frontend/fileeditoradaptation in the same task; do not make the slower full desktop build and preview the routine editor inner loop. -
Prefer
assert_eqorassert_true(pattern is Pattern(...))for results that are stable or very unlikely to change. Use snapshot tests to record current behavior. For solid, well-defined results (e.g. scientific computations), prefer assertion tests. You can usemoon coverage analyze > uncovered.logto see which parts of your code are not covered by tests.