Thursday, December 19, 2013

Grails getting the current environment name

Suppose you have created your own custom environment ,for example, purposes of deployment.
You may at times need to get the value of the environment. To do so

import grails.util.Environment

println Environment.current.name