thin-edge / thin-edge.io

The open edge framework for lightweight IoT devices
https://thin-edge.io
Apache License 2.0
211 stars 55 forks source link

feat(sm-plugin): filter packages output list with exclude/include pattern #2869

Closed Ruadhri17 closed 1 month ago

Ruadhri17 commented 1 month ago

Proposed changes

This PR introduce two new tedge configs: software.plugin.include and software.plugin.exclude. This allows to filter packages list output in sm-plugin using include pattern and exclude pattern. When both patterns are provided in config, include pattern takes precedence over exclude pattern.

Types of changes

Paste Link to the issue

2848

Checklist

Further comments

codecov[bot] commented 1 month ago

Codecov Report

Attention: Patch coverage is 27.65957% with 34 lines in your changes are missing coverage. Please review.

Project coverage is 78.1%. Comparing base (33e6890) to head (eb60c35). Report is 51 commits behind head on main.

:exclamation: Current head eb60c35 differs from pull request most recent head 40e1cfe

Please upload reports for the commit 40e1cfe to get more accurate results.

Additional details and impacted files | [Files](https://app.codecov.io/gh/thin-edge/thin-edge.io/pull/2869?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thin-edge) | Coverage Δ | | |---|---|---| | [crates/core/plugin\_sm/src/plugin\_manager.rs](https://app.codecov.io/gh/thin-edge/thin-edge.io/pull/2869?src=pr&el=tree&filepath=crates%2Fcore%2Fplugin_sm%2Fsrc%2Fplugin_manager.rs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thin-edge#diff-Y3JhdGVzL2NvcmUvcGx1Z2luX3NtL3NyYy9wbHVnaW5fbWFuYWdlci5ycw==) | `55.1% <100.0%> (-11.0%)` | :arrow_down: | | [.../tedge\_config/src/tedge\_config\_cli/tedge\_config.rs](https://app.codecov.io/gh/thin-edge/thin-edge.io/pull/2869?src=pr&el=tree&filepath=crates%2Fcommon%2Ftedge_config%2Fsrc%2Ftedge_config_cli%2Ftedge_config.rs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thin-edge#diff-Y3JhdGVzL2NvbW1vbi90ZWRnZV9jb25maWcvc3JjL3RlZGdlX2NvbmZpZ19jbGkvdGVkZ2VfY29uZmlnLnJz) | `76.5% <77.7%> (-0.5%)` | :arrow_down: | | [crates/core/tedge\_api/src/error.rs](https://app.codecov.io/gh/thin-edge/thin-edge.io/pull/2869?src=pr&el=tree&filepath=crates%2Fcore%2Ftedge_api%2Fsrc%2Ferror.rs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thin-edge#diff-Y3JhdGVzL2NvcmUvdGVkZ2VfYXBpL3NyYy9lcnJvci5ycw==) | `0.0% <0.0%> (ø)` | | | [crates/core/plugin\_sm/src/plugin.rs](https://app.codecov.io/gh/thin-edge/thin-edge.io/pull/2869?src=pr&el=tree&filepath=crates%2Fcore%2Fplugin_sm%2Fsrc%2Fplugin.rs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thin-edge#diff-Y3JhdGVzL2NvcmUvcGx1Z2luX3NtL3NyYy9wbHVnaW4ucnM=) | `13.3% <12.9%> (+<0.1%)` | :arrow_up: | ... and [45 files with indirect coverage changes](https://app.codecov.io/gh/thin-edge/thin-edge.io/pull/2869/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thin-edge)
github-actions[bot] commented 1 month ago

Robot Results

:white_check_mark: Passed :x: Failed :next_track_button: Skipped Total Pass % :stopwatch: Duration
435 0 3 435 100 0s
didier-wenzek commented 1 month ago

After discussion with @reubenmiller, we concluded that:

Hence: