k1LoW / runn

runn is a package/tool for running operations following a scenario.
https://runn.run
MIT License
417 stars 30 forks source link

Support negative label condition #935

Closed k1LoW closed 3 months ago

k1LoW commented 3 months ago

Fix https://github.com/k1LoW/runn/issues/934

Support following

runn run path/to/**/*.yml --label '!foo'
runn run path/to/**/*.yml --label '!foo and !bar'
github-actions[bot] commented 3 months ago

BenchmarkManyRunbooks-4

main (-) #935 (31a449b) +/-
Number of iterations 1 1 0
Nanoseconds per iteration 3,756,213,697 ns/op 3,717,462,187 ns/op -38,751,510 ns/op
Bytes allocated per iteration 1,792,984,960 B/op 1,792,859,880 B/op -125,080 B/op
Allocs per iteration 21,406,412 allocs/op 21,406,372 allocs/op -40 allocs/op
Metadata | | [main](https://github.com/k1LoW/runn/tree/main) (-) | [#935](https://github.com/k1LoW/runn/pull/935) ([31a449b](https://github.com/k1LoW/runn/commit/31a449b9d26d7f702ebd20327d95f29f89c2a553)) | |------------|----------------------------------------------------:|------------------------------------------------------------------------------------------------------------------------------------------:| | **goos** | linux | linux | | **goarch** | amd64 | amd64 | | **pkg** | github.com/k1LoW/runn | github.com/k1LoW/runn | | **cpu** | AMD EPYC 7763 64-Core Processor | AMD EPYC 7763 64-Core Processor |

BenchmarkOpenAPI3-4

main (-) #935 (31a449b) +/-
Number of iterations 1 1 0
Nanoseconds per iteration 5,279,865,273 ns/op 5,168,381,684 ns/op -111,483,589 ns/op
Bytes allocated per iteration 2,952,416,592 B/op 2,952,413,544 B/op -3,048 B/op
Allocs per iteration 29,382,363 allocs/op 29,381,900 allocs/op -463 allocs/op
Metadata | | [main](https://github.com/k1LoW/runn/tree/main) (-) | [#935](https://github.com/k1LoW/runn/pull/935) ([31a449b](https://github.com/k1LoW/runn/commit/31a449b9d26d7f702ebd20327d95f29f89c2a553)) | |------------|----------------------------------------------------:|------------------------------------------------------------------------------------------------------------------------------------------:| | **goos** | linux | linux | | **goarch** | amd64 | amd64 | | **pkg** | github.com/k1LoW/runn | github.com/k1LoW/runn | | **cpu** | AMD EPYC 7763 64-Core Processor | AMD EPYC 7763 64-Core Processor |

BenchmarkSingleRunbook-4

main (-) #935 (31a449b) +/-
Number of iterations 16 19 3
Nanoseconds per iteration 63,788,774 ns/op 63,930,330 ns/op 141,556 ns/op
Bytes allocated per iteration 60,298,077 B/op 60,283,485 B/op -14,592 B/op
Allocs per iteration 205,770 allocs/op 205,767 allocs/op -3 allocs/op
Metadata | | [main](https://github.com/k1LoW/runn/tree/main) (-) | [#935](https://github.com/k1LoW/runn/pull/935) ([31a449b](https://github.com/k1LoW/runn/commit/31a449b9d26d7f702ebd20327d95f29f89c2a553)) | |------------|----------------------------------------------------:|------------------------------------------------------------------------------------------------------------------------------------------:| | **goos** | linux | linux | | **goarch** | amd64 | amd64 | | **pkg** | github.com/k1LoW/runn | github.com/k1LoW/runn | | **cpu** | AMD EPYC 7763 64-Core Processor | AMD EPYC 7763 64-Core Processor |

Reported by octocov

github-actions[bot] commented 3 months ago

Code Metrics Report

main (72dec4c) #935 (31a449b) +/-
Coverage 64.1% 64.1% +0.0%
Code to Test Ratio 1:0.5 1:0.5 -0.0
Test Execution Time 6m2s 5m24s -38s
Details ``` diff | | main (72dec4c) | #935 (31a449b) | +/- | |---------------------|----------------|----------------|-------| + | Coverage | 64.1% | 64.1% | +0.0% | | Files | 75 | 75 | 0 | | Lines | 8188 | 8190 | +2 | + | Covered | 5249 | 5252 | +3 | - | Code to Test Ratio | 1:0.5 | 1:0.5 | -0.0 | | Code | 23562 | 23565 | +3 | | Test | 11191 | 11191 | 0 | + | Test Execution Time | 6m2s | 5m24s | -38s | ```

Code coverage of files in pull request scope (79.9% → 79.9%)

Files Coverage +/-
operator.go 79.9% +0.0%

Reported by octocov