Created
June 11, 2017 11:44
-
-
Save outofcoffee/a5ec8af7e1a4f79fea7abd4a604449d0 to your computer and use it in GitHub Desktop.
Load project version from properties file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def projectVersion = new File("${project.rootDir}/version.properties").withInputStream { is -> | |
new Properties().with { load((InputStream) is); delegate } | |
}['version'] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment