Commit Graph

9 Commits

Author SHA1 Message Date
Florian BRUNIAUX ac0de43f2d ci: fix fetch-depth and doc review false positives
- fetch-depth 50 -> 0 to handle PRs with many commits
- doc review prompt: add Rust #[cfg(test)] exemption to avoid
  flagging test-only changes as missing documentation

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: Florian BRUNIAUX <florian@bruniaux.com>
2026-03-31 14:14:01 +02:00
Florian BRUNIAUX e57967ddc6 ci: enforce security patterns on new code
Add check-security-patterns.sh + CI job that hard-fails if any PR
introduces new shell execution (Command::new("sh"/"bash"/"cmd")) or
unsafe {} blocks in Rust source.

Scans only added lines via `git diff --unified=0 --diff-filter=AM` +
`grep '^+'` — never flags pre-existing code (e.g. runner.rs issue #640).

Also adds `-D unsafe_code` to the clippy job: RTK currently has zero
unsafe blocks, so this is free to enforce now.

Warn-only (non-blocking) for new .unwrap() and println! in filter code.
--self-test mode available for local verification.

Closes no issue — terrain vierge (verified: no prior PR/issue for this).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: Florian BRUNIAUX <florian@bruniaux.com>
2026-03-31 14:04:14 +02:00
Florian BRUNIAUX 13e37bf7a8 ci: enforce test presence on new/modified filter modules
Add check-test-presence.sh script and CI job that fails if any *_cmd.rs
file added or modified in a PR is missing a #[cfg(test)] block.

- New CI job runs with no dependencies (parallel to all other jobs, <10s)
- Uses --diff-filter=AM to catch both added files and test deletions
- --self-test mode for local verification
- Add missing tests to wget_cmd.rs (17 tests) and env_cmd.rs (12 tests)
  covering pure functions: compact_url, format_size, parse_error,
  extract_filename, mask_value, is_lang_var, is_cloud_var, etc.

Fixes the enforcement gap: CONTRIBUTING.md required tests but CI did not
check. Now 34/34 *_cmd.rs modules have #[cfg(test)].

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: Florian BRUNIAUX <florian@bruniaux.com>
2026-03-31 12:02:53 +02:00
aesoft da999c8364 Update ci.yml 2026-03-21 17:16:33 +01:00
aesoft 191ea9af9f fix(cicd-docs): some logs to understand what is happening when check docs 2026-03-13 15:35:26 +01:00
aesoft c6b7db2e5a fix: failing context for doc analyze -> cat from files 2026-03-13 15:29:02 +01:00
aesoft de710f4ea3 fix(cicd-docs): add agent reviewer + some contribute guidelines 2026-03-13 15:08:24 +01:00
aesoft 5da5db222d fix(cicd): clippy - do not treat warn as error 2026-03-13 13:29:54 +01:00
aesoft 6303e9530a fix(cicd): Clean cicd, rework depends and add pre-release
- Cleaned all files for a more reusable cicd
- Added pre-release on develop
- Added jobs dependencies to gain time (avoid running all if mandatory fail)
- Add CICD.md documentation
2026-03-13 13:24:46 +01:00