# Child config file (derive_child.aam)
# Inherits all defaults and schemas from derive_base.aam, then overrides some values.
#
# 'Entity' schema is inherited from the base. The base already supplies all three
# required fields (id, name, active), so we only need to override the ones we
# want to change. Child values always WIN over base values.
# 'Plugin' schema is defined here in the child and has its own two required fields
# that MUST also be present before @derive completes successfully.
# ── Plugin schema (child-only, all fields must be present before @derive) ─────
@schema Plugin {
    plugin_name: string
    enabled: bool
}

plugin_name = ChildPlugin
enabled = true

plugin = { plugin_name = ChildPlugin, enabled = true }
entity = { id = 42, name = ChildApp, active = false }

# ── Override shared config values ─────────────────────────────────────────────
log_level = debug
theme = dark

# ── Child-specific keys ───────────────────────────────────────────────────────
author = Alice
version = 2.0

# ── Pull in the base (schemas + remaining keys are merged; child wins) ─────────
@derive derive_base.aam
