How to get a hold of the hostname from inventory file?

that would be the special var inventory_hostname