Enhancement: add a `junit` input to the GitHub Action

Abierto
#715 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
74/100
Tipo de issue
Nueva funcionalidad
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
github-actions, typescript
Área
ci-cd, cli

Línea de trabajo

Start with action.yml and the action implementation, then read the baseline path validation and summary-out help probe; the issue names src/reporting/commands/scan.ts as the existing --junit entry point. Check the test/action-*.ts contract tests. Done when the optional input adds --junit only when set, rejects unsafe or conflicting paths, handles older CLI versions with a notice, and leaves default runs unchanged.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

enhancement good first issue
  • Difficulty: small
  • Area: GitHub Action
Problem

vg scan already has --junit <file> (src/reporting/commands/scan.ts, around line 406). The composite action in action.yml maps max-score, fail-on-epss, baseline, and max-worsening to flags, but has no first-class junit input. Callers must stuff --junit … into args, which is easier to get wrong and is not documented next to the other gates.

Expected behaviour

Add an optional junit input (repo-relative output path). When it is set, pass --junit <path> to scan, after the same kind of path check used for baseline (inside the repository, not absolute, not ..). Do not default it (empty means no JUnit file). output / --out and junit must remain different files; if they resolve to the same path, fail the step with the same message the CLI already uses. Probe scan --help for --junit the way summary-out is probed, so an older image-tag gets a notice instead of a hard failure on an unknown flag.

Acceptance
  • action.yml documents the input and that it maps to --junit.
  • A unit/contract test in the test/action-*.ts style asserts the flag is added only when the input is set, is omitted when empty, and is rejected when it equals output.
  • Default runs (no junit input) are unchanged.

Lenguaje dominante
TypeScript
Estrellas
4
Forks
3
Merge medio
1 d 22 h
PR fusionados (30 d)
76

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de vibgrate/cli

Todos los issues de vibgrate/cli

Issues similares

Más issues de TypeScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.