-
Type:
Bug
-
Status: Resolved
-
Resolution: Fixed
-
Affects Version/s: 0.5.2
-
Fix Version/s: 0.6
http://gradle.org/userguide/0.5.2/userguidech10.html#x28-4700010
10.8.4 Manifest
Both examples in this section have the below incorrect line:
manifest.mainAttributes(Implementation-Title: "Gradle", Implementation-Version: $version)
This is invalid Groovy code because of the '-' in both Implementation-Title and Implementation-Version
When attempting to build, the following error occurs because it's trying to treat Implementation-Title as an expression, instead of as a String.
build_gradle: 11: illegal colon after argument expression;
solution: a complex label expression before a colon must be parenthesized @ line 11, column 34.
The below is all that's needed to correct the example, and is arguably a good practice because you are forcing it to treat the key as a string value.
manifest.mainAttributes("Implementation-Title": "Gradle", "Implementation-Version": $version)