Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,34 @@ Format follows Keep a Changelog; versions follow SemVer.
## Version strategy

- `0.1.0` was uploaded manually to both registries as the first preview. This work is released as **`0.1.1`** (the owner chose a patch-level bump); the registries do not allow re-publishing an existing version.
- `0.3.0` is a minor release: the project selector, audit status, guided fixes for every provider and the tabbed Control Center add features without removing or renaming any command, setting or rule code.
- `0.2.0` is a minor release: it widens what the analyzer reports and tightens release controls, without removing or renaming any command, setting or rule code.
- Publication is automatic from `main`: a merge that changes `package.json` to a version without a GitHub Release starts [`publish.yml`](.github/workflows/publish.yml) and runs to the end without a second approval: the merge is the release decision ([docs/RELEASE.md](docs/RELEASE.md)).

## [Unreleased]

_Nothing yet._

## [0.3.0] — 2026-11-15

### Added
- Control Center: project selector ("Change project", command `orquestivo.selectProject`), remembered per workspace; supports multi-root, monorepo sub-projects and an explicit "entire workspace" scope. Scanning, intent contract, GitHub repo guess and the CI generator default now follow the selected project; results of a previous project are discarded on change.
- "Analyze existing CI/CD" is the primary action and "Create new CI" the alternative; honest review status (needs attention / partial / no problems detected by the available rules / no CI / not evaluated) and a prioritised, de-duplicated improvement plan (manual guidance only).
- Pure `core/project` and `core/recommendations` modules with unit tests.

### Changed
- `docs/USAGE.md` no longer claims an unreleased preview or that files are never overwritten.

- Guided fixes for existing GitHub Actions workflows: `PERMISSIONS_UNDECLARED` and `TIMEOUT_UNSET` get a verified minimal edit (`core/remediation`), diff preview, modal confirmation, SHA-256 guard against concurrent edits, rollback on write failure, re-analysis and `orquestivo.undoImprovement`. Commands `orquestivo.improveFinding` (internal) and `orquestivo.undoImprovement`.

- Verified fixes for GitLab (`GITLAB_NO_TIMEOUT`, `GITLAB_ARTIFACT_NO_EXPIRY`), Azure (`AZURE_NO_TIMEOUT`) and Jenkins (`JENKINS_NO_TIMEOUT`, `JENKINS_NO_BUILD_DISCARDER`); the planner now lives in `src/providers/remediation.ts` and re-analyzes with the owning provider.
- Control Center tabs (Summary, Findings, Improvements, Pipeline, Evidence, Advanced) with keyboard navigation; after the first render the host posts only the `<main>` markup so tab, focus, scroll and open sections are preserved.
- Undo of the last improvement persists in workspace state (validated on load).
- Specific states: untrusted workspace (Manage workspace trust), cancelled analysis, unreadable/oversized/failed files.

### Not yet implemented
- Real-VS-Code integration test of the apply/undo flow. The README gallery now includes screenshots of the current Control Center (renders of the product's own HTML). See `docs/UPGRADE_ORQUESTIVO_UX_CICD_CHECKLIST.md`.

## [0.2.0] — 2026-11-10

### Added
Expand Down
56 changes: 52 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

<p align="center">
<img alt="License MIT" src="https://img.shields.io/badge/license-MIT-7C8CF8">
<img alt="Version 0.2.0" src="https://img.shields.io/badge/version-0.2.0-14181D">
<img alt="Version 0.3.0" src="https://img.shields.io/badge/version-0.3.0-14181D">
<img alt="Visual Studio Code 1.99+" src="https://img.shields.io/badge/VS_Code-1.99%2B-14181D">
<img alt="TypeScript" src="https://img.shields.io/badge/TypeScript-strict-3178C6">
</p>
Expand All @@ -33,10 +33,21 @@ A pipeline can be valid YAML and still be **unsafe, fragile or incorrect for its

Orquestivo reports **static inference** by default. It does not run your pipeline. Only opt-in, read-only evidence from real GitHub Actions runs can back a statement about what actually happened, and even then it does not prove business requirements are met.

## How to use it in four steps

1. **Pick the project.** The Control Center shows the project being audited (a single folder is selected automatically). With several folders or a monorepo press **Change project**; the choice is remembered per workspace and "entire workspace" is a deliberate option.
2. **Press _Analyze existing CI/CD_.** Analysis is local and read-only: no pipeline is run and no GitHub login, token or AI is needed. Prefer a new pipeline? Use **Create new CI**.
3. **Read the review.** The status is honest (*Needs attention*, *Partial*, *No problems detected by the available rules*, *No CI/CD found* or *Not evaluated*) and **What to fix first** lists the most important items with why they matter and what to change.
4. **Apply a safe fix, or fix it by hand.** For a small set of verified fixes press **Review and apply fix**: Orquestivo opens a diff, asks for explicit confirmation, refuses to write if the file changed meanwhile, re-analyzes, and **Undo last improvement** reverts it unless you edited the file afterwards (the undo record survives reloading VS Code). Verified fixes: GitHub Actions `permissions` and job `timeout-minutes`; GitLab CI default `timeout` and artifact `expire_in`; Azure Pipelines `timeoutInMinutes`; Jenkins `timeout` and `buildDiscarder` options. Every other item is manual guidance, with no apply button.

The Control Center is organised in tabs: **Summary**, **Findings**, **Improvements**, **Pipeline**, **Evidence** and **Advanced**. Refreshes keep your tab, focused control, scroll position and expanded sections.

## What it does

| Area | Capability |
| --- | --- |
| Project-aware audit | Project selector (multi-root, monorepo sub-projects), results, intent contract and generator default scoped to the selected project; stale scans are discarded when you switch |
| Guided improvements | Prioritised plan from real findings; verified diff-first fixes for seven rules across GitHub Actions, GitLab CI, Azure Pipelines and Jenkins, each re-analyzed before it is offered, with hash guard and persistent undo. No fix is invented for any other rule |
| Script-injection checks | Flags attacker-controlled values (`github.head_ref`, `inputs.*`, issue and pull request text, `workflow_run` data) interpolated into `run` scripts and `actions/github-script` programs, even inside `format()` or bracket access. Textual, no data-flow: see [docs/ANALYSIS.md](docs/ANALYSIS.md#untrusted-contexts-expression_in_script) |
| Multi-provider analysis | **GitHub Actions** (69 rule codes), **GitLab CI/CD**, **Azure Pipelines** and **Jenkins** (declarative Jenkinsfile). Rule details: [docs/ANALYSIS.md](docs/ANALYSIS.md), [docs/PROVIDERS.md](docs/PROVIDERS.md) |
| Control Center | Webview with an accessible pipeline diagram (with a textual alternative) and three explanation levels: **beginner**, **advanced**, **expert** |
Expand All @@ -52,6 +63,8 @@ Commands (Command Palette, category "Orquestivo"):
| Command ID | Purpose |
| --- | --- |
| `orquestivo.analyze` | Analyze CI pipeline files in the workspace |
| `orquestivo.selectProject` | Choose which project (folder, monorepo sub-project or whole workspace) is audited |
| `orquestivo.undoImprovement` | Undo the last applied improvement (refuses if the file was edited afterwards) |
| `orquestivo.generateCI` | Open the generator wizard |
| `orquestivo.openHome` | Open the Control Center |
| `orquestivo.connectGitHub` | Store a GitHub token in SecretStorage (opt-in) |
Expand All @@ -60,13 +73,13 @@ Commands (Command Palette, category "Orquestivo"):
| `orquestivo.undoLastGeneration` | Undo the files created by the last generation |
| `orquestivo.ai.explainFinding` | Ask the configured AI provider to explain a finding (only if enabled) |

> Command registration and UI wording were being implemented while this document was written. Cross-check the live list in `package.json` (`contributes.commands`). `orquestivo.openFinding` is an internal navigation command.
> Command registration and UI wording were being implemented while this document was written. Cross-check the live list in `package.json` (`contributes.commands`). `orquestivo.openFinding` and `orquestivo.improveFinding` are internal commands used by the Control Center.

Diagnostics identify supported static patterns. A clean scan **does not mean** a pipeline has run, is secure in every context or will deploy successfully.

## Screenshots

A look at Orquestivo. Images 1–3 are real VS Code captures from the earlier 0.1.0 release; images 4–8 show the current Control Center, rendered from the product's own HTML (`src/ui`) with a real analysis of sample workflows and a VS Code dark theme palette. They are not full VS Code window captures; regenerate them with `scripts/render-readme-media.mjs`. Click any image to open it at full resolution.
A look at Orquestivo. Images 1–3 are real VS Code captures from the earlier 0.1.0 release; images 4–11 show the current Control Center, rendered from the product's own HTML (`src/ui`) with a real analysis of sample workflows and a VS Code dark theme palette. They are not full VS Code window captures; regenerate them with `scripts/render-readme-media.mjs`. Click any image to open it at full resolution.

### 1. Control Center — scan overview

Expand Down Expand Up @@ -107,7 +120,7 @@ Counts by severity, filters by severity and category, and each finding with why

<p align="center">
<a href="media/04-control-center-overview.png">
<img src="media/04-control-center-overview.png" alt="Orquestivo Control Center in dark theme with 1 pipeline file, 1 error, 8 warnings, 5 informational findings, severity and category filters and the first detailed findings." width="940" />
<img src="media/04-control-center-overview.png" alt="Orquestivo Control Center in dark theme, Findings tab selected, with 1 pipeline file, 1 error, 8 warnings, 5 informational findings, severity and category filters and the first detailed findings." width="940" />
</a>
</p>
<p align="center"><sub>Control Center · Resumen, filtros y hallazgos explicados</sub></p>
Expand Down Expand Up @@ -158,6 +171,41 @@ GitHub Actions, GitLab CI/CD and Jenkins files analysed together: provider chips

> Images 1–3 predate the multi-provider Control Center, the wizard diff preview and the evidence features. None of these images demonstrates execution, deployment or verification of a pipeline's intended outcome; the guided wizard and the Problems panel in a real VS Code window are covered by the integration suite rather than by a screenshot.

### 9. Audit status — what to fix first

For an existing project, the Summary tab ranks the findings by priority and says where each one is, why it matters and what to change. Items that have a verified automatic fix offer **Review and apply fix**; a diff is shown first and nothing changes until you confirm. The *Beginner* experience level is shown.

<p align="center">
<a href="media/09-project-audit-plan.png">
<img src="media/09-project-audit-plan.png" alt="Orquestivo Control Center Summary tab for the project my-app showing the Needs attention status and a prioritized What to fix first list: an unpinned action as manual review, and two low-priority items, missing permissions and a missing job timeout, each with a Review and apply fix button." width="940" />
</a>
</p>
<p align="center"><sub>Resumen · Qué corregir primero, con arreglos que se revisan antes de aplicar</sub></p>

### 10. Project without CI

When the selected project has no supported pipeline file, the Control Center says so and offers to create one with the guided generator.

<p align="center">
<a href="media/10-no-ci.png">
<img src="media/10-no-ci.png" alt="Orquestivo Control Center Summary tab for the project my-app reporting No CI/CD found, with a Create new CI button." width="940" />
</a>
</p>
<p align="center"><sub>Proyecto sin CI · Invitación a crear uno nuevo</sub></p>

### 11. No folder open

When no folder is open, the Control Center says so, offers **Open project** and reports the review as not evaluated instead of showing an empty result.

<p align="center">
<a href="media/11-no-folder.png">
<img src="media/11-no-folder.png" alt="Orquestivo Control Center with no folder open, showing an Open project button and the review status Not evaluated." width="940" />
</a>
</p>
<p align="center"><sub>Sin carpeta · Selección de proyecto</sub></p>

> The diff-first fix preview opens in VS Code's own diff editor, not in the Control Center, so it is not part of this gallery; it is covered by the integration suite.

## Quick start

### Install
Expand Down
27 changes: 27 additions & 0 deletions docs/UPGRADE_ORQUESTIVO_UX_CICD_CHECKLIST.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Upgrade checklist — project-aware CI/CD audit

Baseline: `main` @ `122c1dc`, version `0.2.0`, branch `feat/control-center-ci-audit-ux`. Status: TODO / PASS / PARTIAL / BLOCKED.

| ID | Requirement | Status | Files | Evidence / notes |
|---|---|---|---|---|
| OQ-P0-01 | Project selector, per-workspace persistence, scoped scan | PASS (unit) | `src/core/project.ts`, `src/vscode/project.ts`, `scanner.ts`, `scan-service.ts` | `test/project-audit.test.cjs`; not exercised in a real VS Code window |
| OQ-P0-02 | "Analyze existing CI/CD" primary, "Create new CI" secondary | PASS (render contract) | `render.ts`, `i18n.ts` | render tests |
| OQ-P0-03 | Prioritised plan from real findings | PASS | `src/core/recommendations.ts` | `manual-only` unless a verified fix exists |
| OQ-P0-04 | One project context for scan, intent, remote, generator | PASS (code) | `intent.ts`, `remote.ts`, `generator.ts`, `extension.ts` | no automated multi-root integration test |
| OQ-P0-05 | Safe remediation (diff, confirm, hash guard, undo, re-analysis) | PASS (unit) / integration BLOCKED | `src/providers/remediation.ts`, `src/vscode/remediation.ts` | 7 rules over 4 providers; `test/remediation.test.cjs`; write/undo path needs real VS Code (not run) |
| OQ-P1-06 | Specific empty/error states | PASS (render contract) | `render.ts`, `store.ts` | no CI, no folder, untrusted (+ manage trust), cancelled, unreadable/oversized/failed files, partial |
| OQ-P1-07 | Honest executive summary | PASS | `recommendations.ts`, `render.ts` | never says "perfect" |
| OQ-P1-08 | Preserve UI state on refresh | PASS (unit of markup) / visual BLOCKED | `client-script.ts`, `control-center.ts`, `render.ts` | host posts `<main>` fragment; script restores tab, focus, scroll, open details, level select; shell rebuilt when the panel becomes visible again. Not observed in a real webview |
| OQ-P1-09 | Remote evidence tied to project | PARTIAL | `remote.ts` | repo guess + reset follow selection; copy not reworked |
| OQ-P1-10 | AI honesty | PASS (unchanged) | — | no provider claimed |
| OQ-P1-11 | Docs contradictions | PARTIAL | `README.md`, `docs/USAGE.md`, `CHANGELOG.md` | README/USAGE/CHANGELOG updated; **new screenshots BLOCKED** (see below) |
| OQ-P1-12 | E2E for the main journey | BLOCKED | — | needs real VS Code; not run |
| OQ-P2-13 | Tabs / progressive disclosure | PASS (markup, ARIA, keyboard in script) | `render.ts`, `client-script.ts` | 6 tabs, roving tabindex, arrows/Home/End |
| OQ-P2-14 | Accessibility/theme verification | BLOCKED | — | no graphical session |
| OQ-P2-15 | Stale-result protection | PASS (code) | `scan-service.ts` | generation counter + cancellation |

## Validation log
- `npm run typecheck`, `npm run lint`: PASS.
- `npm test`: 794/795 pass; the failure `safe-path: a real symlink or junction pointing outside the root is rejected` reports `unresolvable` instead of `symlink-escape` on this Windows host. Code untouched (fails closed); not verified on CI.
- Not run: `test:integration`, `verify:enterprise`, `package`.
- Screenshots: `msedge` is not on PATH and the command policy refused the full path, so no PNG was produced; no workaround was attempted. Scenes 09-11 of `scripts/render-readme-media.mjs` are ready to capture.
12 changes: 12 additions & 0 deletions docs/UPGRADE_ORQUESTIVO_UX_CICD_HANDOFF.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Handoff — project-aware CI/CD audit, guided fixes, tabs (partial)

**Result: PARTIAL.** All requested code is implemented and unit-tested; nothing has been run in a real VS Code window and the README screenshots are missing.

- Base: `main` @ `122c1dc` (0.2.0). Branch: `feat/control-center-ci-audit-ux`.
- Implemented: project selector/isolation; analyze-existing path; honest status; prioritised plan; verified diff-first fixes (7 rules, 4 providers) with SHA-256 guard, rollback, re-analysis and persistent undo; tabbed Control Center; fragment updates preserving tab/focus/scroll/open sections; specific states (untrusted, cancelled, unreadable).
- Key files: `src/core/{project,recommendations}.ts`, `src/providers/remediation.ts`, `src/vscode/{project,remediation,control-center,store,scan-service}.ts`, `src/ui/{render,client-script,messages,view-model}.ts`, tests `test/{project-audit,remediation}.test.cjs`.
- Tests: typecheck and lint PASS; unit suite passes except the Windows symlink test of `safe-path` (untouched code, unverified on CI). Not run: `test:integration`, `verify:enterprise`, `package`.
- BLOCKED: README screenshots (no browser reachable under the command policy; no workaround attempted), real-window verification of tabs/focus preservation/apply/undo, theme and accessibility checks.
- Limitations: fixes are conservative and fall back to manual guidance on unusual file shapes (flow YAML, existing `default:`/`options` blocks); persisted undo is skipped above ~400 KB; selection (text highlight) is not restored, only focus; "entire workspace" keeps folder-relative paths.
- Rollback: revert the branch; no schema, setting or version change (new commands only).
- Next: capture scenes 09-11 and add the PNGs to the README; integration test select → analyze → diff → apply → undo → reload → undo.
Loading
Loading