Skip to content
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 .github/workflows/assemble.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: Set up JDK 17
- name: Set up JDK 21
uses: actions/setup-java@03ad4de0992f5dab5e18fcb136590ce7c4a0ac95 # v5.6.0
with:
distribution: "temurin"
java-version: 17
java-version: 21
- uses: gradle/actions/wrapper-validation@3f131e8634966bd73d06cc69884922b02e6faf92 # v6.2.0
- name: Setup JVM options
run: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,11 @@ jobs:
task: [ detekt, spotlessKotlinCheck, lint ]
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: Set up JDK 17
- name: Set up JDK 21
uses: actions/setup-java@03ad4de0992f5dab5e18fcb136590ce7c4a0ac95 # v5.6.0
with:
distribution: "temurin"
java-version: 17
java-version: 21
- name: Setup JVM options
run: |
mkdir -p "$HOME/.gradle"
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/garm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,11 @@ jobs:
docker exec --user www-data server /tmp/configNC.sh ${{ matrix.server }}
docker exec server /usr/local/bin/run.sh

- name: set up JDK 17
- name: set up JDK 21
uses: actions/setup-java@03ad4de0992f5dab5e18fcb136590ce7c4a0ac95 # v5.6.0
with:
distribution: "temurin"
java-version: 17
java-version: 21

- name: Enable KVM group perms
run: |
Expand Down
4 changes: 2 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,11 @@ subprojects {
}
}

task clean(type: Delete) {
tasks.register('clean', Delete) {
delete rootProject.buildDir
}

task installGitHooks(type: Copy, group: "development") {
tasks.register('installGitHooks', Copy) {
def sourceFolder = "${rootProject.projectDir}/scripts/hooks"
def destFolder = "${rootProject.projectDir}/.git/hooks"

Expand Down
13 changes: 5 additions & 8 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,16 @@ android.nonTransitiveRClass=false
android.nonFinalResIds=false

# JVM arguments to optimize heap usage, enable heap dump on out-of-memory errors, and set the file encoding
org.gradle.jvmargs=-Xmx4g -XX:MaxMetaspaceSize=1g -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
org.gradle.jvmargs=-Xmx3g -XX:MaxMetaspaceSize=1g -Dfile.encoding=UTF-8
org.gradle.dependency.verification.console=verbose
kotlin.daemon.jvmargs=-Xmx4096m
kotlin.daemon.jvmargs=-Xmx3072m
org.gradle.caching=true
org.gradle.parallel=true
org.gradle.configureondemand=true
android.defaults.buildfeatures.resvalues=true
android.sdk.defaultTargetSdkToCompileSdkIfUnset=false
android.enableAppCompileTimeRClass=false
android.usesSdkInManifest.disallowed=false
android.uniquePackageNames=false
android.dependency.useConstraints=true
android.r8.strictFullModeForKeepRules=false
android.r8.optimizedResourceShrinking=false
android.builtInKotlin=false
android.newDsl=false

# Enabled parallel sync for Gradle 9.4+
org.gradle.tooling.parallel=true
2 changes: 1 addition & 1 deletion jitpack.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
# SPDX-FileCopyrightText: 2021-2023 Tobias Kaminsky <tobias@kaminsky.me>
# SPDX-License-Identifier: MIT
jdk:
- openjdk17
- openjdk21
install:
- ./gradlew :library:publishReleasePublicationToMavenLocal
19 changes: 13 additions & 6 deletions library/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ plugins {
}

apply plugin: 'com.android.library'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-parcelize'
apply plugin: 'org.jetbrains.kotlin.plugin.serialization'
apply from: "$rootProject.projectDir/jacoco.gradle"
Expand Down Expand Up @@ -159,12 +158,14 @@ android {
}

compileOptions {
sourceCompatibility JavaVersion.VERSION_17
targetCompatibility JavaVersion.VERSION_17
sourceCompatibility JavaVersion.VERSION_21
targetCompatibility JavaVersion.VERSION_21
}

kotlinOptions {
jvmTarget = '17'

kotlin {
jvmToolchain {
languageVersion.set(JavaLanguageVersion.of(21))
}
}

testOptions {
Expand All @@ -182,6 +183,12 @@ android {
}

namespace = 'com.owncloud.android.lib'

publishing {
singleVariant("release") {
withSourcesJar()
}
}
}

tasks.register("combinedTestReport", JacocoReport) {
Expand Down
6 changes: 6 additions & 0 deletions sample_client/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,12 @@ android {

testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}

compileOptions {
sourceCompatibility JavaVersion.VERSION_21
targetCompatibility JavaVersion.VERSION_21
}

namespace = 'com.owncloud.android.lib.sampleclient'
lint {
abortOnError false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,24 +116,19 @@ public void onDestroy() {


public void onClickHandler(View button) {
switch (button.getId()) {
case R.id.button_refresh:
startRefresh();
break;
case R.id.button_upload:
startUpload();
break;
case R.id.button_delete_remote:
startRemoteDeletion();
break;
case R.id.button_download:
startDownload();
break;
case R.id.button_delete_local:
startLocalDeletion();
break;
default:
Toast.makeText(this, R.string.youre_doing_it_wrong, Toast.LENGTH_SHORT).show();
int id = button.getId();
if (id == R.id.button_refresh) {
startRefresh();
} else if (id == R.id.button_upload) {
startUpload();
} else if (id == R.id.button_delete_remote) {
startRemoteDeletion();
} else if (id == R.id.button_download) {
startDownload();
} else if (id == R.id.button_delete_local) {
startLocalDeletion();
} else {
Toast.makeText(this, R.string.youre_doing_it_wrong, Toast.LENGTH_SHORT).show();
}
}

Expand Down
Loading