diff --git a/spark/build.gradle b/spark/build.gradle index a7a76e3555..8dce05e05d 100644 --- a/spark/build.gradle +++ b/spark/build.gradle @@ -14,7 +14,7 @@ repositories { mavenCentral() } -tasks.register('downloadG4Files', Exec) { +tasks.register('downloadG4Files') { description = 'Download remote .g4 files from GitHub' // use doLast to wait the completion of command execution @@ -27,6 +27,11 @@ tasks.register('downloadG4Files', Exec) { args '-o', 'src/main/antlr/SqlBaseParser.g4', 'https://raw.githubusercontent.com/apache/spark/master/sql/api/src/main/antlr4/org/apache/spark/sql/catalyst/parser/SqlBaseParser.g4' args '-o', 'src/main/antlr/SqlBaseLexer.g4', 'https://raw.githubusercontent.com/apache/spark/master/sql/api/src/main/antlr4/org/apache/spark/sql/catalyst/parser/SqlBaseLexer.g4' } + project.exec { + executable 'ls' + + args '-l', 'src/main/antlr/' + } } } clean.delete fileTree('src/main/antlr/') { include '*.g4' } @@ -45,8 +50,6 @@ configurations { // Make sure the downloadG4File task runs before the generateGrammarSource task generateGrammarSource.dependsOn downloadG4Files -compileJava.dependsOn generateGrammarSource - dependencies { antlr "org.antlr:antlr4:4.7.1"