Skip to content

Add setup-sui-contracts skill#10

Open
bidzyyys wants to merge 4 commits into
mainfrom
feat/setup-sui-contracts
Open

Add setup-sui-contracts skill#10
bidzyyys wants to merge 4 commits into
mainfrom
feat/setup-sui-contracts

Conversation

@bidzyyys

@bidzyyys bidzyyys commented Jul 1, 2026

Copy link
Copy Markdown

Summary

Adds a new setup-sui-contracts skill — an instructional guide for scaffolding a Sui Move project that integrates OpenZeppelin Contracts for Sui, mirroring the existing setup-*-contracts skills.

The skill is methodology-first: it teaches the library's discovery chain (llms.txt → package catalogs → package READMEs → examples/ → API & code docs) rather than enumerating components, so it stays correct as the library grows.

What it covers

  • Install the pinned Sui CLI; verify version from the contracts-sui README.
  • sui move new, then wire OZ dependencies from the Move Registry via r.mvr.
  • The override = true fix for diamond dependencies (e.g. integer-math + fixed-point-math).
  • Study the examples and docs before implementing, including local code docs via sui move build --doc.
  • Sui testing conventions: OTW init_for_testing, Clock test helpers + the no-Clock-in-init two-step constraint, and the --warnings-are-errors assertion lint rule.
  • A lean project-side AGENTS.md + CLAUDE.md (mirroring contracts-sui's own convention).
  • Code quality via STYLEGUIDE.md and @mysten/prettier-plugin-move formatting.
  • Build & test with --build-env testnet.

Tracking issue: OpenZeppelin/contracts-sui#421 (skill lives here; issue tracked in contracts-sui).

Add an instructional setup skill for scaffolding Sui Move projects with
OpenZeppelin Contracts for Sui, mirroring the existing setup-* skills.

The skill is methodology-first: it teaches the library's discovery chain
(llms.txt -> package catalogs -> package READMEs -> examples -> API/code
docs) rather than enumerating components, so it stays correct as the
library grows. It covers: installing the pinned Sui CLI, `sui move new`,
wiring MVR deps via `r.mvr` (incl. the `override = true` fix for diamond
dependencies), studying examples and docs before implementing (incl.
`sui move build --doc`), Sui testing conventions (OTW `init_for_testing`,
Clock, assertion lint rule), generating a lean AGENTS.md + CLAUDE.md, code
quality via STYLEGUIDE.md, prettier-move formatting, and building/testing
with `--build-env testnet`.

Validated by six independent cold-start runs: a fresh agent, given only the
skill, composed role-based access control + rate limiter + fixed-point math
+ decimal scaling into one module with green build/test/lint/prettier/doc.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new setup-sui-contracts skill that guides users through scaffolding a Sui Move project that integrates OpenZeppelin Contracts for Sui, with an emphasis on discovering the correct packages/modules via the library’s own metadata and examples.

Changes:

  • Added skills/setup-sui-contracts/SKILL.md with end-to-end guidance for installing Sui, creating a Move package, adding OZ deps via MVR, and recommended build/test/docs workflows.
  • Updated the root README.md skills table to include the new setup-sui-contracts entry.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
skills/setup-sui-contracts/SKILL.md Introduces the new Sui setup skill and its methodology-first workflow.
README.md Adds the new skill to the “Available Skills” table.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread skills/setup-sui-contracts/SKILL.md Outdated
Comment thread skills/setup-sui-contracts/SKILL.md
…he note

Generalize dependency discovery to read the full set of package catalogs
from llms.txt rather than naming a fixed set, so the skill stays correct as
new top-level catalogs are added. State the catalog-path rule generically
(resolve a package Path against its catalog's directory) instead of by
example. Remove the numeric-suffixed build-cache directory aside.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.

bidzyyys added 2 commits July 2, 2026 18:10
…og Docs link

Address PR review: the API reference URL hard-coded `1.x`, which drifts on a
docs major bump. Use a `<major>.x` placeholder and point readers at the
`Docs` link in each catalog table, which always carries the correct version.
Applies to both the skill body and the generated AGENTS.md template.
The prereq said to confirm the local install "matches" the pinned version,
which is too strict — a newer patch/minor works in practice (verified on
1.74.1 against a 1.73.2 pin). Reframe as: match the pin when you can (it's
the tested version), but treat a small drift as a warning, not a blocker.

@ericnordelo ericnordelo left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

setup-sui-contracts: project scaffolding skill

4 participants