简体   繁体   中英

Config.groovy in grails

In Config.groovy file we are assigning the value of appName to grails.project.groupId

grails.project.groupId = appName

My question is from where we are getting the value for appName.

Thanks in advance.

要在您包含在grails.config.locations中的配置文件中获取appName,可以使用-

appName = grails.util.Metadata.current.'app.name'

You should use: grailsApplication.config.my.property

You would have access to all properties defined in config File.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM