From 01cb1777a7b6492d5cc01e70ff47875786eb483f Mon Sep 17 00:00:00 2001 From: Abdourahamane Boinaidi Date: Fri, 19 Jul 2024 09:55:41 +0200 Subject: [PATCH 1/2] Add github actions --- .github/ISSUE_TEMPLATE/bug_report.md | 36 ++++++++++++++++++++ .github/ISSUE_TEMPLATE/feature_request.md | 22 +++++++++++++ .github/workflows/android.yml | 40 +++++++++++++++++++++++ .github/workflows/auto-author-assign.yml | 14 ++++++++ .github/workflows/dependent-issues.yml | 28 ++++++++++++++++ 5 files changed, 140 insertions(+) create mode 100644 .github/ISSUE_TEMPLATE/bug_report.md create mode 100644 .github/ISSUE_TEMPLATE/feature_request.md create mode 100644 .github/workflows/android.yml create mode 100644 .github/workflows/auto-author-assign.yml create mode 100644 .github/workflows/dependent-issues.yml diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 000000000..0d70c1841 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,36 @@ +--- +name: Bug report +about: Create a report to help us improve +title: '' +labels: bug +assignees: '' + +--- + +*Note: Please write your issue only in english* + +**Description** +A clear and concise description of what the bug is. + +**Steps to reproduce** +Steps to reproduce the behavior: + +1. Go to '...' +2. Click on '....' +3. Scroll down to '....' +4. See error + +**Expected behavior** +A clear and concise description of what you expected to happen. + +**Screenshots** +If applicable, add screenshots to help explain your problem. + +**Smartphone (please complete the following information):** + +- Device: [e.g. Samsung S20 Ultra 5G] +- Android version: [e.g. Android 11] +- App version: [e.g. 4.0.1] + +**Additional context** +Add any other context about the problem here. diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md new file mode 100644 index 000000000..0d4bf2c88 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,22 @@ +--- +name: Feature request +about: Suggest an idea for this project +title: '' +labels: '' +assignees: '' + +--- + +*Note: Please write your issue only in english* + +**Is your feature request related to a problem? Please describe.** +A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] + +**Describe the solution you'd like** +A clear and concise description of what you want to happen. + +**Describe alternatives you've considered** +A clear and concise description of any alternative solutions or features you've considered. + +**Additional context** +Add any other context or screenshots about the feature request here. diff --git a/.github/workflows/android.yml b/.github/workflows/android.yml new file mode 100644 index 000000000..a0bc37711 --- /dev/null +++ b/.github/workflows/android.yml @@ -0,0 +1,40 @@ +name: Android CI + +on: + pull_request: + +concurrency: + group: ${{ github.head_ref }} + cancel-in-progress: true + +jobs: + + instrumentation-tests: + if: github.event.pull_request.draft == false + runs-on: [ self-hosted, Android ] + strategy: + matrix: + api-level: [ 34 ] + target: [ google_apis ] + + steps: + - name: Cancel Previous Runs + uses: styfle/cancel-workflow-action@0.12.1 + with: + access_token: ${{ github.token }} + + - name: Checkout the code + uses: actions/checkout@v4.1.7 + with: + token: ${{ github.token }} + submodules: recursive + + # Setup Gradle and run Build + - name: Grant execute permission for gradlew + run: chmod +x gradlew + - name: Build with Gradle + run: ./gradlew build + + # Run tests + - name: Run Unit tests + run: ./gradlew testDebugUnitTest --stacktrace diff --git a/.github/workflows/auto-author-assign.yml b/.github/workflows/auto-author-assign.yml new file mode 100644 index 000000000..847fd7431 --- /dev/null +++ b/.github/workflows/auto-author-assign.yml @@ -0,0 +1,14 @@ +name: Auto Author Assign + +on: + pull_request_target: + types: [ opened, reopened ] + +permissions: + pull-requests: write + +jobs: + assign-author: + runs-on: ubuntu-latest + steps: + - uses: toshimaru/auto-author-assign@v2.1.1 diff --git a/.github/workflows/dependent-issues.yml b/.github/workflows/dependent-issues.yml new file mode 100644 index 000000000..d081deede --- /dev/null +++ b/.github/workflows/dependent-issues.yml @@ -0,0 +1,28 @@ +name: Dependent Issues + +on: + issues: + types: + - opened + - edited + - closed + - reopened + pull_request_target: + types: + - opened + - edited + - closed + - reopened + # Makes sure we always add status check for PRs. Useful only if + # this action is required to pass before merging. Otherwise, it + # can be removed. + - synchronize + +jobs: + check: + runs-on: ubuntu-latest + steps: + - uses: z0al/dependent-issues@v1.5.2 + env: + # (Required) The token to use to make API calls to GitHub. + GITHUB_TOKEN: ${{ github.token }} From 5545f2d7cf8b3bea7d47d8443adf14f1aa92d4ca Mon Sep 17 00:00:00 2001 From: Abdourahamane Boinaidi Date: Fri, 19 Jul 2024 10:57:13 +0200 Subject: [PATCH 2/2] Update bug_report App version --- .github/ISSUE_TEMPLATE/bug_report.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index 0d70c1841..95acae26d 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -30,7 +30,7 @@ If applicable, add screenshots to help explain your problem. - Device: [e.g. Samsung S20 Ultra 5G] - Android version: [e.g. Android 11] -- App version: [e.g. 4.0.1] +- App version: [e.g. 1.0.1] **Additional context** Add any other context about the problem here.