cuke-dedup 0.2.1 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +9 -0
- package/README.md +1 -1
- package/THIRD-PARTY-LICENSES.md +11 -0
- package/docs/ci-and-baselines.md +46 -4
- package/package.json +9 -9
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,14 @@ All notable changes to CukeDedup are documented in this file. The project follow
|
|
|
5
5
|
|
|
6
6
|
## [Unreleased]
|
|
7
7
|
|
|
8
|
+
## [0.3.0] - 2026-09-14
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
|
|
12
|
+
- `--baseline-from-ref` and the matching Action input compare against a fetched Git revision
|
|
13
|
+
with the current analysis policy, reusing `--fail-on-new` without a committed baseline file.
|
|
14
|
+
Incomplete historical scans are rejected rather than treated as clean baselines.
|
|
15
|
+
|
|
8
16
|
## [0.2.1] - 2026-09-13
|
|
9
17
|
|
|
10
18
|
### Changed
|
|
@@ -151,6 +159,7 @@ Initial public release.
|
|
|
151
159
|
- Native Cargo and npm distributions for eight supported targets.
|
|
152
160
|
- A checksum-verified GitHub Action and an agent-oriented CukeDedup skill.
|
|
153
161
|
|
|
162
|
+
[0.3.0]: https://github.com/figueiredoluiz/cuke-dedup/compare/v0.2.1...v0.3.0
|
|
154
163
|
[0.2.1]: https://github.com/figueiredoluiz/cuke-dedup/compare/v0.2.0...v0.2.1
|
|
155
164
|
[0.2.0]: https://github.com/figueiredoluiz/cuke-dedup/compare/v0.1.1...v0.2.0
|
|
156
165
|
[0.1.1]: https://github.com/figueiredoluiz/cuke-dedup/compare/v0.1.0...v0.1.1
|
package/README.md
CHANGED
package/THIRD-PARTY-LICENSES.md
CHANGED
|
@@ -18,9 +18,11 @@ regenerated whenever `Cargo.lock` changes.
|
|
|
18
18
|
| anstyle-query | 1.1.5 | MIT OR Apache-2.0 | Not declared | https://github.com/rust-cli/anstyle.git |
|
|
19
19
|
| anstyle-wincon | 3.0.11 | MIT OR Apache-2.0 | Not declared | https://github.com/rust-cli/anstyle.git |
|
|
20
20
|
| anyhow | 1.0.104 | MIT OR Apache-2.0 | David Tolnay <dtolnay@gmail.com> | https://github.com/dtolnay/anyhow |
|
|
21
|
+
| bitflags | 2.13.1 | MIT OR Apache-2.0 | The Rust Project Developers | https://github.com/bitflags/bitflags |
|
|
21
22
|
| bstr | 1.13.1 | MIT OR Apache-2.0 | Andrew Gallant <jamslam@gmail.com> | https://github.com/BurntSushi/bstr |
|
|
22
23
|
| bytecount | 0.6.9 | Apache-2.0/MIT | Andre Bogus <bogusandre@gmail.de>, Joshua Landau <joshua@landau.ws> | https://github.com/llogiq/bytecount |
|
|
23
24
|
| cc | 1.4.4 | MIT OR Apache-2.0 | Not declared | https://github.com/rust-lang/cc-rs |
|
|
25
|
+
| cfg-if | 1.0.4 | MIT OR Apache-2.0 | Alex Crichton <alex@alexcrichton.com> | https://github.com/rust-lang/cfg-if |
|
|
24
26
|
| clap | 4.6.6 | MIT OR Apache-2.0 | Not declared | https://github.com/clap-rs/clap |
|
|
25
27
|
| clap_builder | 4.6.6 | MIT OR Apache-2.0 | Not declared | https://github.com/clap-rs/clap |
|
|
26
28
|
| clap_derive | 4.6.4 | MIT OR Apache-2.0 | Not declared | https://github.com/clap-rs/clap |
|
|
@@ -35,7 +37,10 @@ regenerated whenever `Cargo.lock` changes.
|
|
|
35
37
|
| derive_more-impl | 2.1.1 | MIT | Jelte Fennema <github-tech@jeltef.nl> | https://github.com/JelteF/derive_more |
|
|
36
38
|
| either | 1.18.0 | MIT OR Apache-2.0 | Not declared | https://github.com/rayon-rs/either |
|
|
37
39
|
| equivalent | 1.0.2 | Apache-2.0 OR MIT | Not declared | https://github.com/indexmap-rs/equivalent |
|
|
40
|
+
| errno | 0.3.14 | MIT OR Apache-2.0 | Chris Wong <lambda.fairy@gmail.com>, Dan Gohman <dev@sunfishcode.online> | https://github.com/lambda-fairy/rust-errno |
|
|
41
|
+
| fastrand | 2.5.0 | Apache-2.0 OR MIT | Stjepan Glavina <stjepang@gmail.com> | https://github.com/smol-rs/fastrand |
|
|
38
42
|
| find-msvc-tools | 0.1.11 | MIT OR Apache-2.0 | Not declared | https://github.com/rust-lang/cc-rs |
|
|
43
|
+
| getrandom | 0.4.3 | MIT OR Apache-2.0 | The Rand Project Developers | https://github.com/rust-random/getrandom |
|
|
39
44
|
| gherkin | 0.16.0 | MIT OR Apache-2.0 | Brendan Molloy <brendan@bbqsrc.net> | https://github.com/cucumber-rs/gherkin |
|
|
40
45
|
| globset | 0.4.20 | Unlicense OR MIT | Andrew Gallant <jamslam@gmail.com> | https://github.com/BurntSushi/ripgrep/tree/master/crates/globset |
|
|
41
46
|
| hashbrown | 0.17.1 | MIT OR Apache-2.0 | Not declared | https://github.com/rust-lang/hashbrown |
|
|
@@ -44,21 +49,26 @@ regenerated whenever `Cargo.lock` changes.
|
|
|
44
49
|
| indexmap | 2.14.1 | Apache-2.0 OR MIT | Not declared | https://github.com/indexmap-rs/indexmap |
|
|
45
50
|
| is_terminal_polyfill | 1.70.2 | MIT OR Apache-2.0 | Not declared | https://github.com/polyfill-rs/is_terminal_polyfill |
|
|
46
51
|
| itoa | 1.0.18 | MIT OR Apache-2.0 | David Tolnay <dtolnay@gmail.com> | https://github.com/dtolnay/itoa |
|
|
52
|
+
| libc | 0.2.189 | MIT OR Apache-2.0 | Not declared | https://github.com/rust-lang/libc |
|
|
47
53
|
| libyaml-rs | 0.3.0 | MIT | David Tolnay <dtolnay@gmail.com>, YAML Organization <noreply@yaml.org> | https://github.com/yaml/libyaml-rs |
|
|
54
|
+
| linux-raw-sys | 0.12.1 | Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT | Dan Gohman <dev@sunfishcode.online> | https://github.com/sunfishcode/linux-raw-sys |
|
|
48
55
|
| log | 0.4.34 | MIT OR Apache-2.0 | The Rust Project Developers | https://github.com/rust-lang/log |
|
|
49
56
|
| memchr | 2.8.3 | Unlicense OR MIT | Andrew Gallant <jamslam@gmail.com>, bluss | https://github.com/BurntSushi/memchr |
|
|
50
57
|
| nom | 8.0.0 | MIT | contact@geoffroycouprie.com | https://github.com/rust-bakery/nom |
|
|
51
58
|
| nom_locate | 5.0.0 | MIT | Florent FAYOLLE <florent.fayolle69@gmail.com>, Christopher Durham <cad97@cad97.com>, Valentin Lorentz <progval+git@progval.net> | https://github.com/fflorent/nom_locate |
|
|
59
|
+
| once_cell | 1.21.4 | MIT OR Apache-2.0 | Aleksey Kladov <aleksey.kladov@gmail.com> | https://github.com/matklad/once_cell |
|
|
52
60
|
| once_cell_polyfill | 1.70.2 | MIT OR Apache-2.0 | Not declared | https://github.com/polyfill-rs/once_cell_polyfill |
|
|
53
61
|
| peg | 0.6.3 | MIT | Kevin Mehall <km@kevinmehall.net> | https://github.com/kevinmehall/rust-peg |
|
|
54
62
|
| peg-macros | 0.6.3 | MIT | Kevin Mehall <km@kevinmehall.net> | https://github.com/kevinmehall/rust-peg |
|
|
55
63
|
| peg-runtime | 0.6.3 | MIT | Kevin Mehall <km@kevinmehall.net> | https://github.com/kevinmehall/rust-peg |
|
|
56
64
|
| proc-macro2 | 1.0.107 | MIT OR Apache-2.0 | David Tolnay <dtolnay@gmail.com>, Alex Crichton <alex@alexcrichton.com> | https://github.com/dtolnay/proc-macro2 |
|
|
57
65
|
| quote | 1.0.47 | MIT OR Apache-2.0 | David Tolnay <dtolnay@gmail.com> | https://github.com/dtolnay/quote |
|
|
66
|
+
| r-efi | 6.0.0 | MIT OR Apache-2.0 OR LGPL-2.1-or-later | Not declared | https://github.com/r-efi/r-efi |
|
|
58
67
|
| regex | 1.13.1 | MIT OR Apache-2.0 | The Rust Project Developers, Andrew Gallant <jamslam@gmail.com> | https://github.com/rust-lang/regex |
|
|
59
68
|
| regex-automata | 0.4.18 | MIT OR Apache-2.0 | The Rust Project Developers, Andrew Gallant <jamslam@gmail.com> | https://github.com/rust-lang/regex |
|
|
60
69
|
| regex-syntax | 0.8.11 | MIT OR Apache-2.0 | The Rust Project Developers, Andrew Gallant <jamslam@gmail.com> | https://github.com/rust-lang/regex |
|
|
61
70
|
| rustc_version | 0.4.1 | MIT OR Apache-2.0 | Not declared | https://github.com/djc/rustc-version-rs |
|
|
71
|
+
| rustix | 1.1.4 | Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT | Dan Gohman <dev@sunfishcode.online>, Jakub Konka <kubkon@jakubkonka.com> | https://github.com/bytecodealliance/rustix |
|
|
62
72
|
| ryu | 1.0.23 | Apache-2.0 OR BSL-1.0 | David Tolnay <dtolnay@gmail.com> | https://github.com/dtolnay/ryu |
|
|
63
73
|
| same-file | 1.0.6 | Unlicense/MIT | Andrew Gallant <jamslam@gmail.com> | https://github.com/BurntSushi/same-file |
|
|
64
74
|
| semver | 1.0.28 | MIT OR Apache-2.0 | David Tolnay <dtolnay@gmail.com> | https://github.com/dtolnay/semver |
|
|
@@ -72,6 +82,7 @@ regenerated whenever `Cargo.lock` changes.
|
|
|
72
82
|
| strsim | 0.11.1 | MIT | Danny Guo <danny@dannyguo.com>, maxbachmann <oss@maxbachmann.de> | https://github.com/rapidfuzz/strsim-rs |
|
|
73
83
|
| syn | 2.0.119 | MIT OR Apache-2.0 | David Tolnay <dtolnay@gmail.com> | https://github.com/dtolnay/syn |
|
|
74
84
|
| syn | 3.0.4 | MIT OR Apache-2.0 | David Tolnay <dtolnay@gmail.com> | https://github.com/dtolnay/syn |
|
|
85
|
+
| tempfile | 3.27.0 | MIT OR Apache-2.0 | Steven Allen <steven@stebalien.com>, The Rust Project Developers, Ashley Mannix <ashleymannix@live.com.au>, Jason White <me@jasonwhite.io> | https://github.com/Stebalien/tempfile |
|
|
75
86
|
| textwrap | 0.16.2 | MIT | Martin Geisler <martin@geisler.net> | https://github.com/mgeisler/textwrap |
|
|
76
87
|
| thiserror | 2.0.20 | MIT OR Apache-2.0 | David Tolnay <dtolnay@gmail.com> | https://github.com/dtolnay/thiserror |
|
|
77
88
|
| thiserror-impl | 2.0.20 | MIT OR Apache-2.0 | David Tolnay <dtolnay@gmail.com> | https://github.com/dtolnay/thiserror |
|
package/docs/ci-and-baselines.md
CHANGED
|
@@ -18,7 +18,7 @@ steps:
|
|
|
18
18
|
fetch-depth: 0
|
|
19
19
|
persist-credentials: false
|
|
20
20
|
|
|
21
|
-
- uses: figueiredoluiz/cuke-dedup@v0.
|
|
21
|
+
- uses: figueiredoluiz/cuke-dedup@v0.3.0
|
|
22
22
|
id: cuke-dedup
|
|
23
23
|
with:
|
|
24
24
|
path: .
|
|
@@ -95,9 +95,9 @@ cuke-dedup . --baseline .cuke-dedup-baseline.json --fail-on-new
|
|
|
95
95
|
cuke-dedup . --baseline .cuke-dedup-baseline.json --fail-on-new 3
|
|
96
96
|
```
|
|
97
97
|
|
|
98
|
-
`--fail-on-new` defaults to zero when no count is supplied
|
|
99
|
-
`--baseline` and cannot be combined
|
|
100
|
-
`fail-on-new` inputs.
|
|
98
|
+
`--fail-on-new` defaults to zero when no count is supplied and requires `--baseline` or
|
|
99
|
+
`--baseline-from-ref`. `--update-baseline` requires the file form and cannot be combined with
|
|
100
|
+
`--fail-on-new`. The Action exposes `baseline`, `baseline-from-ref`, and `fail-on-new` inputs.
|
|
101
101
|
|
|
102
102
|
Baselines store sorted semantic fingerprints with multiplicity counts. Renames and unrelated line
|
|
103
103
|
changes do not make a finding new, while an additional occurrence beyond the recorded count does.
|
|
@@ -107,6 +107,48 @@ Version `1` baselines from CukeDedup 0.1 can be replaced by running the version
|
|
|
107
107
|
Updates reject `--changed-since` and are skipped after incomplete analysis or an operational error,
|
|
108
108
|
preventing a partial scan from erasing accepted findings.
|
|
109
109
|
|
|
110
|
+
### Compare against a Git revision (next release)
|
|
111
|
+
|
|
112
|
+
Instead of committing a baseline file, compare with a revision that is already fetched locally:
|
|
113
|
+
|
|
114
|
+
```sh
|
|
115
|
+
cuke-dedup . --baseline-from-ref origin/main --fail-on-new
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
The corresponding Action inputs are:
|
|
119
|
+
|
|
120
|
+
```yaml
|
|
121
|
+
with:
|
|
122
|
+
baseline-from-ref: ${{ github.event.pull_request.base.sha }}
|
|
123
|
+
fail-on-new: "0"
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
This requires an Action/binary version containing this feature; v0.2.1 does not include it.
|
|
127
|
+
Use checkout with `fetch-depth: 0`, or explicitly fetch the desired revision before analysis.
|
|
128
|
+
The tool does not fetch revisions, initialize submodules, install dependencies, or run project code.
|
|
129
|
+
|
|
130
|
+
The base is scanned in a temporary independent Git checkout using the **current effective
|
|
131
|
+
CukeDedup configuration**, including rule overrides, patterns and suppressions. Historical
|
|
132
|
+
project module metadata and ignore files remain historical inputs. The same repository-relative
|
|
133
|
+
analysis directory must exist in both trees. Missing refs/directories, unsupported submodules,
|
|
134
|
+
base extraction errors, unresolved registrations, zero extraction from discovered sources,
|
|
135
|
+
definitions without a feature corpus, and truncated base comparisons fail with exit code `2`;
|
|
136
|
+
none become an empty accepted baseline. A genuinely empty historical suite is allowed.
|
|
137
|
+
Hooks and configured checkout filters are disabled, so Git LFS content is not hydrated.
|
|
138
|
+
The full repository snapshot is limited to 512 MiB of tracked content and 100,000 files;
|
|
139
|
+
larger repositories can use a committed baseline instead. Git submodules anywhere in that
|
|
140
|
+
snapshot are rejected because their content is not materialized.
|
|
141
|
+
|
|
142
|
+
Matching findings are suppressed using the existing semantic fingerprints and multiplicity
|
|
143
|
+
rules. Current modified/untracked files are analyzed normally. `--baseline-from-ref` conflicts
|
|
144
|
+
with `--baseline` and `--update-baseline`; it writes no baseline file or base reports and leaves
|
|
145
|
+
the current index, branch and worktree registration untouched. Temporary files are removed after
|
|
146
|
+
success or failure. This costs a second scan, not a changed-files-only optimization.
|
|
147
|
+
|
|
148
|
+
The new-finding allowance is an additional gate: it does not disable the duplication threshold
|
|
149
|
+
or independent error rules. Use `--fail-on-incomplete` if incomplete current analysis must also
|
|
150
|
+
fail instead of retaining the normal partial-report behavior.
|
|
151
|
+
|
|
110
152
|
## Exit codes
|
|
111
153
|
|
|
112
154
|
| Code | Meaning |
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cuke-dedup",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "Static analysis for duplicate and reusable Cucumber step definitions",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -47,13 +47,13 @@
|
|
|
47
47
|
"npm/platforms/*"
|
|
48
48
|
],
|
|
49
49
|
"optionalDependencies": {
|
|
50
|
-
"cuke-dedup-darwin-arm64": "0.
|
|
51
|
-
"cuke-dedup-darwin-x64": "0.
|
|
52
|
-
"cuke-dedup-linux-arm64-gnu": "0.
|
|
53
|
-
"cuke-dedup-linux-arm64-musl": "0.
|
|
54
|
-
"cuke-dedup-linux-x64-gnu": "0.
|
|
55
|
-
"cuke-dedup-linux-x64-musl": "0.
|
|
56
|
-
"cuke-dedup-windows-arm64-msvc": "0.
|
|
57
|
-
"cuke-dedup-windows-x64-msvc": "0.
|
|
50
|
+
"cuke-dedup-darwin-arm64": "0.3.0",
|
|
51
|
+
"cuke-dedup-darwin-x64": "0.3.0",
|
|
52
|
+
"cuke-dedup-linux-arm64-gnu": "0.3.0",
|
|
53
|
+
"cuke-dedup-linux-arm64-musl": "0.3.0",
|
|
54
|
+
"cuke-dedup-linux-x64-gnu": "0.3.0",
|
|
55
|
+
"cuke-dedup-linux-x64-musl": "0.3.0",
|
|
56
|
+
"cuke-dedup-windows-arm64-msvc": "0.3.0",
|
|
57
|
+
"cuke-dedup-windows-x64-msvc": "0.3.0"
|
|
58
58
|
}
|
|
59
59
|
}
|