Gradle war file name from yml file

How can I get property value from yml file and set the value for the war file name in the Gradle script?