Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update build gradle 7.2 #40

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Copyright (c) 2007-2016 The Board of Trustees of The Leland Stanford Junior Univ
## Installation

We use [Gradle](http://gradle.org) to build Phrasal. Gradle will
install all dependencies. You need Gradle version 2.1+.
install all dependencies. You need Gradle version 7.2+.
If you are on OS X, the easiest way to get
Gradle is to install Homebrew and then to type `brew install gradle`.

Expand All @@ -31,7 +31,7 @@ usually the default shell.

### Windows

Follow the Linux instructions above. Then be sure to execute `gradle startupScripts` to generate a .bat file.
Follow the Linux instructions above. Then be sure to execute `gradle startScripts` to generate a .bat file.

## Citation

Expand All @@ -41,7 +41,7 @@ If you use Phrasal for research, then please cite the following paper:
@inproceedings{Green2014,
author = {Spence Green and Daniel Cer and Christopher D. Manning},
title = {Phrasal: A Toolkit for New Directions in Statistical Machine Translation},
booktitle = {In Proceddings of the Ninth Workshop on Statistical Machine Translation},
booktitle = {In Proceedings of the Ninth Workshop on Statistical Machine Translation},
year = {2014}
}
```
Expand Down
62 changes: 33 additions & 29 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'application'
apply plugin: 'idea'
apply plugin: 'maven-publish'

// Gradle java plugin
sourceCompatibility = 1.8
Expand All @@ -22,16 +23,18 @@ applicationDefaultJvmArgs = ["-ea", "-server", "-XX:+UseParallelGC", "-XX:+UsePa
jar {
manifest {
attributes 'Implementation-Title': 'Stanford Phrasal',
'Implementation-Version': version,
'Implementation-Version': archiveVersion.get(),
'Main-Class': 'edu.stanford.nlp.mt.Phrasal'
}
}

uploadArchives {
repositories {
flatDir {
dirs 'repos'
}
publishing {
publications {
maven(MavenPublication) {
groupId = 'edu.stanford.nlp'
artifactId = 'Stanford Phrasal'
version = '3.6.0'
}
}
}

Expand Down Expand Up @@ -93,41 +96,43 @@ repositories {
mavenCentral()
}

task listDeps << {
configurations.compile.each { File file -> println file.name }
task listDeps {
doLast {
configurations.implementation.api.each { File file -> println file.name }
}
}

task copyDeps(type: Copy) {
from configurations.runtime
from configurations.runtimeClasspath
into 'lib'
}

dependencies {
// TERp jars that are no longer available on the web.
compile fileTree(dir: 'lib', include: '*.jar')
implementation fileTree(dir: 'lib', include: '*.jar')

// lilt/core Maven dependencies
compile group: 'edu.stanford.nlp', name: 'stanford-corenlp', version: '3.6.0'
compile group: 'com.esotericsoftware', name: 'kryo', version: '3.0.1'
compile group: 'it.unimi.dsi', name: 'fastutil', version: '7.0.12'
compile group: 'com.google.guava', name: 'guava', version: '19.0'
compile group: 'org.apache.logging.log4j', name: 'log4j-api', version: '2.7'
compile group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.7'
compile group: 'com.lmax', name: 'disruptor', version: '3.3.6'
implementation group: 'edu.stanford.nlp', name: 'stanford-corenlp', version: '3.6.0'
implementation group: 'com.esotericsoftware', name: 'kryo', version: '3.0.1'
implementation group: 'it.unimi.dsi', name: 'fastutil', version: '7.0.12'
implementation group: 'com.google.guava', name: 'guava', version: '19.0'
implementation group: 'org.apache.logging.log4j', name: 'log4j-api', version: '2.7'
implementation group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.7'
implementation group: 'com.lmax', name: 'disruptor', version: '3.3.6'

// Test dependencies
testCompile group: 'junit', name: 'junit', version: '4.12'
testImplementation group: 'junit', name: 'junit', version: '4.12'

// Extra dependencies
extraCompile sourceSets.main.output
extraCompile sourceSets.test.output
extraCompile configurations.testCompile
extraRuntime configurations.testRuntime
extraCompile group: 'com.google.code.gson', name: 'gson', version: '2.6.2'
extraCompile group: 'org.eclipse.jetty', name: 'jetty-continuation', version: '9.2.1.v20140609'
extraCompile group: 'org.eclipse.jetty', name: 'jetty-server', version: '9.2.1.v20140609'
extraCompile group: 'org.eclipse.jetty', name: 'jetty-annotations', version: '9.2.1.v20140609'
extraCompile group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '9.2.1.v20140609'
extraImplementation sourceSets.main.output
extraImplementation sourceSets.test.output
extraImplementation configurations.testImplementation
extraRuntimeOnly configurations.testRuntimeOnly
extraImplementation group: 'com.google.code.gson', name: 'gson', version: '2.6.2'
extraImplementation group: 'org.eclipse.jetty', name: 'jetty-continuation', version: '9.2.1.v20140609'
extraImplementation group: 'org.eclipse.jetty', name: 'jetty-server', version: '9.2.1.v20140609'
extraImplementation group: 'org.eclipse.jetty', name: 'jetty-annotations', version: '9.2.1.v20140609'
extraImplementation group: 'org.eclipse.jetty', name: 'jetty-servlet', version: '9.2.1.v20140609'
}

// Eclipse plugin setup
Expand All @@ -148,11 +153,10 @@ eclipse {
buildscript {
repositories {
mavenCentral()
jcenter()
}
dependencies {
classpath 'org.owasp:dependency-check-gradle:1.4.2'
classpath 'com.github.ben-manes:gradle-versions-plugin:0.13.0'
classpath 'com.github.ben-manes:gradle-versions-plugin:0.11.1'
}
}
apply plugin: 'com.github.ben-manes.versions'
Expand Down