Publishing Mods - GitHub Experienced Users Guide¶
This streamlined guide is for developers already familiar with Git and GitHub who want to publish their mods to the Chivalry 2 mod registry.
Quick Start¶
- Create a GitHub repository with your mod files. The root of your mod should be the root of the repo.
 - Add a properly formatted 
mod.jsonat the root - Create a GitHub release with your mod 
.pakfile - Submit your repository URL to C2ModRegistry via an issue
 
mod.json Structure¶
💡 Use the mod.json generator for an interactive way to create your mod.json file!
Place this at your repository root:
{
  "repo_url": "https://github.com/yourusername/your-mod-repo",
  "name": "Your Mod Name",
  "description": "A short description of your mod",
  "home_page": "https://yourdocsite.com",  // Optional
  "image_url": "https://example.com/mod-image.png",  // Optional
  "mod_type": "Client",  // Client, Server, or Shared
  "authors": ["Your Name"],
  "dependencies": [
    {
      "repo_url": "https://github.com/Chiv2-Community/Unchained-Mods",
      "version": "0.1.0"  
    } // Add any other required mods as dependencies
  ],
  "tags": ["Weapon"],  // Mutator, Map, Cosmetic, Audio, Model, Weapon, Doodad, Library
  "maps": [],  // List of maps this mod provides (if any)
  "options": {
    "actor_mod": false  // Set to true if your mod affects actors
  }
}
mod_type values (PascalCase):
- Client: Client-side only
- Server: Server-side only
- Shared: Client and server components
tag options (PascalCase):
- Mutator: Gameplay modifications
- Map: Levels/maps
- Cosmetic: Visual mods
- Audio: Sound/music
- Model: 3D models
- Weapon: Weapon mods
- Doodad: Game extensions
- Library: Frameworks/libraries
Publishing a new mod¶
1. Repository Setup¶
# Initialize repo with mod files and mod.json
git init
git add .
git commit -m "Initial mod commit"
git remote add origin https://github.com/username/mod-name.git
git push -u origin main
2. Create Release¶
- Tag your release following semver: 
git tag v1.0.0 - Push tag: 
git push origin v1.0.0 - Go to GitHub releases
 - Create release from tag
 - Attach your .pak file
 - Publish release
 
3. Submit to C2ModRegistry¶
- Go to C2ModRegistry Issues
 - Create new issue with "Add Package" template
 - Submit:
{ "action": "add_package", "repo_url": "https://github.com/yourusername/your-mod-repo" } 
Publishing Updates¶
For updates:
1. Commit changes and create new tag
2. Create new GitHub release
3. Submit new issue to C2ModRegistry:
{
  "action": "add_package_release",
  "repo_url": "https://github.com/yourusername/your-mod-repo",
  "release_tag": "v1.0.1"
}
Best Practices¶
- Versioning: Follow semantic versioning (MAJOR.MINOR.PATCH)
 - Release Notes: Include detailed changelogs
 - Dependencies: Keep dependency versions updated
 - Testing: Test mods before release
 
Common Issues¶
- Invalid mod.json: Ensure proper JSON formatting and required fields
 - Missing release asset: Attach .pak file to GitHub release
 - Wrong mod_type: Choose appropriate type based on mod functionality
 - Dependency versions: Specify exact dependency versions
 
Registry API¶
The mod registry uses these actions:
- add_package: Add new mod to registry
- add_package_release: Add new version of existing mod
For advanced automation, you can create scripts to interact with the registry API via GitHub issues.
Support¶
- Discord: Join the Chivalry 2 Unchained server for help
 - Issues: Report problems on C2ModRegistry repository
 - Updates: Watch C2ModRegistry for registry format changes