Skip to content

Commit 91840be

Browse files
committed
Revert "Migrate from Groovy to Kotlin"
This reverts commit b44bd20.
1 parent b44bd20 commit 91840be

File tree

4 files changed

+132
-126
lines changed

4 files changed

+132
-126
lines changed

.github/workflows/build_and_release_github.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,6 @@ jobs:
3838
run: ./gradlew clean build
3939

4040
- name: Release package
41-
run: ./gradlew publish
41+
run: ./gradlew githubRelease
4242
env:
4343
RELEASE_GRADLE_PLUGIN_TOKEN: ${{ secrets.RELEASE_GRADLE_PLUGIN_TOKEN }}

build.gradle

Lines changed: 130 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,130 @@
1+
plugins {
2+
id 'com.gradleup.shadow' version '8.3.6'
3+
id 'com.github.breadmoirai.github-release' version '2.5.2'
4+
id 'com.palantir.git-version' version '3.2.0'
5+
id 'java'
6+
id 'java-library'
7+
id 'signing'
8+
}
9+
10+
repositories {
11+
mavenCentral()
12+
}
13+
14+
dependencies {
15+
api libs.org.cryptomator.integrations.api
16+
api libs.org.slf4j.slf4j.api
17+
api libs.org.purejava.keepassxc.proxy.access
18+
testImplementation libs.org.slf4j.slf4j.simple
19+
testImplementation libs.org.junit.jupiter.junit.jupiter.api
20+
testImplementation libs.org.junit.jupiter.junit.jupiter.engine
21+
testImplementation libs.org.junit.jupiter.junit.jupiter
22+
testRuntimeOnly libs.org.junit.platform.junit.platform.launcher
23+
}
24+
25+
group = 'org.purejava'
26+
version = gitVersion() // version set by the plugin, based on the Git tag
27+
java.sourceCompatibility = JavaVersion.VERSION_17
28+
29+
def releaseGradlePluginToken = System.getenv("RELEASE_GRADLE_PLUGIN_TOKEN") ?: ''
30+
31+
java {
32+
withSourcesJar()
33+
withJavadocJar()
34+
}
35+
36+
test {
37+
useJUnitPlatform()
38+
filter {
39+
includeTestsMatching "KeePassXCAccessTest"
40+
}
41+
}
42+
43+
/*
44+
publishing {
45+
publications {
46+
mavenJava(MavenPublication) {
47+
from(components.java)
48+
pom {
49+
name = 'keepassxc-cryptomator'
50+
description = 'Plug-in for Cryptomator to store vault passwords in KeePassXC'
51+
url = 'https://github.com/purejava/keepassxc-cryptomator'
52+
licenses {
53+
license {
54+
name = 'MIT License'
55+
url = 'https://opensource.org/licenses/MIT'
56+
}
57+
}
58+
developers {
59+
developer {
60+
id = 'purejava'
61+
name = 'Ralph Plawetzki'
62+
63+
}
64+
}
65+
scm {
66+
connection = 'scm:git:git://github.com/purejava/keepassxc-cryptomator.git'
67+
developerConnection = 'scm:git:ssh://github.com/purejava/keepassxc-cryptomator.git'
68+
url = 'https://github.com/purejava/keepassxc-cryptomator/tree/main'
69+
}
70+
issueManagement {
71+
system = 'GitHub Issues'
72+
url = 'https://github.com/purejava/keepassxc-cryptomator/issues'
73+
}
74+
}
75+
}
76+
}
77+
}
78+
*/
79+
80+
tasks.named('shadowJar', com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar) {
81+
archiveClassifier.set('')
82+
}
83+
84+
tasks.named('githubRelease') {
85+
dependsOn('sourcesJar')
86+
dependsOn('javadocJar')
87+
dependsOn('signArchives')
88+
}
89+
90+
artifacts {
91+
archives tasks.named('shadowJar')
92+
archives tasks.named('sourcesJar')
93+
}
94+
95+
signing {
96+
useGpgCmd()
97+
// Sign both the sources JAR and the shadow JAR
98+
sign configurations.archives
99+
}
100+
101+
javadoc {
102+
if(JavaVersion.current().isJava9Compatible()) {
103+
options.addBooleanOption('html5', true)
104+
}
105+
}
106+
107+
githubRelease {
108+
setToken(releaseGradlePluginToken)
109+
setTagName("$project.version")
110+
setReleaseName("$project.version")
111+
setTargetCommitish('main')
112+
setDraft(true)
113+
setBody("[![Downloads](https://img.shields.io/github/downloads/purejava/keepassxc-cryptomator/latest/keepassxc-cryptomator-${project.version}.jar)](https://github.com/purejava/keepassxc-cryptomator/releases/latest/download/keepassxc-cryptomator-${project.version}.jar)\n" +
114+
"\n" +
115+
"- xxx")
116+
releaseAssets = fileTree(dir: "${layout.buildDirectory}/libs", includes: [
117+
"keepassxc-cryptomator-${version}.jar",
118+
"keepassxc-cryptomator-${version}.jar.asc",
119+
"keepassxc-cryptomator-${version}-sources.jar",
120+
"keepassxc-cryptomator-${version}-sources.jar.asc"
121+
]).files
122+
}
123+
124+
tasks.withType(JavaCompile) {
125+
options.encoding = 'UTF-8'
126+
}
127+
128+
tasks.withType(Javadoc) {
129+
options.encoding = 'UTF-8'
130+
}

build.gradle.kts

Lines changed: 0 additions & 124 deletions
This file was deleted.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44
* This project uses @Incubating APIs which are subject to change.
55
*/
66

7-
rootProject.name = "keepassxc-cryptomator"
7+
rootProject.name = 'keepassxc-cryptomator'

0 commit comments

Comments
 (0)