Skip to content

Latest commit

 

History

History
188 lines (126 loc) · 4.45 KB

File metadata and controls

188 lines (126 loc) · 4.45 KB

Contributing to Fantasy RPG World

Thank you for your interest in contributing! This document explains our development process.

Code of Conduct

  • Be respectful and inclusive
  • Focus on constructive feedback
  • Assume good intent

Local Setup

Git Configuration

Configure git to work correctly with this repository's line ending settings:

# Let .gitattributes handle all line ending conversions
git config --local core.autocrlf false

# Verify configuration
git config core.autocrlf  # Should output: false

Why this matters:

  • The repository uses .gitattributes to enforce LF line endings for all text files
  • Setting core.autocrlf = false prevents git from converting line endings automatically
  • This eliminates CRLF warnings and ensures consistent line endings across platforms

Verification

After configuring git, verify your setup:

# Build should succeed with zero warnings
dotnet build --warnaserror

# All tests should pass
dotnet test

# No line ending warnings when committing
git add <file> && git status

Development Workflow

Issue-Driven Development

Every contribution requires a GitHub issue.

  1. Check for existing issues before starting
  2. Create an issue if none exists
  3. Reference the issue in all commits and PRs

Branch Strategy

main (protected)
  └── feature/42-description (your work)
        └── PR → main

Never commit directly to main.

Branch Naming

feature/<issue-number>-<short-description>
fix/<issue-number>-<short-description>
docs/<issue-number>-<short-description>

Pull Request Process

Before Opening

  1. Ensure all tests pass
  2. Build with zero warnings
  3. Update documentation if needed
  4. Rebase on latest main

PR Requirements

  • Clear description of changes
  • Reference to GitHub issue (Closes #42)
  • Appropriate labels
  • Tests for new functionality

Review Process

PRs are reviewed using a multi-persona approach:

Persona Reviews
Fantasy Author Narrative content, lore consistency
Casual Game Expert UX, mobile patterns, accessibility
.NET Specialist Code quality, architecture, performance
Tech Lead Final approval, issue follow-up

Roles

Role Actions
Contributor Write code, open PRs from feature branches
Maintainer Review PRs, enable auto-merge, manage issues
Owner Architecture decisions, repository configuration

For AI Agents: Configure your GitHub accounts in CLAUDE.local.md.

Coding Standards

C# Style

  • Use modern C# 14 features appropriately
  • File-scoped namespaces
  • Primary constructors where suitable
  • Collection expressions
  • Pattern matching

Quality Requirements

  • Zero compiler warnings
  • 80% test coverage minimum
  • XML documentation on public APIs
  • No TODO comments in merged code

Commit Messages

<type>(<scope>): <description>

<body>

Refs #<issue-number>

Types: feat, fix, docs, refactor, test, chore, style, perf, ci, build, revert

Enforcement: Commit messages are validated by commitlint on commit.

Testing

Test-Driven Development

  1. Write failing test first
  2. Implement to pass
  3. Refactor

Test Categories

Category Purpose Speed
Unit Isolated logic Fast
Integration System interactions Medium
Acceptance User scenarios Slow

For AI Agents

If you're an AI agent contributing:

  1. Complete onboarding in CLAUDE.md
  2. Follow rules in AGENTS.md
  3. Use appropriate persona from docs/roles/
  4. Invoke skills as documented

Required Skills

  • /brainstorming - Before creative work
  • /writing-plans - For multi-step tasks
  • /test-driven-development - For implementations
  • /verification-before-completion - Before claiming done

Getting Help

  • Workflow questions: See AGENTS.md
  • Technical questions: Open a discussion
  • Bug reports: Open an issue with reproduction steps

Recognition

Contributors are recognized in:

  • PR merge messages
  • Release notes
  • Project documentation

Thank you for contributing!