[PR #13887] [MERGED] Add $schema to cgmanifest.json #29806

Open
opened 2026-01-31 09:36:59 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/microsoft/terminal/pull/13887
Author: @JamieMagee
Created: 8/30/2022
Status: Merged
Merged: 8/31/2022
Merged by: @undefined

Base: mainHead: cgmanifest-schema


📝 Commits (1)

  • 235e7f3 Add $schema to cgmanifest.json

📊 Changes

11 files changed (+110 additions, -91 deletions)

View changed files

📝 dep/CLI11/cgmanifest.json (+11 -9)
📝 dep/jsoncpp/cgmanifest.json (+11 -9)
📝 oss/boost/cgmanifest.json (+1 -0)
📝 oss/chromium/cgmanifest.json (+13 -11)
📝 oss/dynamic_bitset/cgmanifest.json (+13 -11)
📝 oss/fmt/cgmanifest.json (+12 -10)
📝 oss/interval_tree/cgmanifest.json (+8 -6)
📝 oss/libpopcnt/cgmanifest.json (+13 -11)
📝 oss/pcg/cgmanifest.json (+1 -0)
📝 oss/wyhash/cgmanifest.json (+15 -14)
📝 oss/xorg_apps_rgb/cgmanifest.json (+12 -10)

📄 Description

This pull request adds the JSON schema for cgmanifest.json.

FAQ

Why?

A JSON schema helps you to ensure that your cgmanifest.json file is valid.
JSON schema validation is a build-in feature in most modern IDEs like Visual Studio and Visual Studio Code.
Most modern IDEs also provide code-completion for JSON schemas.

How can I validate my cgmanifest.json file?

Most modern IDEs like Visual Studio and Visual Studio Code have a built-in feature to validate JSON files.
You can also use this small script to validate your cgmanifest.json file.

Why does it suggest camel case for the properties?

Component Detection is able to read camel case and pascal case properties.
However, the JSON schema doesn't have a case-insensitive mode.
We therefore suggest camel case as it's the most common format for JSON.

Why is the diff so large?

To deserialize the cgmanifest.json file, we use JSON.parse().
However, to serialize the JSON again we use prettier.
We found that, in general, it gave smaller diffs than the default JSON.stringify() function.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/microsoft/terminal/pull/13887 **Author:** [@JamieMagee](https://github.com/JamieMagee) **Created:** 8/30/2022 **Status:** ✅ Merged **Merged:** 8/31/2022 **Merged by:** [@undefined](undefined) **Base:** `main` ← **Head:** `cgmanifest-schema` --- ### 📝 Commits (1) - [`235e7f3`](https://github.com/microsoft/terminal/commit/235e7f3bbc33e4e66a5403844803b0bd66e0794b) Add `$schema` to `cgmanifest.json` ### 📊 Changes **11 files changed** (+110 additions, -91 deletions) <details> <summary>View changed files</summary> 📝 `dep/CLI11/cgmanifest.json` (+11 -9) 📝 `dep/jsoncpp/cgmanifest.json` (+11 -9) 📝 `oss/boost/cgmanifest.json` (+1 -0) 📝 `oss/chromium/cgmanifest.json` (+13 -11) 📝 `oss/dynamic_bitset/cgmanifest.json` (+13 -11) 📝 `oss/fmt/cgmanifest.json` (+12 -10) 📝 `oss/interval_tree/cgmanifest.json` (+8 -6) 📝 `oss/libpopcnt/cgmanifest.json` (+13 -11) 📝 `oss/pcg/cgmanifest.json` (+1 -0) 📝 `oss/wyhash/cgmanifest.json` (+15 -14) 📝 `oss/xorg_apps_rgb/cgmanifest.json` (+12 -10) </details> ### 📄 Description This pull request adds the JSON schema for `cgmanifest.json`. ## FAQ ### Why? A JSON schema helps you to ensure that your `cgmanifest.json` file is valid. JSON schema validation is a build-in feature in most modern IDEs like Visual Studio and Visual Studio Code. Most modern IDEs also provide code-completion for JSON schemas. ### How can I validate my `cgmanifest.json` file? Most modern IDEs like Visual Studio and Visual Studio Code have a built-in feature to validate JSON files. You can also use [this small script](https://github.com/JamieMagee/verify-cgmanifest) to validate your `cgmanifest.json` file. ### Why does it suggest camel case for the properties? Component Detection is able to read camel case and pascal case properties. However, the JSON schema doesn't have a case-insensitive mode. We therefore suggest camel case as it's the most common format for JSON. ### Why is the diff so large? To deserialize the `cgmanifest.json` file, we use [`JSON.parse()`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/parse). However, to serialize the JSON again we use [`prettier`](https://prettier.io/). We found that, in general, it gave smaller diffs than the default [`JSON.stringify()`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/stringify) function. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
claunia added the pull-request label 2026-01-31 09:36:59 +00:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#29806