Generate AGENTS.md when running stellar contract init - #2687
Merged
Conversation
New projects get agent-oriented build, test, and deploy guidance at the workspace root so coding agents can work without extra setup. Co-authored-by: Cursor <cursoragent@cursor.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
Adds an AGENTS.md guidance document to the Soroban contract workspace template and updates tests/docs to ensure it’s generated and contains key build/test instructions.
Changes:
- Add
AGENTS.mdto the workspace template and list it in the template README. - Extend
contract initunit tests to assertAGENTS.mdexists and includes build/test/WASM target guidance. - Extend integration test to assert
AGENTS.mdis present and mentionsstellar contract build.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| cmd/soroban-cli/src/utils/contract-workspace-template/README.md | Updates template file tree to include AGENTS.md. |
| cmd/soroban-cli/src/utils/contract-workspace-template/AGENTS.md | New template documentation covering layout, build, test, deploy, invoke. |
| cmd/soroban-cli/src/commands/contract/init.rs | Updates unit tests to include AGENTS.md existence/content assertions. |
| cmd/crates/soroban-test/tests/it/init.rs | Updates integration test to verify AGENTS.md content includes build command. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Minor change Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
stellar contract init
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
AGENTS.mdin thestellar contract initworkspace template so new projects ship agent-oriented build, test, and deploy guidance.AGENTS.mdin the template README layout.stellar contract build,cargo test, andwasm32v1-none.Test plan
stellar contract init /tmp/test-agentsand confirmAGENTS.mdis at the workspace rootAGENTS.mdmentionsstellar contract build,cargo test, andwasm32v1-nonecargo test -p soroban-test --test it initor the repo's usual init test target)