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

Gradle build refactoring and version upgrade (6 to 8) 🚀🚀 #130

Open
wants to merge 1 commit 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
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ Raccoon is an APK downloader for fetching apps from Google Play.
Building
--------

Raccoon is build with gradle. It is recommended to use the "launch4j" task
instead of the standard one. Version can be changed via 'gradle.properties' file.
Raccoon is build with gradle.
Project version can be changed via 'gradle.properties' file.

#### How to build on Linux/MacOS/Windows (git bash/powershell terminal):
./gradlew createExe
Expand Down
60 changes: 29 additions & 31 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,64 +1,62 @@
plugins {
id "java"
id "eclipse"
id "edu.sc.seis.launch4j" version "2.4.9"
id "edu.sc.seis.launch4j" version "3.0.6"
id "com.gradleup.shadow" version "8.3.5"
}

// Settings
sourceCompatibility = 1.7
targetCompatibility = 1.7
java {
toolchain {
languageVersion = JavaLanguageVersion.of(8)
}
}

// In this section you declare where to find the dependencies of your project
repositories {
// You can declare any Maven/Ivy/file repository here.
mavenCentral()
}

task fatJar(type: Jar) {
shadowJar {
manifest {
// version can be changed via 'gradle.properties' file
attributes 'Implementation-Version': archiveVersion, 'Main-Class': 'de.onyxbits.raccoon.Main'
}
archiveBaseName = project.name
from { configurations.compile.collect { it.isDirectory() ? it : zipTree(it) } }
exclude 'META-INF/*', 'META-INF/maven/'
with jar
}

createExe {
copyConfigurable = project.tasks.fatJar.outputs.files
outfile = 'Raccoon-' +version +'.exe'
launch4j {
outfile = 'Raccoon-' + project.version +'.exe'
mainClassName = 'de.onyxbits.raccoon.Main'
jvmOptions = [ "-Dswing.defaultlaf=com.sun.java.swing.plaf.windows.WindowsLookAndFeel", "-Djava.net.preferIPv4Stack=true" ]
jar = "lib/${project.tasks.fatJar.archiveName}"
icon= '../../icon.ico'
jreMinVersion ='1.7.0'
jarTask = project.tasks.shadowJar
icon= "${rootDir}/icon.ico"
jreMinVersion ='1.8.0'
}

// In this section you declare the dependencies for your production and test code
dependencies {
// The production code uses the SLF4J logging API at compile time
// compile 'org.slf4j:slf4j-api:1.7.7'
compile 'net.dongliu:apk-parser:2.6.10'
compile 'org.hsqldb:hsqldb:2.5.1'
compile 'org.eclipse.jetty:jetty-server:8.1.22.v20160922'
compile 'com.google.zxing:core:3.4.1'
compile 'commons-codec:commons-codec:1.15'
compile 'com.google.protobuf:protobuf-java:3.14.0'
compile 'org.apache.httpcomponents:httpclient:4.5.13'
compile 'org.apache.httpcomponents:httpcore:4.4.14'
compile 'commons-io:commons-io:2.8.0'
compile 'commons-cli:commons-cli:1.4'
compile group: 'org.bouncycastle', name: 'bctls-jdk15on', version: '1.57'
// implementation 'org.slf4j:slf4j-api:1.7.7'
implementation 'net.dongliu:apk-parser:2.6.10'
implementation 'org.hsqldb:hsqldb:2.5.1'
implementation 'org.eclipse.jetty:jetty-server:8.1.22.v20160922'
implementation 'com.google.zxing:core:3.4.1'
implementation 'commons-codec:commons-codec:1.15'
implementation 'com.google.protobuf:protobuf-java:3.14.0'
implementation 'org.apache.httpcomponents:httpclient:4.5.13'
implementation 'org.apache.httpcomponents:httpcore:4.4.14'
implementation 'commons-io:commons-io:2.8.0'
implementation 'commons-cli:commons-cli:1.4'
implementation 'org.bouncycastle:bctls-jdk15on:1.57'

// Declare the dependency for your favourite test framework you want to use in your tests.
// TestNG is also supported by the Gradle Test task. Just change the
// testCompile dependency to testCompile 'org.testng:testng:6.8.1' and add
// testimplementation dependency to testimplementation 'org.testng:testng:6.8.1' and add
// 'test.useTestNG()' to your build script.
testCompile "junit:junit:4.13.1"
testImplementation "junit:junit:4.13.1"
}

wrapper {
gradleVersion = "6.8.2"
gradleVersion = "8.11.1"
distributionType = Wrapper.DistributionType.ALL
}
}
Binary file modified gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
5 changes: 4 additions & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.8.2-all.zip
distributionSha256Sum=89d4e70e4e84e2d2dfbb63e4daa53e21b25017cc70c37e4eea31ee51fb15098a
distributionUrl=https\://services.gradle.org/distributions/gradle-8.11.1-all.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Loading