Skip to content

Contributing

Thank you for your interest in contributing to ryu_ldn_nx! This guide will help you get started.

  • Bug Reports - Found an issue? Let us know!
  • Feature Requests - Have an idea? We’d love to hear it!
  • Code - Submit pull requests with fixes or features
  • Documentation - Help improve these docs
  • Testing - Test on different games and configurations
  • Docker and Docker Compose
  • Git
  • VS Code (recommended)
  1. Fork the repository

    Terminal window
    git clone --recursive https://github.com/Ethiquema/ryu_ldn_nx.git
    cd ryu_ldn_nx
  2. Build using Docker

    Terminal window
    # Build sysmodule
    docker-compose run --rm build
    # Run tests
    docker-compose run --rm test
    # Build overlay
    docker-compose run --rm overlay
ryu_ldn_nx/
├── sysmodule/ # Main sysmodule code
│ └── source/
│ ├── config/ # Configuration parsing
│ ├── network/ # Network client
│ ├── protocol/ # RyuLdn protocol
│ └── ldn/ # LDN MITM service
├── overlay/ # Tesla overlay
├── tests/ # Unit tests
└── docs/ # This documentation
  • Use C++20 features where appropriate
  • Follow existing code style
  • Use Doxygen comments for public APIs
  • Keep functions focused and small
  • Classes: PascalCase
  • Functions: PascalCase (matching Atmosphere style)
  • Variables: snake_case
  • Member variables: m_snake_case
  • Constants: UPPER_SNAKE_CASE
/**
* @brief Process incoming network data
*
* @param data Raw data buffer
* @param size Size in bytes
* @return Result Success or error code
*/
Result NetworkClient::ProcessData(const u8* data, size_t size) {
if (data == nullptr || size == 0) {
R_THROW(ResultInvalidArgument());
}
// Process the data...
R_SUCCEED();
}
Terminal window
docker-compose run --rm test

Tests use a simple assertion framework. Add tests to tests/ directory:

void test_my_feature() {
// Arrange
MyClass instance;
// Act
auto result = instance.DoSomething();
// Assert
ASSERT_TRUE(result == expected);
}
  1. Create a branch

    Terminal window
    git checkout -b feature/my-feature
  2. Make your changes

    • Write code
    • Add tests
    • Update documentation
  3. Test locally

    Terminal window
    docker-compose run --rm test
    docker-compose run --rm build
  4. Commit with sign-off

    Terminal window
    git commit -s -m "Add my feature"
  5. Push and create PR

    Terminal window
    git push origin feature/my-feature
  6. Describe your changes

    • What does this PR do?
    • How was it tested?
    • Any breaking changes?

We require a Developer Certificate of Origin (DCO) sign-off on commits. This certifies that you wrote or have the right to submit the code.

Add -s to your commit command:

Terminal window
git commit -s -m "Your commit message"

This adds a line like:

Signed-off-by: Your Name <your.email@example.com>
  • Open an issue for questions
  • Check existing issues and PRs
  • Read the Architecture guide