Commit Graph
6 Commits
Author SHA1 Message Date
james.maesandClaude Fable 5.1 a562acd55c ci: adopt the standards' pull-request, security, CodeQL and Scorecard gates (#68)
* ci: adopt the standards' pull-request, security, CodeQL and Scorecard gates

Call the KofTwentyTwo/standards reusable workflows (pinned to 855cf44):
pr-gates (Conventional Commit title, DCO, dependency review), security
(gitleaks over history, Trivy + OSV-Scanner on the lock files, zizmor +
actionlint), codeql (security-extended for csharp and actions, gated at
high), plus the Scorecard workflow. Root scanner configs, global.json,
.pre-commit-config.yaml with the dotnet-format hook, and the standard
PSScriptAnalyzer settings come with them.

Harden the existing workflows: persist-credentials false on every checkout,
no restore cache in the release job, verify-job outputs and inputs read from
environment variables instead of ${{ }} inside run:, concurrency on release,
locked restores for publish and pack (the CLI now declares win-x64 so its
lock file carries that runtime graph).

Release assets: a CycloneDX 1.6 SBOM per artifact (attached and attested),
SHA256SUMS (renamed; the channel feed is listed too), LICENSE inside the CLI
zip and the app payload, and release notes generated from Conventional
Commit subjects by .github/scripts/New-ReleaseNotes.ps1 with breaking and
security changes first. Generated pull requests use Conventional Commit
titles; Dependabot gets the 7-day cooldown and the ci prefix; the NuGet
update script holds back versions younger than the cooldown.

The old job names and dependency-review.yml stay until protect-main lists
the new required contexts (#66).

Closes #63

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Signed-off-by: James Maes <james@kof22.com>

* ci: pin the standards workflows to the commit that exempts file-licensed packages

standards#4 (merged as ae174f5) adds the `allow-dependencies-licenses` input to
the reusable pull-request workflow, fixes the DCO check for commits whose author
has no GitHub login, and accepts `security` titles. The three callers move to
that commit, and pr-gates.yml exempts LibGit2Sharp, Microsoft.WindowsAppSDK and
Microsoft.Windows.SDK.BuildTools from the license check (standards EX-0003):
their nuspecs name a license file, so the dependency graph reports NOASSERTION.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Signed-off-by: James Maes <james@kof22.com>

---------

Signed-off-by: James Maes <james@kof22.com>
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-09 14:27:45 -05:00
James MaesandClaude Fable 5.1 fa6317d4fb CI: remove duplicated cache keys from the setup-dotnet steps (workflow files failed to validate)
The lock-file batch inserted the cache: / cache-dependency-path: pair twice
into every setup-dotnet 'with:' block (the batch script ran twice); GitHub
rejects duplicate mapping keys and every workflow on dev reported a startup
failure. One pair each now.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-09 07:31:43 -05:00
James MaesandClaude Fable 5.1 437d497e63 Security + release engineering: SHA-pinned actions, scoped secrets, pinned tooling, provenance, no token redisplay, startup update check, lock files, UI diagnostics (#32, #31)
Workflows
- Every `uses:` is pinned to a full commit SHA with the version as a comment
  (checkout v7.0.1, setup-dotnet v6.0.0, upload-artifact v7.0.2, codeql-action
  v4, dependency-review-action v5.0.0, attest-build-provenance v4); Dependabot
  keeps the pins current.
- release.yml: NUGET_API_KEY and WINGET_TOKEN are no longer job-level env — only
  the push and winget steps receive them. vpk is installed at a pinned version
  (1.2.161, matching the Velopack package) and wingetcreate is downloaded from a
  pinned release asset and verified against its committed SHA-256 before it
  runs. A build-provenance attestation is published for the CLI zip and every
  Velopack asset (verify with `gh attestation verify <file> -R KofTwentyTwo/gclo`).
  gclo.Engine is packed with ContinuousIntegrationBuild and a .snupkg.
- packages.lock.json committed for all seven projects
  (RestorePackagesWithLockFile); CI builds and the format restore run in locked
  mode, every setup-dotnet step caches the NuGet packages keyed on the lock
  files, and the NuGet-updates workflow refreshes them after a bump.
- UI e2e job: TRX logger, and on failure an artifact with the TRX, a
  screenshot of the screen at session end, and the app's activity log
  (AppSession captures both when GCLO_UITEST_ARTIFACTS is set).

App
- The stored token is never redisplayed: the account wizard's token box opens
  empty with "Leave empty to keep the stored token" and fetches the vault token
  only for step 2's validation call when the box is empty (never into the
  Token property); the connect card and chip flyout no longer mirror an
  account's or the default token into a PasswordBox.
- A background update check on every launch of an installed build offers a
  newer release in the update bar with an "Update and restart…" action;
  silent when up to date or when the check fails.
- gclo.Engine.csproj: PackageProjectUrl, PackageTags, SourceLink to the public
  repo, embedded untracked sources, symbol package.

Docs
- SECURITY.md: no longer "pre-1.0"; the token section states what is persisted
  (Credential Manager only), the same-user trust boundary, and that the UI
  never redisplays a stored token; a new "How releases are trusted" section
  covers the tag/gates/attestation chain and the open signing item (#57).
- CONTRIBUTING.md: honest branch model (checks advisory on dev, enforced at
  main) and the lock-file refresh step. README: repos/dry-run/accounts
  examples. #57 opened as needs-owner for Authenticode signing.

Tests: wizard token handling (empty box validates with the stored token
without exposing it; no stored token blocks step 2 until one is typed).
387 Engine tests, coverage 100%, format clean, locked-mode build clean,
FlaUI e2e 8/8 with the artifact capture exercised locally.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-09 07:20:52 -05:00
James MaesandClaude Fable 5.1 0bc425268a CI: run CodeQL on dev pushes and pull requests (#45)
Feature PRs target dev, but CodeQL only watched main, so code reached the
integration branch unanalyzed. Scan pushes and PRs on both branches; the
weekly scheduled scan is unchanged. CONTRIBUTING's check table now says so.

Closes #45

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-09 05:35:12 -05:00
James MaesandClaude Fable 5.1 818c0e1763 Deps: setup-dotnet v6, LibGit2Sharp 0.32 (security), Velopack, test tooling
Dependabot has been closing its own PRs and failing weekly on actions/setup-dotnet
("no longer updatable") since the v6 release in July, so nothing has landed since.
Bump everything it should have delivered:

- actions/setup-dotnet v5 -> v6 in all five workflow usages (ESM migration only)
- LibGit2Sharp 0.31.0 -> 0.32.0 (security release, bundles libgit2 1.8.6)
- Velopack 1.2.0 -> 1.2.161
- Microsoft.Windows.SDK.BuildTools 10.0.28000.2270 -> .2705
- Microsoft.NET.Test.Sdk 18.7.0 -> 18.10.1, coverlet.collector 10.0.1 -> 10.1.0,
  xunit.runner.visualstudio 3.1.5 -> 4.0.0 (all three test projects)

Verified locally: solution builds warning-free, 267 Engine + 65 CLI tests pass,
coverage gate still reports 100% on gclo.Engine / gclo.ViewModels / gclo,
dotnet format verify clean.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-09 05:29:36 -05:00
James MaesandClaude Fable 5 cbdce91363 Productionize: integration tests, CLI, CI/CD, Velopack self-update
- 15 real-git integration tests for LibGit2GitClient against local fixture
  repos (35 tests total; engine line coverage 60.6%)
- gclo.Cli: scriptable head over the engine (sync/orgs, --json, exit codes
  0/1/2, token via env/file/stdin only) + docs/CLI.md; verified against
  live GitHub (orgs incl. personal account, parallel clone, pull path)
- Velopack 1.2.0: custom Main entry point, UpdateService (GithubSource),
  Help > Check for updates with update-and-restart flow
- GitHub Actions: CI (x64 -warnaserror, tests, coverage gate >=60%,
  dotnet format gate), CodeQL, dependency review, Dependabot, tag-driven
  release pipeline (Velopack pack/upload, CLI zip, gated NuGet + winget)
  + docs/RELEASING.md
- TODO.md status updates; T22 (Windows-invalid paths) prioritized next

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-03 08:55:12 -05:00