Disable Jahro in Production Builds
Jahro is a development-only tool. Shipping it in a release build adds runtime overhead, may expose debug commands and internal data to players, and increases build size.
By default, Jahro disables itself in non-development builds, so standard release builds need no extra configuration. If you want explicit control, two options are available.
How Jahro decides whether to run
Jahro evaluates three conditions at startup, in priority order:
JAHRO_DISABLEpreprocessor define — If set, Jahro is disabled unconditionally. Nothing else is checked.- Auto-disable in Release Builds — If enabled and
Debug.isDebugBuildisfalse, Jahro disables itself. - Enable Jahro setting — If neither condition above applies, this master switch determines whether Jahro runs.
Disabling Jahro
Option 1: Auto-disable (default, recommended)
"Auto-disable in Release Builds" is on by default in Tools → Jahro Settings → General Settings. Any build where Unity's Development Build checkbox is unchecked will exclude Jahro automatically.
No code changes required. Verify it worked by checking the Unity console for:
Jahro Console: Disabled in this build
Option 2: Preprocessor define
Add JAHRO_DISABLE to Player Settings → Scripting Define Symbols. Separate multiple defines with semicolons:
JAHRO_DISABLE;YOUR_OTHER_DEFINE
This overrides all other settings — Jahro is excluded regardless of build type or project settings. Use this when you want to exclude Jahro from a specific platform no matter what.
Option 3: Master switch
Tools → Jahro Settings → General Settings → Enable Jahro is the global on/off toggle. Disabling it stops Jahro in all builds, including development builds and editor play mode. Use this to temporarily remove Jahro from your workflow without uninstalling the package.
Lifecycle reference
Jahro initializes automatically. No prefab setup or manual Start() calls needed.
Initialization (before splash screen)
Jahro runs at RuntimeInitializeLoadType.BeforeSplashScreen. During this phase it:
- Loads project settings
- Evaluates the
JAHRO_DISABLEdefine and "Auto-disable in Release Builds" setting - Sets
Jahro.Enabledaccordingly - Prepares logging infrastructure
If disabled, initialization exits immediately with minimal overhead.
Runtime boot
A second initialization pass runs after engine startup. If Jahro is enabled, it:
- Initializes console storage and the UI view
- Verifies the API key and starts a Jahro session
- Injects the UI manager (window, tabs, launch button)
- Binds hotkeys (configured Launch key, Alt+1/2/3) and mobile tap activation if enabled
Shutdown
Jahro's shutdown sequence runs when:
- Your application quits
- Assemblies reload in the editor
- You call
Jahro.Release()explicitly
During shutdown, Jahro saves console state (window position, favorites, defaults), disposes the logger, destroys the UI view, and ends the session.
Gotchas
Development builds sent to testers will include Jahro. Auto-disable only triggers when Debug.isDebugBuild is false. If you ship a Unity Development Build to external testers, Jahro will be active — verify your commands and any streamed data are safe to expose.
The master switch affects editor play mode. Auto-disable doesn't apply in the editor. If you toggle "Enable Jahro" off, Jahro stops running in play mode too, not just in standalone builds.
If streaming is enabled, disabling Jahro in release builds also cuts network load. No extra steps needed. The lifecycle shutdown handles cleanup.
AI-assisted production configuration
The production agent skill teaches your AI coding assistant to configure Jahro's three-tier disable mechanism, generate CI/CD validation scripts, and set up per-platform build safety.
Tell your AI: "Set up Jahro so it's excluded from release builds" and it recommends the right approach and generates the configuration.
Related
- Jahro Settings — full reference for General Settings options
- API Reference —
Jahro.Enabled,Jahro.Release(), and programmatic control - Getting Started — initial setup and API key configuration
- Snapshots — if you're using Snapshot Streaming, understand how it interacts with session lifecycle