From 95b1a2355bd0e526ad2fd62da9fd386ad4c98474 Mon Sep 17 00:00:00 2001 From: Valentin Kiselev Date: Thu, 13 Jul 2023 12:23:52 +0300 Subject: [PATCH] feat: add files option (#185) --- README.md | 1 + action.yml | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/README.md b/README.md index 36a984fa..6f06cb93 100644 --- a/README.md +++ b/README.md @@ -16,6 +16,7 @@ The action's step needs to run after your test suite has outputted an LCOV file. | --------------------- | ----------- | ----------- | | `github-token` | _required_ | Default if not specified: `${{ github.token }}`. Can be also specified this way: `github-token: ${{ secrets.GITHUB_TOKEN }}`; Coveralls uses this token to verify the appropriate repo at Coveralls and send any new status updates based on your coverage results. This variable is built into Github Actions, so __do not add it to your secrets store__. [More Info](https://help.github.com/en/actions/configuring-and-managing-workflows/authenticating-with-the-github_token)| | `file` | _optional_ | Default: all coverage files that could be found. Local path to the coverage report file produced by your test suite. An error will be thrown if no file was found. This is the file that will be sent to the Coveralls API. Leave empty if you want to combine many files reports. | +| `files` | _optional_ | Default: all coverage files that could be found. Space-separated list of coverage report files produced by your test suite. Example: `files: coverage/test1.lcov coverage/test2.lcov` | | `format` | _optional_ | Force coverage report file format. If not specified, coveralls will try to detect the format based on file extension and/or content. Possible values: `lcov`, `simplecov`, `cobertura`, `jacoco`, `gcov`, `golang`, `python`. See also [actual supported coverage report formats list](https://github.com/coverallsapp/coverage-reporter#supported-coverage-report-formats). | | `flag-name` | _optional (unique required if parallel)_ | Job flag name, e.g. "Unit", "Functional", or "Integration". Will be shown in the Coveralls UI. | | `parallel` | _optional_ | Set to true for parallel (or matrix) based steps, where multiple posts to Coveralls will be performed in the check. `flag-name` needs to be set and unique, e.g. `flag-name: run ${{ join(matrix.*, ' - ') }}` | diff --git a/action.yml b/action.yml index 088bdc67..85bb2498 100644 --- a/action.yml +++ b/action.yml @@ -13,6 +13,9 @@ inputs: file: description: 'Coverage file' required: false + files: + description: 'Space-separated list of coverage files' + required: false format: description: 'Force coverage format, supported formats: lcov, simplecov, cobertura, jacoco, gcov, golang, python' required: false @@ -135,6 +138,7 @@ runs: ${{ inputs.base-path && format('--base-path {0}', inputs.base-path) || '' }} ${{ inputs.format && format('--format {0}', inputs.format) || '' }} ${{ inputs.file || inputs.path-to-lcov }} + ${{ inputs.files }} env: COVERALLS_DEBUG: ${{ inputs.debug }} COVERALLS_CARRYFORWARD_FLAGS: ${{ inputs.carryforward }}