This document outlines the steps to address Issue #110, focusing on creating a comprehensive contributor onboarding guide and an automated development environment setup script.
Objective: Automate the setup of the development environment.
Steps:
- Prerequisite Checks and Installation:
- Add checks for Node.js (20+), Rust, Docker, and Stellar CLI.
- Provide instructions or automated installation for missing prerequisites where feasible (e.g.,
rustup,nvmfor Node.js). - Include a link to the Freighter extension for manual installation.
- Clone and Setup Services:
- Ensure the script can clone necessary repositories (if applicable, based on project structure).
- Integrate
docker compose -f docker-compose.dev.yml upto start all services.
- Verify Environment:
- Add commands to run all tests (unit, integration, E2E) to confirm a successful setup.
Objective: Create a comprehensive guide for new contributors.
Steps:
- Architecture Overview:
- Summarize the three-layer architecture.
- Include diagrams (referencing existing
docs/architecture.mdor creating new ones if needed).
- Development Environment Setup:
- Provide clear instructions on how to use
setup-dev.sh. - Explain manual setup steps if
setup-dev.shcannot cover everything.
- Provide clear instructions on how to use
- Project Structure Tour:
- Describe the main directories and their contents.
- Explain the purpose of key files.
- How to Run Tests:
- Detail how to run unit, integration, and E2E tests.
- Specify commands and expected outcomes.
- PR Workflow and Code Review Expectations:
- Outline the process for submitting pull requests.
- Describe code review guidelines and expectations.
- How to Find Good First Issues:
- Guide contributors on identifying suitable entry-level tasks.
- Troubleshooting Common Issues:
- Compile a list of frequently encountered problems and their solutions.
Objective: Provide a consistent and efficient development experience for VS Code users.
Steps:
- Recommended Extensions:
- Create
.vscode/extensions.jsonto suggest relevant extensions (e.g., Rust Analyzer, Docker, ESLint, Prettier).
- Create
- Launch Configurations:
- Create
.vscode/launch.jsonwith configurations for debugging the frontend and backend services.
- Create
Objective: Enable one-command startup for all development services.
Steps:
- File Creation:
- Create
docker-compose.dev.ymlin the project root if it doesn't exist.
- Create
- Service Definitions:
- Define all necessary services for local development (e.g., database, backend, frontend, Stellar testnet).
- Ensure proper port mappings, volume mounts, and environment variables.
Objective: Ensure all acceptance criteria are met.
Steps:
- Run
bash scripts/setup-dev.shand confirm it sets up the full dev environment without errors. - Review
CONTRIBUTOR_GUIDE.mdto ensure all specified sections are covered comprehensively. - Run
docker compose -f docker-compose.dev.yml upand verify all services start correctly. - Open the project in VS Code and confirm recommended extensions are suggested and launch configurations are available and functional for debugging.
- Prioritize using existing documentation (
CONTRIBUTING.md,docs/architecture.md) and scripts as a base. - Ensure all instructions are clear, concise, and easy to follow for a new contributor.
- Use relative paths where appropriate within the documentation.
- Consider adding a section on code style and linting if not already covered elsewhere.