Compare commits

..

1 Commits

Author SHA1 Message Date
e098baebee fix: initial status loading issues.
Some checks failed
Check PR code / Lint (pull_request) Successful in 3m5s
Check PR code / translations (pull_request) Successful in 1m42s
Check PR code / build (pull_request) Has been cancelled
2025-03-11 22:02:01 +01:00
2 changed files with 6 additions and 32 deletions

View File

@@ -10,44 +10,30 @@ jobs:
uses: actions/checkout@v4 uses: actions/checkout@v4
with: with:
fetch-depth: 0 fetch-depth: 0
- name: "Check android app changes"
id: check-android-changes
uses: tj-actions/changed-files@v45
with:
files: |
androidApp/src/**
- name: Fetch tags - name: Fetch tags
if: steps.check-android-changes.outputs.any_modified == 'true'
run: git fetch --tags -p run: git fetch --tags -p
- uses: actions/setup-java@v4 - uses: actions/setup-java@v4
if: steps.check-android-changes.outputs.any_modified == 'true'
with: with:
distribution: 'temurin' distribution: 'temurin'
java-version: '17' java-version: '17'
cache: gradle cache: gradle
- uses: gradle/actions/setup-gradle@v3 - uses: gradle/actions/setup-gradle@v3
if: steps.check-android-changes.outputs.any_modified == 'true'
- uses: android-actions/setup-android@v3 - uses: android-actions/setup-android@v3
if: steps.check-android-changes.outputs.any_modified == 'true'
- name: Configure gradle... - name: Configure gradle...
if: steps.check-android-changes.outputs.any_modified == 'true'
run: mkdir -p ~/.gradle && echo "org.gradle.daemon=false\nignoreGitVersion=true" >> ~/.gradle/gradle.properties run: mkdir -p ~/.gradle && echo "org.gradle.daemon=false\nignoreGitVersion=true" >> ~/.gradle/gradle.properties
- name: Build and test - name: Build and test
if: steps.check-android-changes.outputs.any_modified == 'true'
run: ./gradlew build -x testReleaseUnitTest -x testDebugUnitTest -x testGithubConfigReleaseUnitTest -x testGithubConfigDebugUnitTest # These tests will be done run: ./gradlew build -x testReleaseUnitTest -x testDebugUnitTest -x testGithubConfigReleaseUnitTest -x testGithubConfigDebugUnitTest # These tests will be done
# TESTS ARE RUN LOCALLY - uses: KengoTODA/actions-setup-docker-compose@v1
# - uses: KengoTODA/actions-setup-docker-compose@v1 with:
# with: version: "2.23.3"
# version: "2.23.3" # TESTS ARE RUN LOCALLY
# - name: run selfoss # - name: run selfoss
# run: | # run: |
# docker compose -f .gitea/workflows/assets/docker-compose.yml up -d # docker compose -f .gitea/workflows/assets/docker-compose.yml up -d
- name: coverage - name: coverage
if: steps.check-android-changes.outputs.any_modified == 'true'
run: | run: |
./gradlew :koverHtmlReport ./gradlew :koverHtmlReport
- uses: actions/upload-artifact@v3 - uses: actions/upload-artifact@v3
if: steps.check-android-changes.outputs.any_modified == 'true'
with: with:
name: coverage name: coverage
path: build/reports/kover/html path: build/reports/kover/html

View File

@@ -29,16 +29,7 @@ jobs:
steps: steps:
- name: Check out repository code - name: Check out repository code
uses: actions/checkout@v4 uses: actions/checkout@v4
with:
fetch-depth: 0
- name: "Check translations changes"
id: check-translations-changes
uses: tj-actions/changed-files@v45
with:
files: |
androidApp/src/main/res/values/strings.xml
- name: upload translation sources - name: upload translation sources
if: steps.check-api-changes.outputs.any_modified == 'true'
uses: crowdin/github-action@v2 uses: crowdin/github-action@v2
with: with:
config: './.gitea/workflows/assets/crowdin.yml' config: './.gitea/workflows/assets/crowdin.yml'
@@ -51,10 +42,8 @@ jobs:
CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }} CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }}
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }} CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }}
- name: wait - name: wait
if: steps.check-api-changes.outputs.any_modified == 'true'
run: sleep 10s run: sleep 10s
- name: download translations - name: download translations
if: steps.check-api-changes.outputs.any_modified == 'true'
uses: crowdin/github-action@v2 uses: crowdin/github-action@v2
with: with:
config: './.gitea/workflows/assets/crowdin.yml' config: './.gitea/workflows/assets/crowdin.yml'
@@ -67,18 +56,17 @@ jobs:
CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }} CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }}
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }} CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }}
- name: Check for uncommitted changes - name: Check for uncommitted changes
if: steps.check-api-changes.outputs.any_modified == 'true'
id: check-changes id: check-changes
uses: mskri/check-uncommitted-changes-action@v1.0.1 uses: mskri/check-uncommitted-changes-action@v1.0.1
- name: Commit Changes - name: Commit Changes
if: steps.check-api-changes.outputs.any_modified == 'true' && steps.check-changes.outputs.changes != '' if: steps.check-changes.outputs.changes != ''
run: | run: |
git config --global user.email aminecmi+giteadrone@pm.me git config --global user.email aminecmi+giteadrone@pm.me
git config --global user.name giteadrone git config --global user.name giteadrone
git add ./androidApp/src/main/res/* git add ./androidApp/src/main/res/*
git commit -m "translation: translation files" git commit -m "translation: translation files"
- name: Push changes - name: Push changes
if: steps.check-api-changes.outputs.any_modified == 'true' && steps.check-changes.outputs.changes != '' if: steps.check-changes.outputs.changes != ''
uses: appleboy/git-push-action@v1.0.0 uses: appleboy/git-push-action@v1.0.0
with: with:
author_name: giteadrone author_name: giteadrone