Skip to content

Commit fcb0311

Browse files
committed
Merge branch 'main' into tasks
2 parents 2fe63dd + 01bce4a commit fcb0311

155 files changed

Lines changed: 4190 additions & 2927 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/build-kdoc.yml

Lines changed: 28 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,39 @@
1-
name: Build KDoc
1+
name: Build and publish KDoc
22
on:
33
push:
44
branches: [main]
5+
6+
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
7+
permissions:
8+
contents: read
9+
pages: write
10+
id-token: write
11+
512
jobs:
613
build:
7-
name: Build and publish KDoc
814
runs-on: ubuntu-latest
915
steps:
10-
- uses: actions/checkout@v2
16+
- uses: actions/checkout@v4
17+
- uses: actions/setup-java@v4
1118
with:
12-
submodules: true
13-
- uses: actions/setup-java@v2
14-
with:
15-
distribution: 'temurin'
16-
java-version: 11
17-
cache: 'gradle'
18-
- uses: gradle/wrapper-validation-action@v1
19+
distribution: temurin
20+
java-version: 17
21+
- uses: gradle/actions/setup-gradle@v4
1922

2023
- name: Build KDoc
21-
run: ./gradlew dokkaHtml
22-
- name: Publish KDoc
23-
if: success()
24-
uses: crazy-max/ghaction-github-pages@v2.5.0
24+
run: ./gradlew --no-configuration-cache dokkaHtml
25+
26+
- uses: actions/upload-pages-artifact@v3
2527
with:
26-
target_branch: gh-pages
27-
build_dir: build/dokka/html
28-
env:
29-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
28+
path: lib/build/dokka/html
29+
30+
deploy:
31+
environment:
32+
name: github-pages
33+
url: ${{ steps.deployment.outputs.page_url }}
34+
runs-on: ubuntu-latest
35+
needs: build
36+
steps:
37+
- name: Deploy to GitHub Pages
38+
id: deployment
39+
uses: actions/deploy-pages@v4

.github/workflows/codeql.yml

Lines changed: 0 additions & 74 deletions
This file was deleted.
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: Dependent Issues
2+
3+
on:
4+
issues:
5+
types:
6+
- opened
7+
- edited
8+
- closed
9+
- reopened
10+
pull_request_target:
11+
types:
12+
- opened
13+
- edited
14+
- closed
15+
- reopened
16+
# Makes sure we always add status check for PRs. Useful only if
17+
# this action is required to pass before merging. Otherwise, it
18+
# can be removed.
19+
- synchronize
20+
21+
# Schedule a daily check. Useful if you reference cross-repository
22+
# issues or pull requests. Otherwise, it can be removed.
23+
schedule:
24+
- cron: '12 9 * * *'
25+
26+
permissions: write-all
27+
28+
jobs:
29+
check:
30+
runs-on: ubuntu-latest
31+
steps:
32+
- uses: z0al/dependent-issues@v1
33+
env:
34+
# (Required) The token to use to make API calls to GitHub.
35+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
36+
# (Optional) The token to use to make API calls to GitHub for remote repos.
37+
GITHUB_READ_TOKEN: ${{ secrets.DEPENDENT_ISSUES_READ_TOKEN }}
38+
39+
with:
40+
# (Optional) The label to use to mark dependent issues
41+
# label: dependent
42+
43+
# (Optional) Enable checking for dependencies in issues.
44+
# Enable by setting the value to "on". Default "off"
45+
check_issues: on
46+
47+
# (Optional) A comma-separated list of keywords. Default
48+
# "depends on, blocked by"
49+
keywords: depends on, blocked by
50+
51+
# (Optional) A custom comment body. It supports `{{ dependencies }}` token.
52+
comment: >
53+
This PR/issue depends on:
54+
55+
{{ dependencies }}

.github/workflows/test-dev.yml

Lines changed: 83 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -1,68 +1,104 @@
11
name: Development tests
22
on: push
33
jobs:
4+
compile:
5+
name: Compile and cache
6+
runs-on: ubuntu-latest
7+
steps:
8+
- uses: actions/checkout@v4
9+
- uses: actions/setup-java@v4
10+
with:
11+
distribution: temurin
12+
java-version: 21
13+
14+
# See https://community.gradle.org/github-actions/docs/setup-gradle/ for more information
15+
- uses: gradle/actions/setup-gradle@v4 # creates build cache when on main branch
16+
with:
17+
cache-encryption-key: ${{ secrets.gradle_encryption_key }}
18+
gradle-home-cache-cleanup: true # clean up unused files
19+
dependency-graph: generate-and-submit # submit Github Dependency Graph info
20+
21+
- run: ./gradlew --build-cache --configuration-cache compileDebugSources
22+
423
test:
24+
needs: compile
525
name: Tests without emulator
626
runs-on: ubuntu-latest
727
steps:
8-
- uses: actions/checkout@v2
28+
- uses: actions/checkout@v4
29+
- uses: actions/setup-java@v4
930
with:
10-
submodules: true
11-
- uses: actions/setup-java@v2
31+
distribution: temurin
32+
java-version: 21
33+
- uses: gradle/actions/setup-gradle@v4
1234
with:
13-
distribution: 'temurin'
14-
java-version: 11
15-
cache: 'gradle'
16-
- uses: gradle/wrapper-validation-action@v1
35+
cache-encryption-key: ${{ secrets.gradle_encryption_key }}
36+
cache-read-only: true
1737

18-
- name: Check
19-
run: ./gradlew check
20-
- name: Archive results
21-
uses: actions/upload-artifact@v2
22-
with:
23-
name: test-results
24-
path: |
25-
build/outputs/lint*
26-
build/reports
38+
- name: Run lint and unit tests
39+
run: ./gradlew --build-cache --configuration-cache lintDebug testDebugUnitTest
2740

2841
test_on_emulator:
42+
needs: compile
2943
name: Tests with emulator
30-
runs-on: privileged
31-
container:
32-
image: ghcr.io/bitfireat/docker-android-ci:main
33-
options: --privileged
34-
env:
35-
ANDROID_HOME: /sdk
36-
ANDROID_AVD_HOME: /root/.android/avd
44+
runs-on: ubuntu-latest
45+
strategy:
46+
matrix:
47+
api-level: [ 31 ]
3748
steps:
38-
- uses: actions/checkout@v2
49+
- uses: actions/checkout@v4
50+
- uses: actions/setup-java@v4
51+
with:
52+
distribution: temurin
53+
java-version: 21
54+
- uses: gradle/actions/setup-gradle@v4
3955
with:
40-
submodules: true
41-
- uses: gradle/wrapper-validation-action@v1
56+
cache-encryption-key: ${{ secrets.gradle_encryption_key }}
57+
cache-read-only: true
58+
59+
- name: Enable KVM group perms
60+
run: |
61+
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
62+
sudo udevadm control --reload-rules
63+
sudo udevadm trigger --name-match=kvm
4264
43-
- name: Cache APKs and gradle dependencies
44-
uses: actions/cache@v2
65+
- name: Cache AVD and APKs
66+
uses: actions/cache@v4
67+
id: avd-cache
4568
with:
46-
key: ${{ runner.os }}-1
4769
path: |
70+
~/.android/avd/*
71+
~/.android/adb*
4872
~/.apk
49-
~/.gradle/caches
50-
~/.gradle/wrapper
73+
key: avd-${{ matrix.api-level }}
5174

52-
- name: Start emulator
53-
run: start-emulator.sh
54-
- name: Install task apps
55-
run: |
56-
mkdir .apk && cd .apk
57-
wget -cq -O org.dmfs.tasks.apk https://f-droid.org/archive/org.dmfs.tasks_80800.apk && adb install org.dmfs.tasks.apk
58-
wget -cq -O org.tasks.apk https://f-droid.org/archive/org.tasks_120400.apk && adb install org.tasks.apk
59-
wget -cq -O at.techbee.jtx.apk https://f-droid.org/archive/at.techbee.jtx_100140002.apk && adb install at.techbee.jtx.apk
60-
cd ..
61-
- name: Run connected tests
62-
run: ./gradlew connectedCheck -Pandroid.testInstrumentationRunnerArguments.notAnnotation=androidx.test.filters.FlakyTest
63-
- name: Archive results
64-
uses: actions/upload-artifact@v2
75+
- name: Create AVD and generate snapshot for caching
76+
if: steps.avd-cache.outputs.cache-hit != 'true'
77+
uses: reactivecircus/android-emulator-runner@v2
6578
with:
66-
name: test-results
67-
path: |
68-
build/reports
79+
api-level: ${{ matrix.api-level }}
80+
arch: x86_64
81+
force-avd-creation: false
82+
emulator-options: -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
83+
disable-animations: false
84+
script: echo "Generated AVD snapshot for caching."
85+
86+
- name: Install task apps and run tests
87+
uses: reactivecircus/android-emulator-runner@v2
88+
env:
89+
version_at_techbee_jtx: v2.9.0
90+
version_org_tasks: 131104
91+
version_org_dmfs_tasks: 82200
92+
with:
93+
api-level: ${{ matrix.api-level }}
94+
arch: x86_64
95+
force-avd-creation: false
96+
emulator-options: -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
97+
disable-animations: true
98+
script: |
99+
mkdir .apk && cd .apk
100+
(wget -cq -O org.dmfs.tasks.apk https://f-droid.org/repo/org.dmfs.tasks_${{ env.version_org_dmfs_tasks }}.apk || wget -cq -O org.dmfs.tasks.apk https://f-droid.org/archive/org.dmfs.tasks_${{ env.version_org_dmfs_tasks }}.apk) && adb install org.dmfs.tasks.apk
101+
(wget -cq -O org.tasks.apk https://f-droid.org/repo/org.tasks_${{ env.version_org_tasks }}.apk || wget -cq -O org.tasks.apk https://f-droid.org/archive/org.tasks_${{ env.version_org_tasks }}.apk) && adb install org.tasks.apk
102+
(wget -cq -O at.techbee.jtx.apk https://github.com/TechbeeAT/jtxBoard/releases/download/${{ env.version_at_techbee_jtx }}/jtxBoard-${{ env.version_at_techbee_jtx }}.apk) && adb install at.techbee.jtx.apk
103+
cd ..
104+
./gradlew --build-cache --configuration-cache connectedCheck -Pandroid.testInstrumentationRunnerArguments.notAnnotation=androidx.test.filters.FlakyTest

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,9 @@
88
# Files for the Dalvik VM
99
*.dex
1010

11-
# Java class files
11+
# Java/Kotlin files
1212
*.class
13+
.kotlin/
1314

1415
# Generated files
1516
bin/

.idea/copyright/GPL.xml

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/copyright/profiles_settings.xml

Lines changed: 7 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

AUTHORS

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,4 @@
1-
# This is the list of significant contributors to ical4android.
2-
#
3-
# This does not necessarily list everyone who has contributed work.
4-
# To see the full list of contributors, see the revision history in
5-
# source control.
1+
You can view the list of people who have contributed to the code base in the version control history:
2+
https://github.com/bitfireAT/ical4android/graphs/contributors
63

7-
Initial contributor:
8-
9-
* Ricki Hirner (bitfire.at)
10-
11-
12-
Further contributor:
13-
14-
* Patrick Lang (techbee.at): jtx Board integration
4+
Every contribution is welcome. There are many other forms of contributing besides writing code!

0 commit comments

Comments
 (0)