Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

[Feature]: Surface `--output`, `--valid-days` and `--export-cer` in `winapp cert generate`

Abierto
#243 1 comentario 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 8 días

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
55/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
typescript, vscode

Línea de trabajo

Comienza con el comando winapp.certGenerate existente y su generate QuickPick; después, revisa cómo se gestionan actualmente la configuración de la extensión y workspaceState. Revisa el cambio de transporte de cert generate que está en curso antes de añadir estas opciones, y comprueba scripts/download-cli.ps1 para conocer el contexto de la versión de CLI. Se considera terminado cuando las tres opciones de CLI están disponibles de forma predeterminada sin prompts, mediante el flujo avanzado propuesto, y sus valores persisten según lo especificado.

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

Descripción

enhancement
Is your feature request related to a problem? Please describe.

winapp.certGenerate runs cert generate (or cert generate --install) with no other arguments, so several winappcli options are unreachable from the extension:

  • --output — where the PFX is written. Users are stuck with devcert.pfx in the project directory and cannot put certificates in, say, a certs/ or build/ folder.
  • --valid-days — certificate validity period. Users are stuck with the CLI default of 365 days and cannot shorten it for a short-lived test certificate or lengthen it to avoid re-trusting a dev certificate every year.
  • --export-cer — emit a .cer (public key only) alongside the .pfx. The .cer is the artifact you hand to a colleague or a test machine in order to trust the certificate, so not being able to ask for one is a real gap for anyone sharing a dev certificate across machines.

Background: the extension's command surface was designed against winappcli ~0.3.1, while scripts/download-cli.ps1 downloads latest (now 0.6.x). The result is a 0.6.x CLI shipping behind a 0.3.x UI, with these options present in the bundled binary but not surfaced anywhere.

These were deliberately split out of the in-flight cert generate work so that change can stay focused on correctness (publisher/manifest matching, and making failures visible in VS Code at all) rather than growing a configuration surface at the same time.

Describe the solution you'd like

Expose the three options without turning a two-click command into a multi-prompt interrogation. The design sketched during the cert generate review, for whoever picks this up:

  • Settings for values a user sets once per project and then never wants to be asked about again:
    • winapp.cert.outputPath (default "" ⇒ CLI default devcert.pfx in the project directory)
    • winapp.cert.validDays (default 365, matching the CLI)
    • winapp.cert.exportCer (default worth discussing — see note below)
  • An "Advanced options…" entry appended to the existing generate QuickPick, opening a single canPickMany checklist (Custom output path, Custom validity period, Export .cer alongside .pfx, Override publisher) that then prompts only for the rows the user ticked, with answers recalled from workspaceState for the next run.

The point of the two-tier shape is that the default path gains zero prompts, one extra click reaches the full surface, and the user only answers as many questions as they explicitly asked for.

Note on --export-cer: consider defaulting it on. The .cer costs nothing to produce, contains no secret, and is what you hand to someone else to trust. It is also what allows "generate and install" to elevate only cert install <the .cer> instead of the .pfx — installing the .pfx imports the private key into the machine store, which is more privilege than trusting the certificate requires.

Additional context

Related work and issues:

  • The in-flight cert generate change covers --manifest / --publisher (so the certificate's publisher matches the manifest) and --if-exists, and moves the command off the fire-and-forget terminal transport onto spawn + --json so exit codes and errors are actually visible. That transport change is a prerequisite for anything here that needs to read back the generated paths.
  • #242 tracks --password support across the cert commands.
  • The underlying version drift is worth addressing on its own: scripts/download-cli.ps1 defaults to latest, so the UI silently falls further behind each CLI release. Pinning the downloaded version, or asserting a minimum version at activation using the CLI's --cli-schema self-description, would stop this recurring.
Lenguaje dominante
TypeScript
Estrellas
14
Forks
4
Merge medio
7 d 28 min
PR fusionados (30 d)
10

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 microsoft/WinAppVSCE

Todos los issues de microsoft/WinAppVSCE

Issues similares

Más issues de TypeScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.