/Shared-CI-Action-Android

Shared actions used in GitHub actions.

MIT LicenseMIT

Shared-CI-Action-Android

Shared actions used by Kroger's GitHub actions.

Actions

  • Build
    • Uses gradle/gradle-build-action and calls assemble
    • Inputs:
      • Java Version - 17 is recommended
  • Code Coverage
    • Runs kover-report with the specified inputs.
    • Inputs:
      • Coverage Counter Type - Report counter type used to calculate coverage metrics. Possible values are: INSTRUCTION, LINE or BRANCH.
      • Gradle Command - The gradle command to execute to generate the code coverage report
      • Java Distribution - The distribution of Java to use
      • Java Version - 17 is recommended
      • Min Coverage Changed Files - The minimum code coverage that is required to pass for changed files
      • Min Coverage Overall - The minimum code coverage that is required to pass for overall project
      • Path - Path to the generated code coverage file
      • Title - Title for the pull request comment
      • Token - Github token to use when adding commits to the pull request
      • Update Comment - Update the coverage report comment instead of creating a new one. Requires title to be set.
  • Code Lint
    • Runs ktlint with the specified version.
    • Inputs:
      • ktlint version, e.g. 0.46.1
      • Java Version - 17 is recommended
  • Commit Lint
    • Runs commitlint against commits to ensure they meet requirements and to protect the Determine Version and Release steps.
    • Inputs:
      • NodeJS Version - 20 is recommended
      • Commitlint Version - 17+ is recommended
  • Determine Version
    • Uses Semantic Release to determine if the new commits should trigger a release.
    • Inputs:
      • NodeJS Version - 20 is recommended
      • Semantic Release Version - 21+ recommended
      • Conventional Changelog Version - 5+ recommended
  • Gradle Task
    • Uses gradle/gradle-build-action and calls the Gradle Command input.
    • Inputs:
      • Gradle Command - The gradle task to execute
      • Java Distribution - The distribution of Java to use
      • Java Version - 17 is recommended
      • Setup Android SDK - Whether or not to run android-actions/setup-android before executing the Gradle Command task.
  • Instrumented Tests
    • Runs Instrumented tests for an Android project.
    • Inputs:
      • Java Version - 17 is recommended
      • API Level - The Android API level of the emulator to use
      • Instrumented Test Script - Script to run to execute instrumented tests, e.g. ./gradlew connectedCheck
  • Problem Matchers
    • Adds Problem Matchers which highlight build errors and warnings in the job log and create annotations for them.
  • Publish
    • Runs gradle publish for your project.
    • Inputs:
      • Java Version - 17 is recommended
  • Release
    • Uses Semantic Release to create a release/tag on github of the version calculated using prior releases and new commits.
    • Inputs:
      • NodeJS Version - 20 is recommended
      • Semantic Release Version - 21+ recommended
      • Conventional Changelog Version - 5+ recommended
  • Unit Tests
    • Uses gradle/gradle-build-action and calls the Test Command input. Test results are published using mikepenz/action-junit-report.
    • Inputs:
      • Java Version - 17 is recommended
      • Test Command - The gradle task to run your tests, e.g. test