Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: added prefix_path input that can be used to add a prefix to each filename in the cobertura report #74

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 4 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@ The GITHUB_TOKEN. Defaults to `${{github.token}}`

The path to the cobertura report. Defaults to `coverage.xml`. Glob pattern is supported, for example `coverage/*.xml`.

## `prefix_path`

This prefix is added to every `filename` within the cobertura report. This can resolve issues with `link_missing_lines` URLs and `only_changed_files`.

### `skip_covered`

If files with 100% coverage should be ignored. Defaults to `true`.
Expand Down Expand Up @@ -80,11 +84,6 @@ Default is no crop.
Link missing line numbers. This only has an effect when `show_missing` is set to `true`.
Defaults to `false`.

### `link_missing_lines_source_dir`

Allows specifying a source directory for `link_missing_lines`, that will be inserted
into the resulting URLs, in-between the commit hash and the file path.

### `only_changed_files`

Only show coverage for changed files.
Expand Down
5 changes: 5 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ inputs:
description: 'Path to the cobertura file.'
required: true
default: 'coverage.xml'
prefix_path:
description: 'Prefix path to add to each filename.'
required: false
default: ''
skip_covered:
description: 'If files with 100% should be skipped from report.'
required: true
Expand Down Expand Up @@ -48,6 +52,7 @@ inputs:
description: 'Source directory used for link_missing_lines.'
required: false
default: ''
deprecationMessage: 'Please switch to prefix_path instead (this input is forward to prefix_path).'
only_changed_files:
description: 'Only show coverage for changed files. (only if a PR is present)'
required: true
Expand Down
Loading