Game Framework
CLI ReferenceCommands

game config

View, validate, and manage Game Framework CLI configuration.

Subcommands

  • show - Display the project configuration (.game.yml)
  • validate - Validate the project configuration
  • edit - Open .game.yml in your editor

The config command has the alias cfg (e.g. game cfg show).

Usage

game config [command]

config show

Display the current project configuration from .game.yml. (This reads only the project file — it does not print your CLI auth/workspace config.)

Usage

game config show

Example Output

Name: MyGame
Version: 1.0.0

Engines:
  unity:
    Project: ../MyUnityProject
    Platforms: android, ios

config validate

Validate project configuration for correctness.

Usage

game config validate

What It Checks

  • .game.yml exists - Configuration file is present
  • Valid YAML - Properly formatted YAML syntax
  • Required fields - Name, version present
  • Engine paths - Project paths exist
  • Export paths - Export directories are valid
  • Platform settings - Platform configurations are correct

Example Output

Configuration is valid!

Validation Errors

When validation fails, the command prints a header followed by a bulleted list of the problems:

Configuration has errors:
  - Unity project path not found: ../MyUnityProject
  - Export path does not exist: ../MyUnityProject/Exports

config edit

Open the configuration file in your default editor.

Usage

game config edit

This opens .game.yml using your operating system's default handler:

  • macOS / Linux: via open
  • Windows: via start

It does not consult $EDITOR — the file opens in whatever application is registered for .yml files on your system.

Configuration Files

Project Configuration (.game.yml)

Located in your Flutter project root:

name: MyGame
version: 1.0.0

publish:
  workspace_id: "ws-abc123"
  private: false
  exclude:
    - "*.log"
    - "temp/"

engines:
  unity:
    project_path: ../MyUnityProject
    export_path: ../MyUnityProject/Exports
    
    export_settings:
      development: false
      build_configuration: Release
      scenes:
        - MainMenu
        - Gameplay
    
    platforms:
      android:
        enabled: true
        target_path: android/unityLibrary
        build_settings:
          export_project: true
          scripting_backend: IL2CPP
          target_architectures: [ARM64]
      
      ios:
        enabled: true
        target_path: ios/UnityFramework.framework
        build_settings:
          symlink_libraries: true

CLI Configuration (~/.game/config.yml)

Located in your home directory:

# Authentication
auth:
  token: "jwt_token_here"
  api_key: "api_key_here"
  expires_at: "2026-12-31T23:59:59Z"

# Default settings
defaults:
  workspace_id: "ws-abc123"

# User preferences
preferences:
  auto_export: true
  confirm_publish: true
  verbose: false

Never commit ~/.game/config.yml to version control - it contains sensitive credentials!

Configuration Options

Root Level

  • name (required) - Project name
  • version (optional) - Project version
  • publish (optional) - Publishing configuration

Engine Level

  • project_path (required) - Path to Unity/Unreal project
  • export_path (optional) - Where exports are saved
  • export_settings (optional) - Engine-specific export settings
  • platforms (required) - Platform configurations

Export Settings

  • development (optional) - Development build flag
  • build_configuration (optional) - Build configuration
  • scenes (Unity) - List of scenes to include
  • levels (Unreal) - List of levels to include
  • custom_settings (optional) - Additional settings

Platform Level

  • enabled (required) - Whether platform is enabled
  • target_path (optional) - Where to copy files in Flutter project
  • build_settings (optional) - Platform-specific build settings

Examples

Initialize New Config

# Create default .game.yml
game init

# View it
game config show

# Validate it
game config validate

Edit Config

# Open in editor
game config edit

# Or edit manually
vim .game.yml
nano .game.yml

Check Before Operations

# Validate before export
game config validate
game export unity --platform android

# Validate before publish
game config validate
game publish

Troubleshooting

Config Not Found

Error: No .game.yml found

Solution: Run game init to create one

Invalid YAML

Error: Failed to parse .game.yml

Solutions:

  • Check YAML syntax
  • Verify indentation (use spaces, not tabs)
  • Use game config validate for details

Path Not Found

Error: Unity project path not found

Solutions:

  • Verify project_path in .game.yml is correct
  • Use relative paths: ../MyUnityProject
  • Check path exists: ls ../MyUnityProject

Best Practices

Version Control

Commit .game.yml:

git add .game.yml
git commit -m "Add game configuration"

Never commit CLI config:

# Add to .gitignore
echo "~/.game/" >> .gitignore

Relative Paths

Use relative paths for team collaboration:

# Good ✅
project_path: ../MyUnityProject

# Bad ❌
project_path: /Users/john/Projects/MyUnityProject

Validation

Always validate before operations:

game config validate && game export unity --all
game config validate && game publish

Use game config validate regularly to catch configuration issues early!