Skip to content

Doc manifest schema process#6280

Open
JohnMcPMS wants to merge 6 commits into
microsoft:masterfrom
JohnMcPMS:doc-manifest-schem-process
Open

Doc manifest schema process#6280
JohnMcPMS wants to merge 6 commits into
microsoft:masterfrom
JohnMcPMS:doc-manifest-schem-process

Conversation

@JohnMcPMS

@JohnMcPMS JohnMcPMS commented Jun 11, 2026

Copy link
Copy Markdown
Member

📖 Description

Includes some human and 🤖 notes for updating the manifest schema files, as well as a script that does most/all of it for you.

🔍 Validation

Tested the script output locally.

Microsoft Reviewers: Open in CodeFlow

@JohnMcPMS JohnMcPMS requested a review from a team as a code owner June 11, 2026 19:26
@github-actions

This comment has been minimized.

florelis
florelis previously approved these changes Jun 11, 2026

@florelis florelis left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't read the script that closely, but it looks enough like it's good

Comment thread schemas/JSON/manifests/README.md Outdated

## Helper script

`Branch-LatestManifestSchema.ps1` (in this directory) automates most of both workflows below.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: Branch is not an approved PS verb. If not using an approved verb

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Moved to "Checkpoint"

the in-flight schema needs to be locked in.

With -BumpVersion:
Reads the target version from src/binver/binver/version.h (MAJOR.MINOR.0) and compares

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we have this script also update version.h?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That feels like a part of a larger operation. We could certainly collect a bunch of things, including this, into a "Move the version forward" process.

Comment thread schemas/JSON/manifests/README.md Outdated
`ManifestSchemaValidation.cpp`, converting the old top block to an `else if`.
10. Adds a new version constant to `ManifestVersion.cs`.

**Manual steps always required (not automated):**

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not also automate this?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dropped them as it is actually part of modifying the latest schema, not preparing to do so.

Comment on lines +72 to +73
param([string]$Content, [string]$Path)
[System.IO.File]::WriteAllText($Path, $Content, (New-Object System.Text.UTF8Encoding $false))

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could use Out-File

$vcxitemsFile = Join-Path $manifestSchemaDir 'ManifestSchema.vcxitems'
$filtersFile = Join-Path $manifestSchemaDir 'ManifestSchema.vcxitems.filters'
$manifestCommonH = Join-Path $RepoRoot 'src\AppInstallerCommonCore\Public\winget\ManifestCommon.h'
$schemaValidationCpp = Join-Path $RepoRoot 'src\AppInstallerCommonCore\Manifest\ManifestSchemaValidation.cpp'

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: misaligned

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR documents the WinGet manifest JSON schema versioning/branching process and introduces a PowerShell helper script to automate freezing latest/ schemas into versioned snapshots and (optionally) bumping latest/ to match the binary version.

Changes:

  • Added schemas/JSON/manifests/README.md describing schema directory layout and the two versioning workflows.
  • Added Branch-LatestManifestSchema.ps1 to automate schema branching and source-file updates during version bumps.
  • Added a path-scoped Copilot instructions file for manifest schema versioning guidance.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
schemas/JSON/manifests/README.md Documents schema folder structure, versioning workflows, and required manual steps.
schemas/JSON/manifests/Branch-LatestManifestSchema.ps1 Adds automation for branching latest/ into vX.Y.0/ and optionally bumping schema/version references across source files.
.github/instructions/manifest-schema-versioning.instructions.md Adds path-scoped contributor/agent guidance for the manifest schema versioning process.

Comment thread schemas/JSON/manifests/Checkpoint-LatestManifestSchema.ps1
@github-actions

This comment has been minimized.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants