Publishing

A copy of the templates is a different mod. Give it its own repositories, name, database and branding, follow the GPL, and keep private data out of everything you share.

Your Own Repositories

  1. Open ExampleServer on GitHub and choose Use this template > Create a new repository. Then do the same, separately, for ExampleMod. You end up with two repositories you own.
  2. Make sure each repository has the branches you will offer, for example main and dev. Include all branches is optional: leave it off to start with only the default branch and create the others yourself, or tick it to copy the template's branches.
  3. Before the first install, change database.name in your server's config/config.example.php to a unique name of your own, for example my_npc_mod, and set the manifest's database_placeholder to the same value. Never point it at example_ai_mod or another product's database.
  4. Clone your server into its own folder, install it as in Installation, and run the smoke checks against it. Use /var/www/html/custom-mods/<id> with a hyphenated id that differs from your manifest id, for example my-npc-mod-dev at http://127.0.0.1:19000/custom-mods/my-npc-mod-dev/health.php. Give smoke.sh and pair_client.php --base-url that address.

Editing the template does not change a config/config.php that already exists. For a copy you already installed, edit only database.name in its existing private config/config.php to a new unique database, keeping its token, keys and other settings, and do not copy config.example.php over it. Then rerun install.sh to create and migrate that new database. Existing data is not transferred automatically. For a fresh checkout, follow SETUP.md, A separate copy with its own database.

Port defaults. Use this template copies the template's main branch, with its port 19000 defaults. If you set a different CUSTOM_MODS_PORT, use that port instead. Either way, pass the address explicitly when you smoke test and pair. See Ports and branches.

Template updates. A repository made with Use this template has its own independent history, so template changes will not merge in normally. Nothing updates automatically. Compare later template changes with your copy, port the ones you need by hand, and test both your server and client. Do not force a merge of unrelated histories. If you want shared history instead, clone the template and push it to a new empty repository of your own.

Licence

Both templates are licensed GPL-3.0-only. A project based on them must follow its terms, including offering source with any binaries you share.

  • Keep LICENSE and every existing notice listed in each repository's THIRD_PARTY_NOTICES.md, including LICENSES/Original-MIT.txt, ui/HERIKA-LICENSE and third_party/nlohmann/LICENSE.MIT.
  • Add your own copyright notice to the README and THIRD_PARTY_NOTICES.md.

Your Own Branding

ChangeEdit
Project and build nameExampleMod CMakeLists.txt (project and every example_mod target reference), scripts/build.ps1 and README commands
Dashboard title and iconui/tmpl/navbar.php and ui/images/question-mark.png
ColoursBlue accent variables in ui/css/chim-theme.css
DatabaseA new lowercase database.name in config/config.example.php, matching the manifest's database_placeholder
Model behaviourThe system prompt in openai_reply() in lib/llm.php

The full map is in MAKE_IT_YOURS.md.

Launcher Manifest

dwemer-mod.json sits in the repository root. Change the identity fields for your mod:

{
  "schema_version": 1,
  "id": "my-npc-mod",
  "name": "My NPC Mod",
  "description": "Short description of your mod.",
  "project_url": "https://github.com/your-account/MyNpcModServer",
  "dashboard_path": "ui/",
  "health_path": "health.php",
  "requirements": { "php": "8.2", "postgresql": true },
  "setup": {
    "config_template": "config/config.example.php",
    "config_path": "config/config.php",
    "token_placeholder": "CHANGE_ME_TOKEN",
    "database_placeholder": "my_npc_mod",
    "migrate_script": "scripts/migrate.php"
  },
  "branches": { "default": "main", "allowed": ["main", "dev"] },
  "assets": { "icon": "ui/images/icon.png", "banner": "ui/images/banner.png" }
}

The assets paths are examples: create and commit those files first, or leave assets out until they are ready. See Icon and banner.

  • id: 3-32 characters of a-z, 0-9 and single hyphens, starting with a letter. It cannot change after install; the launcher derives the folder custom-mods/<id> and the database custom_<id> (hyphens become underscores, so my-npc-mod uses custom_my_npc_mod) from it. Its dashboard is http://127.0.0.1:19000/custom-mods/my-npc-mod/ui/ on the configured CUSTOM_MODS_PORT.
  • project_url: your own public HTTPS repository. The launcher accepts only public HTTPS URLs.
  • database_placeholder: change it together with the database name in config/config.example.php.
  • branches: only the manifest on the default branch decides which branches are offered, and every listed branch must exist. Without it, only the default branch is offered.

Every copy must also keep config/config.php untracked (a repository that tracks it is rejected), keep 'CHANGE_ME_TOKEN' and the database name each exactly once as quoted strings in the template, keep scripts/migrate.php safe to repeat, and add no symbolic links or submodules.

Icon And Banner

  • Commit the image files and the assets entry together. Paths are relative to the repository root and must point to tracked .png, .jpg or .jpeg files; links, .., hidden folders and web addresses are rejected.
  • Use a square icon (shown at 26 x 26) and a wide banner of about 2:1. Keep each file under 4 MB.
  • Pictures come from the installed version, so users see new ones only after an update.
  • Both are optional. Replace the template's question-mark icon with your own.

Private Data Rules

Never commit, package or publish:

  • config/config.php, config/config.php.lock and config/.config-*.php (token, database password, API keys).
  • The client config.json and the paired example-client.json.
  • Backup folders, *.dump files and logs.

Publish the server as its Git repository, or a git archive of a commit, which contains committed files only. Ship the client executable with config.default.json, never with a config.json that holds a token. Keep public docs generic: no personal names, local paths, private endpoints or credential values.

Full reference: LAUNCHER_CUSTOM_MOD.md, MAKE_IT_YOURS.md and START_HERE.md, Packaging, licensing and private data.

Back to: Custom Mod Guide overview.