Thank you for your interest in contributing to the official Swift implementation of TOON!
This project uses Swift Package Manager for dependency management and build automation.
# Clone the repository
git clone https://github.com/toon-format/toon-swift.git
cd toon-swift
# Build the project
swift build
# Run tests
swift test
# Generate Xcode project (optional)
swift package generate-xcodeproj- Fork the repository and create a feature branch
- Make your changes following the coding standards below
- Add tests for any new functionality
- Ensure all tests pass and follow existing patterns
- Submit a pull request with a clear description
- Open a discussion topic about the new feature explaining the advantages or the motivation for this new feature.
- After approval create an Issue linked to the discussion topic.
- Follow the development workflow to implement the new feature.
- Open an issue reporting the bug with detailed reproduction steps.
This project requires Swift 6.0 and above.
- Follow standard Swift coding conventions
- Use meaningful variable and method names
- Keep methods focused and concise
- Add documentation comments for public APIs
- Format code consistently using the
.swift-formatconfiguration# Format code (if you have swift-format installed) swift-format format --in-place --recursive Sources/ Tests/
-
All new features must include tests using Swift Testing framework
-
Maintain test coverage at 85%+ line coverage
-
Tests should cover edge cases and spec compliance
-
Run the full test suite:
swift test # Verbose output swift test -v
Common Swift Package Manager commands you'll use:
# Build the project
swift build
# Run tests
swift test
# Run tests with verbose output
swift test -v
# Clean build artifacts
swift package clean
# Generate Xcode project
swift package generate-xcodeprojAll implementations must comply with the TOON specification.
Before submitting changes that affect encoding/decoding behavior:
- Verify against the official SPEC.md
- Add tests for the specific spec sections you're implementing
- Document any spec version requirements
- Title: Use a clear, descriptive title
- Description: Explain what changes you made and why
- Tests: Include tests for your changes
- Documentation: Update README or documentation if needed
- Commits: Use clear commit messages (Conventional Commits preferred)
Your pull request will use our standard template which guides you through the required information.
- GitHub Issues: For bug reports and feature requests
- GitHub Discussions: For questions and general discussion
- Pull Requests: For code reviews and implementation discussion
This is a collaborative project. Current maintainers:
All maintainers have equal and consensual decision-making power. For major architectural decisions, please open a discussion issue first.
By contributing, you agree that your contributions will be licensed under the MIT License.