Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- thufir@mordor:~/java$
- thufir@mordor:~/java$ cat build.gradle
- apply plugin: 'java'
- archiveBaseName = "HelloWorld"
- version = "0.5"
- task hello << {
- println 'hello, world'
- }
- jar {
- manifest {
- attributes(
- 'Class-Path': configurations.compile.collect { it.getName() }.join(' ')
- 'Main-Class': 'HelloWorld'
- )
- }
- }
- thufir@mordor:~/java$
- thufir@mordor:~/java$ gradle tasks
- FAILURE: Build failed with an exception.
- * Where:
- Build file '/home/thufir/java/build.gradle' line: 17
- * What went wrong:
- Could not compile build file '/home/thufir/java/build.gradle'.
- > startup failed:
- build file '/home/thufir/java/build.gradle': 17: unexpected token: Main-Class @ line 17, column 7.
- 'Main-Class': 'HelloWorld'
- ^
- 1 error
- * Try:
- Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
- BUILD FAILED
- Total time: 3.976 secs
- thufir@mordor:~/java$
Advertisement
Add Comment
Please, Sign In to add comment