From db2f65017053dbc41aeeb6498ddcd7c013b3ea62 Mon Sep 17 00:00:00 2001 From: Abdulrahman Alfawal <61620817+alfawal@users.noreply.github.com> Date: Sun, 3 Mar 2024 07:42:25 +0300 Subject: [PATCH] Updated JSON schemas --- site/site/public/schemas/Cargo.toml.json | 1237 ++++++++++++----- site/site/public/schemas/dein.toml.json | 276 ++-- site/site/public/schemas/fly.toml.json | 499 ++++--- site/site/public/schemas/makefile.toml.json | 1071 +++++++------- site/site/public/schemas/pyproject.toml.json | 1017 +++++++------- site/site/public/schemas/replit.toml.json | 421 +++--- .../public/schemas/rust-toolchain.toml.json | 712 +++++----- site/site/public/schemas/rustfmt.toml.json | 15 +- 8 files changed, 2987 insertions(+), 2261 deletions(-) diff --git a/site/site/public/schemas/Cargo.toml.json b/site/site/public/schemas/Cargo.toml.json index 5c3ee15bd..5e68c44e8 100644 --- a/site/site/public/schemas/Cargo.toml.json +++ b/site/site/public/schemas/Cargo.toml.json @@ -1,240 +1,6 @@ { "$schema": "http://json-schema.org/draft-07/schema#", - "title": "Cargo.toml", - "description": "A schema for Cargo.toml.", - "x-taplo-info": { - "authors": ["tamasfe (https://github.com/tamasfe)"], - "patterns": ["^(.*(/|\\\\)Cargo\\.toml|Cargo\\.toml)$"] - }, - "type": "object", - "properties": { - "badges": { - "description": "[crates.io](https://crates.io) can display various badges for build status, test coverage, etc. for\neach crate. All badges are optional.\n\n- The badges pertaining to build status that are currently available are\n Appveyor, CircleCI, Cirrus CI, GitLab, Azure DevOps, Travis CI and Bitbucket\n Pipelines.\n- Available badges pertaining to code test coverage are Codecov and Coveralls.\n- There are also maintenance-related badges based on isitmaintained.com\n which state the issue resolution time, percent of open issues, and future\n maintenance intentions.\n\nMost badge specifications require a `repository` key. It is expected to be in\n`user/repo` format.\n\n```toml\n[badges]\n\n# Appveyor: `repository` is required. `branch` is optional; default is `master`\n# `service` is optional; valid values are `github` (default), `bitbucket`, and\n# `gitlab`; `id` is optional; you can specify the appveyor project id if you\n# want to use that instead. `project_name` is optional; use when the repository\n# name differs from the appveyor project name.\nappveyor = { repository = \"...\", branch = \"master\", service = \"github\" }\n\n# Circle CI: `repository` is required. `branch` is optional; default is `master`\ncircle-ci = { repository = \"...\", branch = \"master\" }\n\n# Cirrus CI: `repository` is required. `branch` is optional; default is `master`\ncirrus-ci = { repository = \"...\", branch = \"master\" }\n\n# GitLab: `repository` is required. `branch` is optional; default is `master`\ngitlab = { repository = \"...\", branch = \"master\" }\n\n# Azure DevOps: `project` is required. `pipeline` is required. `build` is optional; default is `1`\n# Note: project = `organization/project`, pipeline = `name_of_pipeline`, build = `definitionId`\nazure-devops = { project = \"...\", pipeline = \"...\", build=\"2\" }\n\n# Travis CI: `repository` in format \"/\" is required.\n# `branch` is optional; default is `master`\ntravis-ci = { repository = \"...\", branch = \"master\" }\n\n# Bitbucket Pipelines: `repository` is required. `branch` is required\nbitbucket-pipelines = { repository = \"...\", branch = \"master\" }\n\n# Codecov: `repository` is required. `branch` is optional; default is `master`\n# `service` is optional; valid values are `github` (default), `bitbucket`, and\n# `gitlab`.\ncodecov = { repository = \"...\", branch = \"master\", service = \"github\" }\n\n# Coveralls: `repository` is required. `branch` is optional; default is `master`\n# `service` is optional; valid values are `github` (default) and `bitbucket`.\ncoveralls = { repository = \"...\", branch = \"master\", service = \"github\" }\n\n# Is it maintained resolution time: `repository` is required.\nis-it-maintained-issue-resolution = { repository = \"...\" }\n\n# Is it maintained percentage of open issues: `repository` is required.\nis-it-maintained-open-issues = { repository = \"...\" }\n\n# Maintenance: `status` is required. Available options are:\n# - `actively-developed`: New features are being added and bugs are being fixed.\n# - `passively-maintained`: There are no plans for new features, but the maintainer intends to\n# respond to issues that get filed.\n# - `as-is`: The crate is feature complete, the maintainer does not intend to continue working on\n# it or providing support, but it works for the purposes it was designed for.\n# - `experimental`: The author wants to share it with the community but is not intending to meet\n# anyone's particular use case.\n# - `looking-for-maintainer`: The current maintainer would like to transfer the crate to someone\n# else.\n# - `deprecated`: The maintainer does not recommend using this crate (the description of the crate\n# can describe why, there could be a better solution available or there could be problems with\n# the crate that the author does not want to fix).\n# - `none`: Displays no badge on crates.io, since the maintainer has not chosen to specify\n# their intentions, potential crate users will need to investigate on their own.\nmaintenance = { status = \"...\" }\n```", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "type": "string" - } - }, - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-badges-section" - } - } - }, - "bench": { - "description": "Benchmarks provide a way to test the performance of your code using the\n[`cargo bench`](https://doc.rust-lang.org/cargo/commands/cargo-bench.html) command. They follow the same structure as [tests](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#tests),\nwith each benchmark function annotated with the `#[bench]` attribute.\nSimilarly to tests:\n\n* Benchmarks are placed in the [`benches` directory](https://doc.rust-lang.org/cargo/guide/project-layout.html).\n* Benchmark functions defined in libraries and binaries have access to the\n *private* API within the target they are defined in. Benchmarks in the\n `benches` directory may use the *public* API.\n* [The `bench` field](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-bench-field) can be used to define which targets\n are benchmarked by default.\n* [The `harness` field](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-harness-field) can be used to disable the\n built-in harness.\n\n> **Note**: The [`#[bench]`\n> attribute](https://doc.rust-lang.org/unstable-book/library-features/test.html) is currently\n> unstable and only available on the [nightly channel](https://doc.rust-lang.org/book/appendix-07-nightly-rust.html). There are some\n> packages available on [crates.io](https://crates.io/keywords/benchmark) that\n> may help with running benchmarks on the stable channel, such as\n> [Criterion](https://crates.io/crates/criterion).", - "type": "array", - "items": { - "description": "Benchmarks provide a way to test the performance of your code using the\n[`cargo bench`](https://doc.rust-lang.org/cargo/commands/cargo-bench.html) command. They follow the same structure as [tests](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#tests),\nwith each benchmark function annotated with the `#[bench]` attribute.\nSimilarly to tests:\n\n* Benchmarks are placed in the [`benches` directory](https://doc.rust-lang.org/cargo/guide/project-layout.html).\n* Benchmark functions defined in libraries and binaries have access to the\n *private* API within the target they are defined in. Benchmarks in the\n `benches` directory may use the *public* API.\n* [The `bench` field](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-bench-field) can be used to define which targets\n are benchmarked by default.\n* [The `harness` field](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-harness-field) can be used to disable the\n built-in harness.\n\n> **Note**: The [`#[bench]`\n> attribute](https://doc.rust-lang.org/unstable-book/library-features/test.html) is currently\n> unstable and only available on the [nightly channel](https://doc.rust-lang.org/book/appendix-07-nightly-rust.html). There are some\n> packages available on [crates.io](https://crates.io/keywords/benchmark) that\n> may help with running benchmarks on the stable channel, such as\n> [Criterion](https://crates.io/crates/criterion).", - "$ref": "#/definitions/Target", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#benchmarks" - } - } - }, - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#benchmarks" - } - } - }, - "bin": { - "description": "Binary targets are executable programs that can be run after being compiled.\nThe default binary filename is `src/main.rs`, which defaults to the name of\nthe package. Additional binaries are stored in the [`src/bin/`\ndirectory](https://doc.rust-lang.org/cargo/guide/project-layout.html). The settings for each binary can be [customized](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#configuring-a-target) in the `[[bin]]` tables in `Cargo.toml`.\n\nBinaries can use the public API of the package's library. They are also linked\nwith the [`[dependencies]`](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html) defined in `Cargo.toml`.\n\nYou can run individual binaries with the [`cargo run`](https://doc.rust-lang.org/cargo/commands/cargo-run.html) command with the `--bin\n` option. [`cargo install`](https://doc.rust-lang.org/cargo/commands/cargo-install.html) can be used to copy the executable to a\ncommon location.\n\n```toml\n# Example of customizing binaries in Cargo.toml.\n[[bin]]\nname = \"cool-tool\"\ntest = false\nbench = false\n\n[[bin]]\nname = \"frobnicator\"\nrequired-features = [\"frobnicate\"]\n```", - "type": "array", - "items": { - "description": "Binary targets are executable programs that can be run after being compiled.\nThe default binary filename is `src/main.rs`, which defaults to the name of\nthe package. Additional binaries are stored in the [`src/bin/`\ndirectory](https://doc.rust-lang.org/cargo/guide/project-layout.html). The settings for each binary can be [customized](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#configuring-a-target) in the `[[bin]]` tables in `Cargo.toml`.\n\nBinaries can use the public API of the package's library. They are also linked\nwith the [`[dependencies]`](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html) defined in `Cargo.toml`.\n\nYou can run individual binaries with the [`cargo run`](https://doc.rust-lang.org/cargo/commands/cargo-run.html) command with the `--bin\n` option. [`cargo install`](https://doc.rust-lang.org/cargo/commands/cargo-install.html) can be used to copy the executable to a\ncommon location.\n\n```toml\n# Example of customizing binaries in Cargo.toml.\n[[bin]]\nname = \"cool-tool\"\ntest = false\nbench = false\n\n[[bin]]\nname = \"frobnicator\"\nrequired-features = [\"frobnicate\"]\n```", - "$ref": "#/definitions/Target", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#binaries" - } - } - }, - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#binaries" - } - } - }, - "build-dependencies": { - "description": "You can depend on other Cargo-based crates for use in your build scripts.\nDependencies are declared through the `build-dependencies` section of the\nmanifest:\n\n```toml\n[build-dependencies]\ncc = \"1.0.3\"\n```\n\nThe build script **does not** have access to the dependencies listed\nin the `dependencies` or `dev-dependencies` section. Build\ndependencies will likewise not be available to the package itself\nunless listed under the `dependencies` section as well. A package\nitself and its build script are built separately, so their\ndependencies need not coincide. Cargo is kept simpler and cleaner by\nusing independent dependencies for independent purposes.", - "type": "object", - "additionalProperties": { - "$ref": "#/definitions/Dependency" - }, - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#build-dependencies" - }, - "plugins": ["crates"], - "crates": { - "schemas": "dependencies" - } - } - }, - "build_dependencies": { - "type": "object", - "additionalProperties": { - "$ref": "#/definitions/Dependency" - }, - "x-taplo": { - "hidden": true - } - }, - "cargo-features": { - "type": "array", - "items": { - "type": "string" - } - }, - "dependencies": { - "description": "Cargo is configured to look for dependencies on [crates.io](https://crates.io) by default. Only\nthe name and a version string are required in this case. In [the cargo\nguide](https://doc.rust-lang.org/cargo/guide/index.html), we specified a dependency on the `time` crate:\n\n```toml\n[dependencies]\ntime = \"0.1.12\"\n```\n\nThe string `\"0.1.12\"` is a [semver](https://github.com/steveklabnik/semver#requirements) version requirement. Since this\nstring does not have any operators in it, it is interpreted the same way as\nif we had specified `\"^0.1.12\"`, which is called a caret requirement.\n\nA dependency can also be defined by a table with additional options:\n\n```toml\n[dependencies]\ntime = { path = \"../time\", version = \"0.1.12\" }\n```", - "type": "object", - "additionalProperties": { - "$ref": "#/definitions/Dependency" - }, - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html" - } - } - }, - "dev-dependencies": { - "description": "The format of `[dev-dependencies]` is equivalent to `[dependencies]`:\n\n```toml\n[dev-dependencies]\ntempdir = \"0.3\"\n```\n\nDev-dependencies are not used when compiling\na package for building, but are used for compiling tests, examples, and\nbenchmarks.\n\nThese dependencies are *not* propagated to other packages which depend on this\npackage.\n\nYou can also have target-specific development dependencies by using\n`dev-dependencies` in the target section header instead of `dependencies`. For\nexample:\n\n```toml\n[target.'cfg(unix)'.dev-dependencies]\nmio = \"0.0.1\"\n```\n\n> **Note**: When a package is published, only dev-dependencies that specify a\n> `version` will be included in the published crate. For most use cases,\n> dev-dependencies are not needed when published, though some users (like OS\n> packagers) may want to run tests within a crate, so providing a `version` if\n> possible can still be beneficial.\n", - "type": "object", - "additionalProperties": { - "$ref": "#/definitions/Dependency" - }, - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#development-dependencies" - }, - "plugins": ["crates"], - "crates": { - "schemas": "dependencies" - } - } - }, - "dev_dependencies": { - "type": "object", - "additionalProperties": { - "$ref": "#/definitions/Dependency" - }, - "x-taplo": { - "hidden": true - } - }, - "example": { - "description": "Files located under the [examples directory](https://doc.rust-lang.org/cargo/guide/project-layout.html) are example uses of the functionality provided by the library. When compiled, they are placed in the[ target/debug/examples directory](https://doc.rust-lang.org/cargo/guide/build-cache.html).\n\nExamples can use the public API of the package's library. They are also linked with the [dependencies](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html) and [dev-dependencies](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#development-dependencies) defined in Cargo.toml.\n\nBy default, examples are executable binaries (with a `main()` function). You\ncan specify the [`crate-type` field](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-crate-type-field) to make an example\nbe compiled as a library:\n\n```toml\n[[example]]\nname = \"foo\"\ncrate-type = [\"staticlib\"]\n```\n\nYou can run individual executable examples with the [`cargo run`](https://doc.rust-lang.org/cargo/commands/cargo-run.html) command with\nthe `--example ` option. Library examples can be built with\n[`cargo build`](https://doc.rust-lang.org/cargo/commands/cargo-build.html) with the `--example ` option. [`cargo install`](https://doc.rust-lang.org/cargo/commands/cargo-install.html)\nwith the `--example ` option can be used to copy executable\nbinaries to a common location. Examples are compiled by [`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html) by\ndefault to protect them from bit-rotting. Set [the `test`\nfield](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-test-field) to `true` if you have `#[test]` functions in the\nexample that you want to run with [`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html).\n", - "type": "array", - "items": { - "description": "Files located under the [examples directory](https://doc.rust-lang.org/cargo/guide/project-layout.html) are example uses of the functionality provided by the library. When compiled, they are placed in the[ target/debug/examples directory](https://doc.rust-lang.org/cargo/guide/build-cache.html).\n\nExamples can use the public API of the package's library. They are also linked with the [dependencies](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html) and [dev-dependencies](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#development-dependencies) defined in Cargo.toml.\n\nBy default, examples are executable binaries (with a `main()` function). You\ncan specify the [`crate-type` field](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-crate-type-field) to make an example\nbe compiled as a library:\n\n```toml\n[[example]]\nname = \"foo\"\ncrate-type = [\"staticlib\"]\n```\n\nYou can run individual executable examples with the [`cargo run`](https://doc.rust-lang.org/cargo/commands/cargo-run.html) command with\nthe `--example ` option. Library examples can be built with\n[`cargo build`](https://doc.rust-lang.org/cargo/commands/cargo-build.html) with the `--example ` option. [`cargo install`](https://doc.rust-lang.org/cargo/commands/cargo-install.html)\nwith the `--example ` option can be used to copy executable\nbinaries to a common location. Examples are compiled by [`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html) by\ndefault to protect them from bit-rotting. Set [the `test`\nfield](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-test-field) to `true` if you have `#[test]` functions in the\nexample that you want to run with [`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html).\n", - "$ref": "#/definitions/Target", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#examples" - } - } - }, - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#examples" - } - } - }, - "features": { - "description": "Cargo supports features to allow expression of:\n\n* conditional compilation options (usable through `cfg` attributes);\n* optional dependencies, which enhance a package, but are not required; and\n* clusters of optional dependencies, such as `postgres-all`, that would include the\n `postgres` package, the `postgres-macros` package, and possibly other packages\n (such as development-time mocking libraries, debugging tools, etc.).\n\nA feature of a package is either an optional dependency, or a set of other\nfeatures.\n", - "type": "object", - "additionalProperties": { - "type": "array", - "items": { - "type": "string" - } - }, - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/features.html" - } - } - }, - "lib": { - "$ref": "#/definitions/Target", - "x-taplo": { - "docs": { - "main": "The library target defines a \"library\" that can be used and linked by other\nlibraries and executables. The filename defaults to `src/lib.rs`, and the name\nof the library defaults to the name of the package. A package can have only\none library. The settings for the library can be [customized](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#configuring-a-target) in the `[lib]`\ntable in `Cargo.toml`.\n\n```toml\n# Example of customizing the library in Cargo.toml.\n[lib]\ncrate-type = [\"cdylib\"]\nbench = false\n```\n" - }, - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#library" - } - } - }, - "package": { - "$ref": "#/definitions/Package" - }, - "patch": { - "description": "The `[patch]` section of `Cargo.toml` can be used to override dependencies\nwith other copies. The syntax is similar to the\n[`[dependencies]`](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html) section.\n\n", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "$ref": "#/definitions/Dependency" - } - }, - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/overriding-dependencies.html#the-patch-section" - } - } - }, - "profile": { - "$ref": "#/definitions/Profiles" - }, - "project": { - "$ref": "#/definitions/Package", - "x-taplo": { - "hidden": true - } - }, - "replace": { - "type": "object", - "additionalProperties": { - "$ref": "#/definitions/Dependency" - }, - "x-taplo": { - "hidden": true - } - }, - "target": { - "type": "object", - "additionalProperties": { - "$ref": "#/definitions/Platform" - } - }, - "test": { - "description": "Files located under the [`tests` directory](https://doc.rust-lang.org/cargo/guide/project-layout.html) are integration\ntests. When you run [`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html), Cargo will compile each of these files as\na separate crate, and execute them.\n\nIntegration tests can use the public API of the package's library. They are\nalso linked with the [`[dependencies]`](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html) and\n[`[dev-dependencies]`](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#development-dependencies) defined in `Cargo.toml`.\n\nIf you want to share code among multiple integration tests, you can place it\nin a separate module such as `tests/common/mod.rs` and then put `mod common;`\nin each test to import it.\n\nEach integration test results in a separate executable binary, and [`cargo\ntest`](https://doc.rust-lang.org/cargo/commands/cargo-test.html) will run them serially. In some cases this can be inefficient, as it\ncan take longer to compile, and may not make full use of multiple CPUs when\nrunning the tests. If you have a lot of integration tests, you may want to\nconsider creating a single integration test, and split the tests into multiple\nmodules. The libtest harness will automatically find all of the `#[test]`\nannotated functions and run them in parallel. You can pass module names to\n[`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html) to only run the tests within that module.\n\nBinary targets are automatically built if there is an integration test. This\nallows an integration test to execute the binary to exercise and test its\nbehavior. The `CARGO_BIN_EXE_` [environment variable](https://doc.rust-lang.org/cargo/reference/environment-variables.html#environment-variables-cargo-sets-for-crates) is set when the\nintegration test is built so that it can use the [`env` macro](https://doc.rust-lang.org/std/macro.env.html) to locate the\nexecutable.", - "type": "array", - "items": { - "description": "Files located under the [`tests` directory](https://doc.rust-lang.org/cargo/guide/project-layout.html) are integration\ntests. When you run [`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html), Cargo will compile each of these files as\na separate crate, and execute them.\n\nIntegration tests can use the public API of the package's library. They are\nalso linked with the [`[dependencies]`](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html) and\n[`[dev-dependencies]`](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#development-dependencies) defined in `Cargo.toml`.\n\nIf you want to share code among multiple integration tests, you can place it\nin a separate module such as `tests/common/mod.rs` and then put `mod common;`\nin each test to import it.\n\nEach integration test results in a separate executable binary, and [`cargo\ntest`](https://doc.rust-lang.org/cargo/commands/cargo-test.html) will run them serially. In some cases this can be inefficient, as it\ncan take longer to compile, and may not make full use of multiple CPUs when\nrunning the tests. If you have a lot of integration tests, you may want to\nconsider creating a single integration test, and split the tests into multiple\nmodules. The libtest harness will automatically find all of the `#[test]`\nannotated functions and run them in parallel. You can pass module names to\n[`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html) to only run the tests within that module.\n\nBinary targets are automatically built if there is an integration test. This\nallows an integration test to execute the binary to exercise and test its\nbehavior. The `CARGO_BIN_EXE_` [environment variable](https://doc.rust-lang.org/cargo/reference/environment-variables.html#environment-variables-cargo-sets-for-crates) is set when the\nintegration test is built so that it can use the [`env` macro](https://doc.rust-lang.org/std/macro.env.html) to locate the\nexecutable.", - "$ref": "#/definitions/Target", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#integration-tests" - } - } - }, - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#integration-tests" - } - } - }, - "workspace": { - "$ref": "#/definitions/Workspace" - } - }, + "$id": "https://json.schemastore.org/cargo.json", "definitions": { "Build": { "title": "Build", @@ -266,15 +32,31 @@ "DebugLevel": { "title": "Debug Level", "description": "The `debug` setting controls the [`-C debuginfo` flag](https://doc.rust-lang.org/rustc/codegen-options/index.html#debuginfo) which controls the\namount of debug information included in the compiled binary.", - "enum": [0, 1, 2, true, false], + "enum": [ + 0, + 1, + 2, + true, + false, + "none", + "line-directives-only", + "line-tables-only", + "limited", + "full" + ], "x-taplo": { "docs": { "enumValues": [ - "\nNo debug info at all.", - "Line tables only.", - "Full debug info.", - "Full debug info.", - "\nNo debug info at all." + "No debug info at all, default for `release` profile", + "Debug info without type or variable-level information. Generates more detailed module-level info than `line-tables-only`.", + "Full debug info, default for `dev` profile", + "Full debug info, default for `dev` profile", + "No debug info at all, default for `release` profile", + "No debug info at all, default for `release` profile", + "Line info directives only. For the nvptx* targets this enables [profiling](https://reviews.llvm.org/D46061). For other use cases, `line-tables-only` is the better, more compatible choice.", + "Line tables only. Generates the minimal amount of debug info for backtraces with filename/line number info, but not anything else, i.e. no variable or function parameter info.", + "Debug info without type or variable-level information. Generates more detailed module-level info than `line-tables-only`.", + "Full debug info, default for `dev` profile" ] }, "links": { @@ -344,7 +126,7 @@ } }, "git": { - "description": "To depend on a library located in a `git` repository, the minimum information\nyou need to specify is the location of the repository with the `git` key:\n\n```toml\n[dependencies]\nrand = { git = \"https://github.com/rust-lang-nursery/rand\" }\n```\n\nCargo will fetch the `git` repository at this location then look for a\n`Cargo.toml` for the requested crate anywhere inside the `git` repository\n(not necessarily at the root - for example, specifying a member crate name\nof a workspace and setting `git` to the repository containing the workspace).\n\nSince we haven’t specified any other information, Cargo assumes that\nwe intend to use the latest commit on the main branch to build our package.\nYou can combine the `git` key with the `rev`, `tag`, or `branch` keys to\nspecify something else. Here's an example of specifying that you want to use\nthe latest commit on a branch named `next`:\n\n```toml\n[dependencies]\nrand = { git = \"https://github.com/rust-lang-nursery/rand\", branch = \"next\" }\n```\n\nSee [Git Authentication](https://doc.rust-lang.org/cargo/appendix/git-authentication.html) for help with git authentication for private repos.\n\n> **Note**: [crates.io](https://crates.io/) does not allow packages to be published with `git`\n> dependencies (`git` [dev-dependencies](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#development-dependencies) are ignored). See the [Multiple\n> locations](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#multiple-locations) section for a fallback alternative.\n", + "description": "To depend on a library located in a `git` repository, the minimum information\nyou need to specify is the location of the repository with the `git` key:\n\n```toml\n[dependencies]\nrand = { git = \"https://github.com/rust-lang-nursery/rand\" }\n```\n\nCargo will fetch the `git` repository at this location then look for a\n`Cargo.toml` for the requested crate anywhere inside the `git` repository\n(not necessarily at the root - for example, specifying a member crate name\nof a workspace and setting `git` to the repository containing the workspace).\n\nSince we haven't specified any other information, Cargo assumes that\nwe intend to use the latest commit on the main branch to build our package.\nYou can combine the `git` key with the `rev`, `tag`, or `branch` keys to\nspecify something else. Here's an example of specifying that you want to use\nthe latest commit on a branch named `next`:\n\n```toml\n[dependencies]\nrand = { git = \"https://github.com/rust-lang-nursery/rand\", branch = \"next\" }\n```\n\nSee [Git Authentication](https://doc.rust-lang.org/cargo/appendix/git-authentication.html) for help with git authentication for private repos.\n\n> **Note**: [crates.io](https://crates.io/) does not allow packages to be published with `git`\n> dependencies (`git` [dev-dependencies](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#development-dependencies) are ignored). See the [Multiple\n> locations](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#multiple-locations) section for a fallback alternative.\n", "type": "string", "x-taplo": { "links": { @@ -371,7 +153,7 @@ } }, "path": { - "description": "Cargo supports **path dependencies** which are typically sub-crates that live within one repository.\nLet’s start off by making a new crate inside of our `hello_world` package:\n\n```console\n# inside of hello_world/\n$ cargo new hello_utils\n```\n\nThis will create a new folder `hello_utils` inside of which a `Cargo.toml` and\n`src` folder are ready to be configured. In order to tell Cargo about this, open\nup `hello_world/Cargo.toml` and add `hello_utils` to your dependencies:\n\n```toml\n[dependencies]\nhello_utils = { path = \"hello_utils\" }\n```\n\nThis tells Cargo that we depend on a crate called `hello_utils` which is found\nin the `hello_utils` folder (relative to the `Cargo.toml` it’s written in).", + "description": "Cargo supports **path dependencies** which are typically sub-crates that live within one repository.\nLet's start off by making a new crate inside of our `hello_world` package:\n\n```console\n# inside of hello_world/\n$ cargo new hello_utils\n```\n\nThis will create a new folder `hello_utils` inside of which a `Cargo.toml` and\n`src` folder are ready to be configured. In order to tell Cargo about this, open\nup `hello_world/Cargo.toml` and add `hello_utils` to your dependencies:\n\n```toml\n[dependencies]\nhello_utils = { path = \"hello_utils\" }\n```\n\nThis tells Cargo that we depend on a crate called `hello_utils` which is found\nin the `hello_utils` folder (relative to the `Cargo.toml` it's written in).", "type": "string", "x-taplo": { "links": { @@ -496,27 +278,19 @@ }, "Package": { "title": "Package", - "description": "The only fields required by Cargo are [`name`](https://doc.rust-lang.org/cargo/reference/manifest.html#the-name-field) and\n[`version`](https://doc.rust-lang.org/cargo/reference/manifest.html#the-version-field). If publishing to a registry, the registry may\nrequire additional fields. See the notes below and [the publishing chapter](https://doc.rust-lang.org/cargo/reference/publishing.html) for requirements for publishing to [crates.io](https://crates.io/).", + "description": "The only field required by Cargo is [`name`](https://doc.rust-lang.org/cargo/reference/manifest.html#the-name-field).\n If publishing to a registry, the registry may\nrequire additional fields. See the notes below and [the publishing chapter](https://doc.rust-lang.org/cargo/reference/publishing.html) for requirements for publishing to [crates.io](https://crates.io/).", "type": "object", - "required": ["name", "version"], + "required": ["name"], "properties": { "authors": { - "description": "The `authors` field lists people or organizations that are considered the\n\"authors\" of the package. The exact meaning is open to interpretation — it may\nlist the original or primary authors, current maintainers, or owners of the\npackage. These names will be listed on the crate's page on\n[crates.io](https://crates.io). An optional email address may be included within angled\nbrackets at the end of each author.\n\n> **Note**: [crates.io](https://crates.io) requires at least one author to be listed.", - "type": "array", - "items": { - "description": "The `authors` field lists people or organizations that are considered the\n\"authors\" of the package. The exact meaning is open to interpretation — it may\nlist the original or primary authors, current maintainers, or owners of the\npackage. These names will be listed on the crate's page on\n[crates.io](https://crates.io). An optional email address may be included within angled\nbrackets at the end of each author.\n\n> **Note**: [crates.io](https://crates.io) requires at least one author to be listed.", - "type": "string", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-authors-field" - } - } - }, - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-authors-field" + "anyOf": [ + { + "$ref": "#/definitions/Authors" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" } - } + ] }, "autobenches": { "description": "Disable automatic discovery of `bench` targets.\n\nDisabling automatic discovery should only be needed for specialized\nsituations. For example, if you have a library where you want a *module* named\n`bin`, this would present a problem because Cargo would usually attempt to\ncompile anything in the `bin` directory as an executable. Here is a sample\nlayout of this scenario:\n\n```\n├── Cargo.toml\n└── src\n ├── lib.rs\n └── bin\n └── mod.rs\n```\n", @@ -558,22 +332,14 @@ "$ref": "#/definitions/Build" }, "categories": { - "description": "The `categories` field is an array of strings of the categories this package\nbelongs to.\n\n```toml\ncategories = [\"command-line-utilities\", \"development-tools::cargo-plugins\"]\n```\n\n> **Note**: [crates.io](https://crates.io) has a maximum of 5 categories. Each category should\n> match one of the strings available at https://crates.io/category_slugs, and\n> must match exactly.", - "type": "array", - "items": { - "description": "The `categories` field is an array of strings of the categories this package\nbelongs to.\n\n```toml\ncategories = [\"command-line-utilities\", \"development-tools::cargo-plugins\"]\n```\n\n> **Note**: [crates.io](https://crates.io) has a maximum of 5 categories. Each category should\n> match one of the strings available at https://crates.io/category_slugs, and\n> must match exactly.", - "type": "string", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-categories-field" - } + "anyOf": [ + { + "$ref": "#/definitions/Categories" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" } - }, - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-categories-field" - } - } + ] }, "default-run": { "description": "The `default-run` field in the `[package]` section of the manifest can be used\nto specify a default binary picked by [`cargo run`](https://doc.rust-lang.org/cargo/commands/cargo-run.html). For example, when there is\nboth `src/bin/a.rs` and `src/bin/b.rs`:\n\n```toml\n[package]\ndefault-run = \"a\"\n```", @@ -585,52 +351,54 @@ } }, "description": { - "description": "The description is a short blurb about the package. [crates.io](https://crates.io) will display\nthis with your package. This should be plain text (not Markdown).\n\n```toml\n[package]\n# ...\ndescription = \"A short description of my package\"\n```\n\n> **Note**: [crates.io](https://crates.io) requires the `description` to be set.", - "type": "string", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-description-field" + "anyOf": [ + { + "$ref": "#/definitions/Description" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" } - } + ] }, "documentation": { - "description": "\nThe `documentation` field specifies a URL to a website hosting the crate's\ndocumentation. If no URL is specified in the manifest file, [crates.io](https://crates.io) will\nautomatically link your crate to the corresponding [docs.rs](https://docs.rs) page.\n\n```toml\n[package]\n# ...\ndocumentation = \"https://docs.rs/bitflags\"\n```\n", - "type": "string", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-documentation-field" + "anyOf": [ + { + "$ref": "#/definitions/Documentation" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" } - } + ] }, "edition": { - "$ref": "#/definitions/Edition" + "anyOf": [ + { + "$ref": "#/definitions/Edition" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" + } + ] }, "exclude": { - "description": "You can explicitly specify that a set of file patterns should be ignored or\nincluded for the purposes of packaging. The patterns specified in the\n`exclude` field identify a set of files that are not included, and the\npatterns in `include` specify files that are explicitly included.\n\nThe patterns should be [gitignore](https://git-scm.com/docs/gitignore)-style patterns. Briefly:\n\n- `foo` matches any file or directory with the name `foo` anywhere in the\n package. This is equivalent to the pattern `**/foo`.\n- `/foo` matches any file or directory with the name `foo` only in the root of\n the package.\n- `foo/` matches any *directory* with the name `foo` anywhere in the package.\n- Common glob patterns like `*`, `?`, and `[]` are supported:\n - `*` matches zero or more characters except `/`. For example, `*.html`\n matches any file or directory with the `.html` extension anywhere in the\n package.\n - `?` matches any character except `/`. For example, `foo?` matches `food`,\n but not `foo`.\n - `[]` allows for matching a range of characters. For example, `[ab]`\n matches either `a` or `b`. `[a-z]` matches letters a through z.\n- `**/` prefix matches in any directory. For example, `**/foo/bar` matches the\n file or directory `bar` anywhere that is directly under directory `foo`.\n- `/**` suffix matches everything inside. For example, `foo/**` matches all\n files inside directory `foo`, including all files in subdirectories below\n `foo`.\n- `/**/` matches zero or more directories. For example, `a/**/b` matches\n `a/b`, `a/x/b`, `a/x/y/b`, and so on.\n- `!` prefix negates a pattern. For example, a pattern of `src/**.rs` and\n `!foo.rs` would match all files with the `.rs` extension inside the `src`\n directory, except for any file named `foo.rs`.\n\nIf git is being used for a package, the `exclude` field will be seeded with\nthe `gitignore` settings from the repository.\n\n```toml\n[package]\n# ...\nexclude = [\"build/**/*.o\", \"doc/**/*.html\"]\n```\n\n```toml\n[package]\n# ...\ninclude = [\"src/**/*\", \"Cargo.toml\"]\n```\n\nThe options are mutually exclusive: setting `include` will override an\n`exclude`. Note that `include` must be an exhaustive list of files as otherwise\nnecessary source files may not be included. The package's `Cargo.toml` is\nautomatically included.\n\nThe include/exclude list is also used for change tracking in some situations.\nFor targets built with `rustdoc`, it is used to determine the list of files to\ntrack to determine if the target should be rebuilt. If the package has a\n[build script](https://doc.rust-lang.org/cargo/reference/build-scripts.html) that does not emit any `rerun-if-*` directives, then the\ninclude/exclude list is used for tracking if the build script should be re-run\nif any of those files change.", - "type": "array", - "items": { - "description": "You can explicitly specify that a set of file patterns should be ignored or\nincluded for the purposes of packaging. The patterns specified in the\n`exclude` field identify a set of files that are not included, and the\npatterns in `include` specify files that are explicitly included.\n\nThe patterns should be [gitignore](https://git-scm.com/docs/gitignore)-style patterns. Briefly:\n\n- `foo` matches any file or directory with the name `foo` anywhere in the\n package. This is equivalent to the pattern `**/foo`.\n- `/foo` matches any file or directory with the name `foo` only in the root of\n the package.\n- `foo/` matches any *directory* with the name `foo` anywhere in the package.\n- Common glob patterns like `*`, `?`, and `[]` are supported:\n - `*` matches zero or more characters except `/`. For example, `*.html`\n matches any file or directory with the `.html` extension anywhere in the\n package.\n - `?` matches any character except `/`. For example, `foo?` matches `food`,\n but not `foo`.\n - `[]` allows for matching a range of characters. For example, `[ab]`\n matches either `a` or `b`. `[a-z]` matches letters a through z.\n- `**/` prefix matches in any directory. For example, `**/foo/bar` matches the\n file or directory `bar` anywhere that is directly under directory `foo`.\n- `/**` suffix matches everything inside. For example, `foo/**` matches all\n files inside directory `foo`, including all files in subdirectories below\n `foo`.\n- `/**/` matches zero or more directories. For example, `a/**/b` matches\n `a/b`, `a/x/b`, `a/x/y/b`, and so on.\n- `!` prefix negates a pattern. For example, a pattern of `src/**.rs` and\n `!foo.rs` would match all files with the `.rs` extension inside the `src`\n directory, except for any file named `foo.rs`.\n\nIf git is being used for a package, the `exclude` field will be seeded with\nthe `gitignore` settings from the repository.\n\n```toml\n[package]\n# ...\nexclude = [\"build/**/*.o\", \"doc/**/*.html\"]\n```\n\n```toml\n[package]\n# ...\ninclude = [\"src/**/*\", \"Cargo.toml\"]\n```\n\nThe options are mutually exclusive: setting `include` will override an\n`exclude`. Note that `include` must be an exhaustive list of files as otherwise\nnecessary source files may not be included. The package's `Cargo.toml` is\nautomatically included.\n\nThe include/exclude list is also used for change tracking in some situations.\nFor targets built with `rustdoc`, it is used to determine the list of files to\ntrack to determine if the target should be rebuilt. If the package has a\n[build script](https://doc.rust-lang.org/cargo/reference/build-scripts.html) that does not emit any `rerun-if-*` directives, then the\ninclude/exclude list is used for tracking if the build script should be re-run\nif any of those files change.", - "type": "string", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-exclude-and-include-fields" - } - } - }, - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-exclude-and-include-fields" + "anyOf": [ + { + "$ref": "#/definitions/Exclude" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" } - } + ] }, "homepage": { - "description": "The `homepage` field should be a URL to a site that is the home page for your\npackage.\n\n```toml\n[package]\n# ...\nhomepage = \"https://serde.rs/\"\n```", - "type": "string", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-homepage-field" + "anyOf": [ + { + "$ref": "#/definitions/Homepage" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" } - } + ] }, "im-a-teapot": { "description": "Sets whether the current package is a teapot or something else that is not capable of brewing tea.", @@ -640,58 +408,44 @@ } }, "include": { - "description": "You can explicitly specify that a set of file patterns should be ignored or\nincluded for the purposes of packaging. The patterns specified in the\n`exclude` field identify a set of files that are not included, and the\npatterns in `include` specify files that are explicitly included.\n\nThe patterns should be [gitignore](https://git-scm.com/docs/gitignore)-style patterns. Briefly:\n\n- `foo` matches any file or directory with the name `foo` anywhere in the\n package. This is equivalent to the pattern `**/foo`.\n- `/foo` matches any file or directory with the name `foo` only in the root of\n the package.\n- `foo/` matches any *directory* with the name `foo` anywhere in the package.\n- Common glob patterns like `*`, `?`, and `[]` are supported:\n - `*` matches zero or more characters except `/`. For example, `*.html`\n matches any file or directory with the `.html` extension anywhere in the\n package.\n - `?` matches any character except `/`. For example, `foo?` matches `food`,\n but not `foo`.\n - `[]` allows for matching a range of characters. For example, `[ab]`\n matches either `a` or `b`. `[a-z]` matches letters a through z.\n- `**/` prefix matches in any directory. For example, `**/foo/bar` matches the\n file or directory `bar` anywhere that is directly under directory `foo`.\n- `/**` suffix matches everything inside. For example, `foo/**` matches all\n files inside directory `foo`, including all files in subdirectories below\n `foo`.\n- `/**/` matches zero or more directories. For example, `a/**/b` matches\n `a/b`, `a/x/b`, `a/x/y/b`, and so on.\n- `!` prefix negates a pattern. For example, a pattern of `src/**.rs` and\n `!foo.rs` would match all files with the `.rs` extension inside the `src`\n directory, except for any file named `foo.rs`.\n\nIf git is being used for a package, the `exclude` field will be seeded with\nthe `gitignore` settings from the repository.\n\n```toml\n[package]\n# ...\nexclude = [\"build/**/*.o\", \"doc/**/*.html\"]\n```\n\n```toml\n[package]\n# ...\ninclude = [\"src/**/*\", \"Cargo.toml\"]\n```\n\nThe options are mutually exclusive: setting `include` will override an\n`exclude`. Note that `include` must be an exhaustive list of files as otherwise\nnecessary source files may not be included. The package's `Cargo.toml` is\nautomatically included.\n\nThe include/exclude list is also used for change tracking in some situations.\nFor targets built with `rustdoc`, it is used to determine the list of files to\ntrack to determine if the target should be rebuilt. If the package has a\n[build script](https://doc.rust-lang.org/cargo/reference/build-scripts.html) that does not emit any `rerun-if-*` directives, then the\ninclude/exclude list is used for tracking if the build script should be re-run\nif any of those files change.", - "type": "array", - "items": { - "description": "You can explicitly specify that a set of file patterns should be ignored or\nincluded for the purposes of packaging. The patterns specified in the\n`exclude` field identify a set of files that are not included, and the\npatterns in `include` specify files that are explicitly included.\n\nThe patterns should be [gitignore](https://git-scm.com/docs/gitignore)-style patterns. Briefly:\n\n- `foo` matches any file or directory with the name `foo` anywhere in the\n package. This is equivalent to the pattern `**/foo`.\n- `/foo` matches any file or directory with the name `foo` only in the root of\n the package.\n- `foo/` matches any *directory* with the name `foo` anywhere in the package.\n- Common glob patterns like `*`, `?`, and `[]` are supported:\n - `*` matches zero or more characters except `/`. For example, `*.html`\n matches any file or directory with the `.html` extension anywhere in the\n package.\n - `?` matches any character except `/`. For example, `foo?` matches `food`,\n but not `foo`.\n - `[]` allows for matching a range of characters. For example, `[ab]`\n matches either `a` or `b`. `[a-z]` matches letters a through z.\n- `**/` prefix matches in any directory. For example, `**/foo/bar` matches the\n file or directory `bar` anywhere that is directly under directory `foo`.\n- `/**` suffix matches everything inside. For example, `foo/**` matches all\n files inside directory `foo`, including all files in subdirectories below\n `foo`.\n- `/**/` matches zero or more directories. For example, `a/**/b` matches\n `a/b`, `a/x/b`, `a/x/y/b`, and so on.\n- `!` prefix negates a pattern. For example, a pattern of `src/**.rs` and\n `!foo.rs` would match all files with the `.rs` extension inside the `src`\n directory, except for any file named `foo.rs`.\n\nIf git is being used for a package, the `exclude` field will be seeded with\nthe `gitignore` settings from the repository.\n\n```toml\n[package]\n# ...\nexclude = [\"build/**/*.o\", \"doc/**/*.html\"]\n```\n\n```toml\n[package]\n# ...\ninclude = [\"src/**/*\", \"Cargo.toml\"]\n```\n\nThe options are mutually exclusive: setting `include` will override an\n`exclude`. Note that `include` must be an exhaustive list of files as otherwise\nnecessary source files may not be included. The package's `Cargo.toml` is\nautomatically included.\n\nThe include/exclude list is also used for change tracking in some situations.\nFor targets built with `rustdoc`, it is used to determine the list of files to\ntrack to determine if the target should be rebuilt. If the package has a\n[build script](https://doc.rust-lang.org/cargo/reference/build-scripts.html) that does not emit any `rerun-if-*` directives, then the\ninclude/exclude list is used for tracking if the build script should be re-run\nif any of those files change.", - "type": "string", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-exclude-and-include-fields" - } - } - }, - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-exclude-and-include-fields" + "anyOf": [ + { + "$ref": "#/definitions/Include" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" } - } + ] }, "keywords": { - "description": "The `keywords` field is an array of strings that describe this package. This\ncan help when searching for the package on a registry, and you may choose any\nwords that would help someone find this crate.\n\n```toml\n[package]\n# ...\nkeywords = [\"gamedev\", \"graphics\"]\n```\n\n> **Note**: [crates.io](https://crates.io) has a maximum of 5 keywords. Each keyword must be\n> ASCII text, start with a letter, and only contain letters, numbers, `_` or\n> `-`, and have at most 20 characters.", - "type": "array", - "items": { - "description": "The `keywords` field is an array of strings that describe this package. This\ncan help when searching for the package on a registry, and you may choose any\nwords that would help someone find this crate.\n\n```toml\n[package]\n# ...\nkeywords = [\"gamedev\", \"graphics\"]\n```\n\n> **Note**: [crates.io](https://crates.io) has a maximum of 5 keywords. Each keyword must be\n> ASCII text, start with a letter, and only contain letters, numbers, `_` or\n> `-`, and have at most 20 characters.", - "type": "string", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-keywords-field" - } - } - }, - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-keywords-field" + "anyOf": [ + { + "$ref": "#/definitions/Keywords" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" } - } + ] }, "license": { - "description": "The `license` field contains the name of the software license that the package\nis released under.\n\n[crates.io](https://crates.io/) interprets the `license` field as an [SPDX 2.1 license\nexpression](https://spdx.org/spdx-specification-21-web-version#h.jxpfx0ykyb60). The name must be a known license\nfrom the [SPDX license list 3.6](https://github.com/spdx/license-list-data/tree/v3.6). Parentheses are not\ncurrently supported. See the [SPDX site](https://spdx.org/license-list) for more information.\n\nSPDX license expressions support AND and OR operators to combine multiple\nlicenses.\n\n```toml\n[package]\n# ...\nlicense = \"MIT OR Apache-2.0\"\n```\n\nUsing `OR` indicates the user may choose either license. Using `AND` indicates\nthe user must comply with both licenses simultaneously. The `WITH` operator\nindicates a license with a special exception. Some examples:\n\n* `MIT OR Apache-2.0`\n* `LGPL-2.1 AND MIT AND BSD-2-Clause`\n* `GPL-2.0+ WITH Bison-exception-2.2`\n\nIf a package is using a nonstandard license, then the `license-file` field may\nbe specified in lieu of the `license` field.", - "type": "string", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-license-and-license-file-fields" + "anyOf": [ + { + "$ref": "#/definitions/License" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" } - } + ] }, "license-file": { - "description": "The `license-file` field contains the path to a file\ncontaining the text of the license (relative to this `Cargo.toml`).\n\n```toml\n[package]\n# ...\nlicense-file = \"LICENSE.txt\"\n```\n\n> **Note**: [crates.io](https://crates.io) requires either `license` or `license-file` to be set.", - "type": "string", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-license-and-license-file-fields" + "anyOf": [ + { + "$ref": "#/definitions/LicenseFile" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" } - } + ] }, "links": { "description": "The `links` field specifies the name of a native library that is being linked\nto. More information can be found in the [`links`](https://doc.rust-lang.org/cargo/reference/build-scripts.html#the-links-manifest-key) section of the build\nscript guide.\n\n```toml\n[package]\n# ...\nlinks = \"foo\"\n```", @@ -712,6 +466,11 @@ "description": "Cargo by default will warn about unused keys in `Cargo.toml` to assist in\ndetecting typos and such. The `package.metadata` table, however, is completely\nignored by Cargo and will not be warned about. This section can be used for\ntools which would like to store package configuration in `Cargo.toml`. For\nexample:\n\n```toml\n[package]\nname = \"...\"\n# ...\n\n# Metadata used when generating an Android APK, for example.\n[package.metadata.android]\npackage-name = \"my-awesome-android-app\"\nassets = \"path/to/static\"\n```\n", "type": "object", "additionalProperties": true, + "properties": { + "playdate": { + "$ref": "#/definitions/PlaydateMetadata" + } + }, "x-taplo": { "links": { "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-metadata-table" @@ -734,7 +493,14 @@ } }, "publish": { - "$ref": "#/definitions/Publish" + "anyOf": [ + { + "$ref": "#/definitions/Publish" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" + } + ] }, "publish-lockfile": { "type": "boolean", @@ -743,37 +509,47 @@ } }, "readme": { - "description": "The `readme` field should be the path to a file in the package root (relative\nto this `Cargo.toml`) that contains general information about the package.\nThis file will be transferred to the registry when you publish. [crates.io](https://crates.io)\nwill interpret it as Markdown and render it on the crate's page.\n\n```toml\n[package]\n# ...\nreadme = \"README.md\"\n```\n\nIf no value is specified for this field, and a file named `README.md`,\n`README.txt` or `README` exists in the package root, then the name of that\nfile will be used. You can suppress this behavior by setting this field to\n`false`. If the field is set to `true`, a default value of `README.md` will\nbe assumed.\n", - "$ref": "#/definitions/Readme", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-readme-field" + "anyOf": [ + { + "$ref": "#/definitions/Readme" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" } - } + ] }, "repository": { - "description": "The `repository` field should be a URL to the source repository for your\npackage.\n\n```toml\n[package]\n# ...\nrepository = \"https://github.com/rust-lang/cargo/\"\n```", - "type": "string", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-repository-field" + "anyOf": [ + { + "$ref": "#/definitions/Repository" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" } - } + ] }, "resolver": { "$ref": "#/definitions/Resolver" }, "rust-version": { - "description": "The `rust-version` field is an optional key that tells cargo what version of the\nRust language and compiler your package can be compiled with. If the currently\nselected version of the Rust compiler is older than the stated version, cargo\nwill exit with an error, telling the user what version is required.\n\nThe first version of Cargo that supports this field was released with Rust 1.56.0.\nIn older releases, the field will be ignored, and Cargo will display a warning.\n\n```toml\n[package]\n# ...\nrust-version = \"1.56\"\n```\n\nThe Rust version must be a bare version number with two or three components; it\ncannot include semver operators or pre-release identifiers. Compiler pre-release\nidentifiers such as -nightly will be ignored while checking the Rust version.\nThe `rust-version` must be equal to or newer than the version that first\nintroduced the configured `edition`.\n\nThe `rust-version` may be ignored using the `--ignore-rust-version` option.\n\nSetting the `rust-version` key in `[package]` will affect all targets/crates in\nthe package, including test suites, benchmarks, binaries, examples, etc.", - "type": "string", - "x-taplo": { - "links": { - "key": "https://doc.rust-lang.org/nightly/cargo/reference/manifest.html#the-rust-version-field" + "anyOf": [ + { + "$ref": "#/definitions/RustVersion" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" } - } + ] }, "version": { - "$ref": "#/definitions/SemVer" + "anyOf": [ + { + "$ref": "#/definitions/SemVer" + }, + { + "$ref": "#/definitions/WorkspaceInheritance" + } + ] }, "workspace": { "description": "The `workspace` field can be used to configure the workspace that this package\nwill be a member of. If not specified this will be inferred as the first\nCargo.toml with `[workspace]` upwards in the filesystem. Setting this is\nuseful if the member is not inside a subdirectory of the workspace root.\n\n```toml\n[package]\n# ...\nworkspace = \"path/to/workspace/root\"\n```\n\nThis field cannot be specified if the manifest already has a `[workspace]`\ntable defined. That is, a crate cannot both be a root crate in a workspace\n(contain `[workspace]`) and also be a member crate of another workspace\n(contain `package.workspace`).\n\nFor more information, see the [workspaces chapter](https://doc.rust-lang.org/cargo/reference/workspaces.html).", @@ -900,6 +676,7 @@ "$ref": "#/definitions/Profile" }, { + "type": "object", "properties": { "build-override": { "$ref": "#/definitions/Profile" @@ -916,7 +693,7 @@ "description": "The `codegen-units` setting controls the [`-C codegen-units` flag](https://doc.rust-lang.org/rustc/codegen-options/index.html#codegen-units) which\ncontrols how many \"code generation units\" a crate will be split into. More\ncode generation units allows more of a crate to be processed in parallel\npossibly reducing compile time, but may produce slower code.\n\nThis option takes an integer greater than 0.\n\nThe default is 256 for [incremental](https://doc.rust-lang.org/cargo/reference/profiles.html#incremental) builds, and 16 for\nnon-incremental builds.", "type": "integer", "format": "uint32", - "minimum": 0.0, + "minimum": 0, "x-taplo": { "links": { "key": "https://doc.rust-lang.org/cargo/reference/profiles.html#codegen-units" @@ -1085,7 +862,7 @@ }, "SemVer": { "title": "Semantic Version", - "description": "Cargo bakes in the concept of [Semantic Versioning](https://semver.org/), so make sure you follow some basic rules:\n\n* Before you reach 1.0.0, anything goes, but if you make breaking changes,\n increment the minor version. In Rust, breaking changes include adding fields to\n structs or variants to enums.\n* After 1.0.0, only make breaking changes when you increment the major version.\n Don’t break the build.\n* After 1.0.0, don’t add any new public API (no new `pub` anything) in patch-level\n versions. Always increment the minor version if you add any new `pub` structs,\n traits, fields, types, functions, methods or anything else.\n* Use version numbers with three numeric parts such as 1.0.0 rather than 1.0.", + "description": "Cargo bakes in the concept of [Semantic Versioning](https://semver.org/), so make sure you follow some basic rules:\n\n* Before you reach 1.0.0, anything goes, but if you make breaking changes,\n increment the minor version. In Rust, breaking changes include adding fields to\n structs or variants to enums.\n* After 1.0.0, only make breaking changes when you increment the major version.\n Don't break the build.\n* After 1.0.0, don't add any new public API (no new `pub` anything) in patch-level\n versions. Always increment the minor version if you add any new `pub` structs,\n traits, fields, types, functions, methods or anything else.\n* Use version numbers with three numeric parts such as 1.0.0 rather than 1.0.", "default": "0.1.0", "type": "string", "format": "semver", @@ -1297,6 +1074,18 @@ } } }, + "dependencies": { + "description": "The `workspace.dependencies` table is where you define dependencies to be\ninherited by members of a workspace.\n\nSpecifying a workspace dependency is similar to [package dependencies](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html) except:\n- Dependencies from this table cannot be declared as `optional`\n- [`features`][features] declared in this table are additive with the `features` from `[dependencies]`\n\nYou can then [inherit the workspace dependency as a package dependency](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#inheriting-a-dependency-from-a-workspace)\n\nExample:\n```toml\n# [PROJECT_DIR]/Cargo.toml\n[workspace]\nmembers = [\"bar\"]\n\n[workspace.dependencies]\ncc = \"1.0.73\"\nrand = \"0.8.5\"\nregex = { version = \"1.6.0\", default-features = false, features = [\"std\"] }\n```\n\n```toml\n# [PROJECT_DIR]/bar/Cargo.toml\n[package]\nname = \"bar\"\nversion = \"0.2.0\"\n\n[dependencies]\nregex = { workspace = true, features = [\"unicode\"] }\n\n[build-dependencies]\ncc.workspace = true\n\n[dev-dependencies]\nrand.workspace = true\n```", + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/Dependency" + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/workspaces.html#the-workspace-section" + } + } + }, "exclude": { "description": "The `exclude` key can be used to prevent paths from being included in a\nworkspace. This can be useful if some path dependencies aren't desired to be\nin the workspace at all, or using a glob pattern and you want to remove a\ndirectory.", "type": "array", @@ -1345,6 +1134,65 @@ }, "resolver": { "$ref": "#/definitions/Resolver" + }, + "package": { + "description": "The `workspace.package` table is where you define keys that can be\ninherited by members of a workspace. These keys can be inherited by\ndefining them in the member package with `{key}.workspace = true`.\n\nKeys that are supported:\n\n| | |\n|----------------|-----------------|\n| `authors` | `categories` |\n| `description` | `documentation` |\n| `edition` | `exclude` |\n| `homepage` | `include` |\n| `keywords` | `license` |\n| `license-file` | `publish` |\n| `readme` | `repository` |\n| `rust-version` | `version` |\n\n- `license-file` and `readme` are relative to the workspace root\n- `include` and `exclude` are relative to your package root\n\nExample:\n```toml\n# [PROJECT_DIR]/Cargo.toml\n[workspace]\nmembers = [\"bar\"]\n\n[workspace.package]\nversion = \"1.2.3\"\nauthors = [\"Nice Folks\"]\ndescription = \"A short description of my package\"\ndocumentation = \"https://example.com/bar\"\n```\n\n```toml\n# [PROJECT_DIR]/bar/Cargo.toml\n[package]\nname = \"bar\"\nversion.workspace = true\nauthors.workspace = true\ndescription.workspace = true\ndocumentation.workspace = true\n```", + "type": "object", + "properties": { + "authors": { + "$ref": "#/definitions/Authors" + }, + "categories": { + "$ref": "#/definitions/Categories" + }, + "description": { + "$ref": "#/definitions/Description" + }, + "documentation": { + "$ref": "#/definitions/Documentation" + }, + "edition": { + "$ref": "#/definitions/Edition" + }, + "exclude": { + "$ref": "#/definitions/Exclude" + }, + "homepage": { + "$ref": "#/definitions/Homepage" + }, + "include": { + "$ref": "#/definitions/Include" + }, + "keywords": { + "$ref": "#/definitions/Keywords" + }, + "license": { + "$ref": "#/definitions/License" + }, + "license-file": { + "$ref": "#/definitions/LicenseFile" + }, + "publish": { + "$ref": "#/definitions/Publish" + }, + "readme": { + "$ref": "#/definitions/Readme" + }, + "repository": { + "$ref": "#/definitions/Repository" + }, + "rust-version": { + "$ref": "#/definitions/RustVersion" + }, + "version": { + "$ref": "#/definitions/SemVer" + } + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/workspaces.html#the-package-table" + } + } } }, "x-taplo": { @@ -1352,6 +1200,647 @@ "key": "https://doc.rust-lang.org/cargo/reference/workspaces.html" } } - } + }, + "Authors": { + "title": "Authors", + "description": "The `authors` field lists people or organizations that are considered the\n\"authors\" of the package. The exact meaning is open to interpretation — it may\nlist the original or primary authors, current maintainers, or owners of the\npackage. These names will be listed on the crate's page on\n[crates.io](https://crates.io). An optional email address may be included within angled\nbrackets at the end of each author.\n\n> **Note**: [crates.io](https://crates.io) requires at least one author to be listed.", + "type": "array", + "items": { + "description": "The `authors` field lists people or organizations that are considered the\n\"authors\" of the package. The exact meaning is open to interpretation — it may\nlist the original or primary authors, current maintainers, or owners of the\npackage. These names will be listed on the crate's page on\n[crates.io](https://crates.io). An optional email address may be included within angled\nbrackets at the end of each author.\n\n> **Note**: [crates.io](https://crates.io) requires at least one author to be listed.", + "type": "string", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-authors-field" + } + } + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-authors-field" + } + } + }, + "Categories": { + "title": "Categories", + "description": "The `categories` field is an array of strings of the categories this package\nbelongs to.\n\n```toml\ncategories = [\"command-line-utilities\", \"development-tools::cargo-plugins\"]\n```\n\n> **Note**: [crates.io](https://crates.io) has a maximum of 5 categories. Each category should\n> match one of the strings available at https://crates.io/category_slugs, and\n> must match exactly.", + "type": "array", + "items": { + "description": "The `categories` field is an array of strings of the categories this package\nbelongs to.\n\n```toml\ncategories = [\"command-line-utilities\", \"development-tools::cargo-plugins\"]\n```\n\n> **Note**: [crates.io](https://crates.io) has a maximum of 5 categories. Each category should\n> match one of the strings available at https://crates.io/category_slugs, and\n> must match exactly.", + "type": "string", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-categories-field" + } + } + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-categories-field" + } + } + }, + "Description": { + "title": "Description", + "description": "The description is a short blurb about the package. [crates.io](https://crates.io) will display\nthis with your package. This should be plain text (not Markdown).\n\n```toml\n[package]\n# ...\ndescription = \"A short description of my package\"\n```\n\n> **Note**: [crates.io](https://crates.io) requires the `description` to be set.", + "type": "string", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-description-field" + } + } + }, + "Documentation": { + "title": "Documentation", + "description": "\nThe `documentation` field specifies a URL to a website hosting the crate's\ndocumentation. If no URL is specified in the manifest file, [crates.io](https://crates.io) will\nautomatically link your crate to the corresponding [docs.rs](https://docs.rs) page.\n\n```toml\n[package]\n# ...\ndocumentation = \"https://docs.rs/bitflags\"\n```\n", + "type": "string", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-documentation-field" + } + } + }, + "Exclude": { + "title": "Exclude", + "description": "You can explicitly specify that a set of file patterns should be ignored or\nincluded for the purposes of packaging. The patterns specified in the\n`exclude` field identify a set of files that are not included, and the\npatterns in `include` specify files that are explicitly included.\n\nThe patterns should be [gitignore](https://git-scm.com/docs/gitignore)-style patterns. Briefly:\n\n- `foo` matches any file or directory with the name `foo` anywhere in the\n package. This is equivalent to the pattern `**/foo`.\n- `/foo` matches any file or directory with the name `foo` only in the root of\n the package.\n- `foo/` matches any *directory* with the name `foo` anywhere in the package.\n- Common glob patterns like `*`, `?`, and `[]` are supported:\n - `*` matches zero or more characters except `/`. For example, `*.html`\n matches any file or directory with the `.html` extension anywhere in the\n package.\n - `?` matches any character except `/`. For example, `foo?` matches `food`,\n but not `foo`.\n - `[]` allows for matching a range of characters. For example, `[ab]`\n matches either `a` or `b`. `[a-z]` matches letters a through z.\n- `**/` prefix matches in any directory. For example, `**/foo/bar` matches the\n file or directory `bar` anywhere that is directly under directory `foo`.\n- `/**` suffix matches everything inside. For example, `foo/**` matches all\n files inside directory `foo`, including all files in subdirectories below\n `foo`.\n- `/**/` matches zero or more directories. For example, `a/**/b` matches\n `a/b`, `a/x/b`, `a/x/y/b`, and so on.\n- `!` prefix negates a pattern. For example, a pattern of `src/**.rs` and\n `!foo.rs` would match all files with the `.rs` extension inside the `src`\n directory, except for any file named `foo.rs`.\n\nIf git is being used for a package, the `exclude` field will be seeded with\nthe `gitignore` settings from the repository.\n\n```toml\n[package]\n# ...\nexclude = [\"build/**/*.o\", \"doc/**/*.html\"]\n```\n\n```toml\n[package]\n# ...\ninclude = [\"src/**/*\", \"Cargo.toml\"]\n```\n\nThe options are mutually exclusive: setting `include` will override an\n`exclude`. Note that `include` must be an exhaustive list of files as otherwise\nnecessary source files may not be included. The package's `Cargo.toml` is\nautomatically included.\n\nThe include/exclude list is also used for change tracking in some situations.\nFor targets built with `rustdoc`, it is used to determine the list of files to\ntrack to determine if the target should be rebuilt. If the package has a\n[build script](https://doc.rust-lang.org/cargo/reference/build-scripts.html) that does not emit any `rerun-if-*` directives, then the\ninclude/exclude list is used for tracking if the build script should be re-run\nif any of those files change.", + "type": "array", + "items": { + "description": "You can explicitly specify that a set of file patterns should be ignored or\nincluded for the purposes of packaging. The patterns specified in the\n`exclude` field identify a set of files that are not included, and the\npatterns in `include` specify files that are explicitly included.\n\nThe patterns should be [gitignore](https://git-scm.com/docs/gitignore)-style patterns. Briefly:\n\n- `foo` matches any file or directory with the name `foo` anywhere in the\n package. This is equivalent to the pattern `**/foo`.\n- `/foo` matches any file or directory with the name `foo` only in the root of\n the package.\n- `foo/` matches any *directory* with the name `foo` anywhere in the package.\n- Common glob patterns like `*`, `?`, and `[]` are supported:\n - `*` matches zero or more characters except `/`. For example, `*.html`\n matches any file or directory with the `.html` extension anywhere in the\n package.\n - `?` matches any character except `/`. For example, `foo?` matches `food`,\n but not `foo`.\n - `[]` allows for matching a range of characters. For example, `[ab]`\n matches either `a` or `b`. `[a-z]` matches letters a through z.\n- `**/` prefix matches in any directory. For example, `**/foo/bar` matches the\n file or directory `bar` anywhere that is directly under directory `foo`.\n- `/**` suffix matches everything inside. For example, `foo/**` matches all\n files inside directory `foo`, including all files in subdirectories below\n `foo`.\n- `/**/` matches zero or more directories. For example, `a/**/b` matches\n `a/b`, `a/x/b`, `a/x/y/b`, and so on.\n- `!` prefix negates a pattern. For example, a pattern of `src/**.rs` and\n `!foo.rs` would match all files with the `.rs` extension inside the `src`\n directory, except for any file named `foo.rs`.\n\nIf git is being used for a package, the `exclude` field will be seeded with\nthe `gitignore` settings from the repository.\n\n```toml\n[package]\n# ...\nexclude = [\"build/**/*.o\", \"doc/**/*.html\"]\n```\n\n```toml\n[package]\n# ...\ninclude = [\"src/**/*\", \"Cargo.toml\"]\n```\n\nThe options are mutually exclusive: setting `include` will override an\n`exclude`. Note that `include` must be an exhaustive list of files as otherwise\nnecessary source files may not be included. The package's `Cargo.toml` is\nautomatically included.\n\nThe include/exclude list is also used for change tracking in some situations.\nFor targets built with `rustdoc`, it is used to determine the list of files to\ntrack to determine if the target should be rebuilt. If the package has a\n[build script](https://doc.rust-lang.org/cargo/reference/build-scripts.html) that does not emit any `rerun-if-*` directives, then the\ninclude/exclude list is used for tracking if the build script should be re-run\nif any of those files change.", + "type": "string", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-exclude-and-include-fields" + } + } + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-exclude-and-include-fields" + } + } + }, + "Homepage": { + "title": "Homepage", + "description": "The `homepage` field should be a URL to a site that is the home page for your\npackage.\n\n```toml\n[package]\n# ...\nhomepage = \"https://serde.rs/\"\n```", + "type": "string", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-homepage-field" + } + } + }, + "Include": { + "description": "You can explicitly specify that a set of file patterns should be ignored or\nincluded for the purposes of packaging. The patterns specified in the\n`exclude` field identify a set of files that are not included, and the\npatterns in `include` specify files that are explicitly included.\n\nThe patterns should be [gitignore](https://git-scm.com/docs/gitignore)-style patterns. Briefly:\n\n- `foo` matches any file or directory with the name `foo` anywhere in the\n package. This is equivalent to the pattern `**/foo`.\n- `/foo` matches any file or directory with the name `foo` only in the root of\n the package.\n- `foo/` matches any *directory* with the name `foo` anywhere in the package.\n- Common glob patterns like `*`, `?`, and `[]` are supported:\n - `*` matches zero or more characters except `/`. For example, `*.html`\n matches any file or directory with the `.html` extension anywhere in the\n package.\n - `?` matches any character except `/`. For example, `foo?` matches `food`,\n but not `foo`.\n - `[]` allows for matching a range of characters. For example, `[ab]`\n matches either `a` or `b`. `[a-z]` matches letters a through z.\n- `**/` prefix matches in any directory. For example, `**/foo/bar` matches the\n file or directory `bar` anywhere that is directly under directory `foo`.\n- `/**` suffix matches everything inside. For example, `foo/**` matches all\n files inside directory `foo`, including all files in subdirectories below\n `foo`.\n- `/**/` matches zero or more directories. For example, `a/**/b` matches\n `a/b`, `a/x/b`, `a/x/y/b`, and so on.\n- `!` prefix negates a pattern. For example, a pattern of `src/**.rs` and\n `!foo.rs` would match all files with the `.rs` extension inside the `src`\n directory, except for any file named `foo.rs`.\n\nIf git is being used for a package, the `exclude` field will be seeded with\nthe `gitignore` settings from the repository.\n\n```toml\n[package]\n# ...\nexclude = [\"build/**/*.o\", \"doc/**/*.html\"]\n```\n\n```toml\n[package]\n# ...\ninclude = [\"src/**/*\", \"Cargo.toml\"]\n```\n\nThe options are mutually exclusive: setting `include` will override an\n`exclude`. Note that `include` must be an exhaustive list of files as otherwise\nnecessary source files may not be included. The package's `Cargo.toml` is\nautomatically included.\n\nThe include/exclude list is also used for change tracking in some situations.\nFor targets built with `rustdoc`, it is used to determine the list of files to\ntrack to determine if the target should be rebuilt. If the package has a\n[build script](https://doc.rust-lang.org/cargo/reference/build-scripts.html) that does not emit any `rerun-if-*` directives, then the\ninclude/exclude list is used for tracking if the build script should be re-run\nif any of those files change.", + "type": "array", + "items": { + "description": "You can explicitly specify that a set of file patterns should be ignored or\nincluded for the purposes of packaging. The patterns specified in the\n`exclude` field identify a set of files that are not included, and the\npatterns in `include` specify files that are explicitly included.\n\nThe patterns should be [gitignore](https://git-scm.com/docs/gitignore)-style patterns. Briefly:\n\n- `foo` matches any file or directory with the name `foo` anywhere in the\n package. This is equivalent to the pattern `**/foo`.\n- `/foo` matches any file or directory with the name `foo` only in the root of\n the package.\n- `foo/` matches any *directory* with the name `foo` anywhere in the package.\n- Common glob patterns like `*`, `?`, and `[]` are supported:\n - `*` matches zero or more characters except `/`. For example, `*.html`\n matches any file or directory with the `.html` extension anywhere in the\n package.\n - `?` matches any character except `/`. For example, `foo?` matches `food`,\n but not `foo`.\n - `[]` allows for matching a range of characters. For example, `[ab]`\n matches either `a` or `b`. `[a-z]` matches letters a through z.\n- `**/` prefix matches in any directory. For example, `**/foo/bar` matches the\n file or directory `bar` anywhere that is directly under directory `foo`.\n- `/**` suffix matches everything inside. For example, `foo/**` matches all\n files inside directory `foo`, including all files in subdirectories below\n `foo`.\n- `/**/` matches zero or more directories. For example, `a/**/b` matches\n `a/b`, `a/x/b`, `a/x/y/b`, and so on.\n- `!` prefix negates a pattern. For example, a pattern of `src/**.rs` and\n `!foo.rs` would match all files with the `.rs` extension inside the `src`\n directory, except for any file named `foo.rs`.\n\nIf git is being used for a package, the `exclude` field will be seeded with\nthe `gitignore` settings from the repository.\n\n```toml\n[package]\n# ...\nexclude = [\"build/**/*.o\", \"doc/**/*.html\"]\n```\n\n```toml\n[package]\n# ...\ninclude = [\"src/**/*\", \"Cargo.toml\"]\n```\n\nThe options are mutually exclusive: setting `include` will override an\n`exclude`. Note that `include` must be an exhaustive list of files as otherwise\nnecessary source files may not be included. The package's `Cargo.toml` is\nautomatically included.\n\nThe include/exclude list is also used for change tracking in some situations.\nFor targets built with `rustdoc`, it is used to determine the list of files to\ntrack to determine if the target should be rebuilt. If the package has a\n[build script](https://doc.rust-lang.org/cargo/reference/build-scripts.html) that does not emit any `rerun-if-*` directives, then the\ninclude/exclude list is used for tracking if the build script should be re-run\nif any of those files change.", + "type": "string", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-exclude-and-include-fields" + } + } + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-exclude-and-include-fields" + } + } + }, + "Keywords": { + "title": "Keywords", + "description": "The `keywords` field is an array of strings that describe this package. This\ncan help when searching for the package on a registry, and you may choose any\nwords that would help someone find this crate.\n\n```toml\n[package]\n# ...\nkeywords = [\"gamedev\", \"graphics\"]\n```\n\n> **Note**: [crates.io](https://crates.io) has a maximum of 5 keywords. Each keyword must be\n> ASCII text, start with a letter, and only contain letters, numbers, `_` or\n> `-`, and have at most 20 characters.", + "type": "array", + "items": { + "description": "The `keywords` field is an array of strings that describe this package. This\ncan help when searching for the package on a registry, and you may choose any\nwords that would help someone find this crate.\n\n```toml\n[package]\n# ...\nkeywords = [\"gamedev\", \"graphics\"]\n```\n\n> **Note**: [crates.io](https://crates.io) has a maximum of 5 keywords. Each keyword must be\n> ASCII text, start with a letter, and only contain letters, numbers, `_` or\n> `-`, and have at most 20 characters.", + "type": "string", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-keywords-field" + } + } + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-keywords-field" + } + } + }, + "License": { + "title": "License", + "description": "The `license` field contains the name of the software license that the package\nis released under.\n\n[crates.io](https://crates.io/) interprets the `license` field as an [SPDX 2.1 license\nexpression](https://spdx.org/spdx-specification-21-web-version#h.jxpfx0ykyb60). The name must be a known license\nfrom the [SPDX license list 3.6](https://github.com/spdx/license-list-data/tree/v3.6). Parentheses are not\ncurrently supported. See the [SPDX site](https://spdx.org/license-list) for more information.\n\nSPDX license expressions support AND and OR operators to combine multiple\nlicenses.\n\n```toml\n[package]\n# ...\nlicense = \"MIT OR Apache-2.0\"\n```\n\nUsing `OR` indicates the user may choose either license. Using `AND` indicates\nthe user must comply with both licenses simultaneously. The `WITH` operator\nindicates a license with a special exception. Some examples:\n\n* `MIT OR Apache-2.0`\n* `LGPL-2.1 AND MIT AND BSD-2-Clause`\n* `GPL-2.0+ WITH Bison-exception-2.2`\n\nIf a package is using a nonstandard license, then the `license-file` field may\nbe specified in lieu of the `license` field.", + "type": "string", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-license-and-license-file-fields" + } + } + }, + "LicenseFile": { + "title": "LicenseFile", + "description": "The `license-file` field contains the path to a file\ncontaining the text of the license (relative to this `Cargo.toml`).\n\n```toml\n[package]\n# ...\nlicense-file = \"LICENSE.txt\"\n```\n\n> **Note**: [crates.io](https://crates.io) requires either `license` or `license-file` to be set.", + "type": "string", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-license-and-license-file-fields" + } + } + }, + "Repository": { + "title": "Repository", + "description": "The `repository` field should be a URL to the source repository for your\npackage.\n\n```toml\n[package]\n# ...\nrepository = \"https://github.com/rust-lang/cargo/\"\n```", + "type": "string", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-repository-field" + } + } + }, + "RustVersion": { + "title": "RustVersion", + "description": "The `rust-version` field is an optional key that tells cargo what version of the\nRust language and compiler your package can be compiled with. If the currently\nselected version of the Rust compiler is older than the stated version, cargo\nwill exit with an error, telling the user what version is required.\n\nThe first version of Cargo that supports this field was released with Rust 1.56.0.\nIn older releases, the field will be ignored, and Cargo will display a warning.\n\n```toml\n[package]\n# ...\nrust-version = \"1.56\"\n```\n\nThe Rust version must be a bare version number with two or three components; it\ncannot include semver operators or pre-release identifiers. Compiler pre-release\nidentifiers such as -nightly will be ignored while checking the Rust version.\nThe `rust-version` must be equal to or newer than the version that first\nintroduced the configured `edition`.\n\nThe `rust-version` may be ignored using the `--ignore-rust-version` option.\n\nSetting the `rust-version` key in `[package]` will affect all targets/crates in\nthe package, including test suites, benchmarks, binaries, examples, etc.", + "type": "string", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-rust-version-field" + } + } + }, + "WorkspaceInheritance": { + "title": "Workspace", + "description": "The `workspace` field allow keys to be inherited by defining them in the member package with `{key}.workspace = true`", + "type": "object", + "properties": { + "workspace": { + "type": "boolean", + "enum": [true] + } + } + }, + "PlaydateMetadata": { + "title": "Playdate Package Metadata", + "description": "Metadata and build configuration.", + "type": "object", + "required": ["bundle-id"], + "properties": { + "bundle-id": { + "type": "string", + "description": "A unique identifier for your game, in reverse DNS notation.", + "x-taplo": { + "links": { + "key": "https://sdk.play.date/#pdxinfo" + } + } + }, + "name": { + "type": "string", + "description": "A game version number, formatted any way you wish, that is displayed to players. It is not used to compute when updates should occur.", + "x-taplo": { + "links": { + "key": "https://sdk.play.date/#pdxinfo" + } + } + }, + "author": { + "type": "string", + "x-taplo": { + "links": { + "key": "https://sdk.play.date/#pdxinfo" + } + } + }, + "description": { + "type": "string", + "x-taplo": { + "links": { + "key": "https://sdk.play.date/#pdxinfo" + } + } + }, + "version": { + "type": "string", + "x-taplo": { + "links": { + "key": "https://sdk.play.date/#pdxinfo" + } + } + }, + "build-number": { + "type": "integer", + "exclusiveMinimum": 0, + "x-taplo": { + "links": { + "key": "https://sdk.play.date/#pdxinfo" + } + }, + "description": "A monotonically-increasing integer value used to indicate a unique version of your game. This can be set using an automated build process like Continuous Integration to avoid having to set the value by hand.\n\nFor sideloaded games, buildNumber is required and is used to determine when a newer version is available to download." + }, + "image-path": { + "type": "string", + "x-taplo": { + "links": { + "key": "https://sdk.play.date/#pdxinfo" + } + }, + "description": "A directory of images that will be used by the launcher.\n\nMore in [official documentation](https://sdk.play.date/#pdxinfo)." + }, + "launch-sound-path": { + "type": "string", + "x-taplo": { + "links": { + "key": "https://sdk.play.date/#pdxinfo" + } + }, + "description": "Should point to the path of a short audio file to be played as the game launch animation is taking place.\n\nMore in [official documentation](https://sdk.play.date/#pdxinfo)." + }, + "content-warning": { + "type": "string", + "x-taplo": { + "links": { + "key": "https://sdk.play.date/#pdxinfo" + } + }, + "description": "Optional. A content warning that displays when the user launches your game for the first time. The user will have the option of backing out and not launching your game if they choose." + }, + "content-warning2": { + "type": "string", + "x-taplo": { + "links": { + "key": "https://sdk.play.date/#pdxinfo" + } + }, + "description": "Optional. A second content warning that displays on a second screen when the user launches your game for the first time. The user will have the option of backing out and not launching your game if they choose.\n\nNote: `content-warning2` will only display if a `content-warning` attribute is also specified.\n\nThe string displayed on the content warning screen can only be so long before it will be truncated with an \"…\" character. Be sure to keep this in mind when designing your `content-warning` and `content-warning2` text." + }, + "assets": { + "anyOf": [ + { + "$ref": "#/definitions/PlaydateMetadataAssetsMap" + }, + { + "$ref": "#/definitions/PlaydateMetadataAssetsArray" + } + ] + }, + "dev-assets": { + "anyOf": [ + { + "$ref": "#/definitions/PlaydateMetadataAssetsMap" + }, + { + "$ref": "#/definitions/PlaydateMetadataAssetsArray" + } + ] + }, + "options": { + "$ref": "#/definitions/PlaydateMetadataOptions" + }, + "support": { + "type": "object", + "properties": {}, + "additionalProperties": true + } + }, + "additionalProperties": false, + "x-taplo": { + "initKeys": [ + "bundle-id", + "name", + "description", + "author", + "image-path", + "launch-sound-path" + ], + "links": { + "key": "https://sdk.play.date/#pdxinfo" + } + }, + "x-taplo-info": { + "authors": ["Alex Koz. (https://github.com/boozook)"] + }, + "x-for": "playdate" + }, + "PlaydateMetadataAssetsArray": { + "type": "array", + "title": "Assets list", + "description": "List of paths to include.", + "uniqueItems": true, + "items": { + "title": "Path", + "description": "Path to include.", + "type": "string" + }, + "x-taplo": { + "links": { + "key": "https://github.com/boozook/playdate/blob/main/support/build/README.md#assets-list" + } + } + }, + "PlaydateMetadataAssetsMap": { + "type": "object", + "title": "Assets rules", + "description": "Rules used to resolve paths to include.", + "properties": { + "options": { + "$ref": "#/definitions/PlaydateMetadataAssetsOptions" + } + }, + "additionalProperties": { + "anyOf": [ + { + "type": "string", + "title": "Path", + "description": "Path of files to include. Can be absolute, relative to the crate root, or/and glob.\n\nLeft hand is where to put files, path in the resulting package.\n\nRight hand is a path or pattern to match files to include." + }, + { + "type": "boolean", + "title": "Include", + "description": "Include or exclude the file or glob-pattern." + } + ] + }, + "x-taplo": { + "links": { + "key": "https://github.com/boozook/playdate/blob/main/support/build/README.md#assets-table" + } + } + }, + "PlaydateMetadataAssetsOptions": { + "type": "object", + "title": "Assets Configuration", + "description": "Options for assets paths resolution and how to build assets collection", + "additionalProperties": false, + "properties": { + "overwrite": { + "type": "boolean", + "description": "Allow overwriting existing files." + }, + "follow-symlinks": { + "type": "boolean" + }, + "method": { + "type": "string", + "enum": ["copy", "link"] + }, + "dependencies": { + "type": "boolean", + "description": "Allow build assets for dependencies." + } + }, + "x-taplo": { + "links": { + "key": "https://github.com/boozook/playdate/blob/main/support/build/README.md#assets-options" + } + } + }, + "PlaydateMetadataOptions": { + "type": "object", + "title": "Configuration", + "description": "Package build options.", + "additionalProperties": true, + "properties": { + "assets": { + "$ref": "#/definitions/PlaydateMetadataAssetsOptions" + } + }, + "x-taplo": { + "links": { + "key": "https://github.com/boozook/playdate/blob/main/support/build/README.md#options" + } + } + } + }, + "description": "A schema for Cargo.toml.", + "properties": { + "badges": { + "description": "[crates.io](https://crates.io) can display various badges for build status, test coverage, etc. for\neach crate. All badges are optional.\n\n- The badges pertaining to build status that are currently available are\n Appveyor, CircleCI, Cirrus CI, GitLab, Azure DevOps, Travis CI and Bitbucket\n Pipelines.\n- Available badges pertaining to code test coverage are Codecov and Coveralls.\n- There are also maintenance-related badges based on isitmaintained.com\n which state the issue resolution time, percent of open issues, and future\n maintenance intentions.\n\nMost badge specifications require a `repository` key. It is expected to be in\n`user/repo` format.\n\n```toml\n[badges]\n\n# Appveyor: `repository` is required. `branch` is optional; default is `master`\n# `service` is optional; valid values are `github` (default), `bitbucket`, and\n# `gitlab`; `id` is optional; you can specify the appveyor project id if you\n# want to use that instead. `project_name` is optional; use when the repository\n# name differs from the appveyor project name.\nappveyor = { repository = \"...\", branch = \"master\", service = \"github\" }\n\n# Circle CI: `repository` is required. `branch` is optional; default is `master`\ncircle-ci = { repository = \"...\", branch = \"master\" }\n\n# Cirrus CI: `repository` is required. `branch` is optional; default is `master`\ncirrus-ci = { repository = \"...\", branch = \"master\" }\n\n# GitLab: `repository` is required. `branch` is optional; default is `master`\ngitlab = { repository = \"...\", branch = \"master\" }\n\n# Azure DevOps: `project` is required. `pipeline` is required. `build` is optional; default is `1`\n# Note: project = `organization/project`, pipeline = `name_of_pipeline`, build = `definitionId`\nazure-devops = { project = \"...\", pipeline = \"...\", build=\"2\" }\n\n# Travis CI: `repository` in format \"/\" is required.\n# `branch` is optional; default is `master`\ntravis-ci = { repository = \"...\", branch = \"master\" }\n\n# Bitbucket Pipelines: `repository` is required. `branch` is required\nbitbucket-pipelines = { repository = \"...\", branch = \"master\" }\n\n# Codecov: `repository` is required. `branch` is optional; default is `master`\n# `service` is optional; valid values are `github` (default), `bitbucket`, and\n# `gitlab`.\ncodecov = { repository = \"...\", branch = \"master\", service = \"github\" }\n\n# Coveralls: `repository` is required. `branch` is optional; default is `master`\n# `service` is optional; valid values are `github` (default) and `bitbucket`.\ncoveralls = { repository = \"...\", branch = \"master\", service = \"github\" }\n\n# Is it maintained resolution time: `repository` is required.\nis-it-maintained-issue-resolution = { repository = \"...\" }\n\n# Is it maintained percentage of open issues: `repository` is required.\nis-it-maintained-open-issues = { repository = \"...\" }\n\n# Maintenance: `status` is required. Available options are:\n# - `actively-developed`: New features are being added and bugs are being fixed.\n# - `passively-maintained`: There are no plans for new features, but the maintainer intends to\n# respond to issues that get filed.\n# - `as-is`: The crate is feature complete, the maintainer does not intend to continue working on\n# it or providing support, but it works for the purposes it was designed for.\n# - `experimental`: The author wants to share it with the community but is not intending to meet\n# anyone's particular use case.\n# - `looking-for-maintainer`: The current maintainer would like to transfer the crate to someone\n# else.\n# - `deprecated`: The maintainer does not recommend using this crate (the description of the crate\n# can describe why, there could be a better solution available or there could be problems with\n# the crate that the author does not want to fix).\n# - `none`: Displays no badge on crates.io, since the maintainer has not chosen to specify\n# their intentions, potential crate users will need to investigate on their own.\nmaintenance = { status = \"...\" }\n```", + "type": "object", + "additionalProperties": { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/manifest.html#the-badges-section" + } + } + }, + "bench": { + "description": "Benchmarks provide a way to test the performance of your code using the\n[`cargo bench`](https://doc.rust-lang.org/cargo/commands/cargo-bench.html) command. They follow the same structure as [tests](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#tests),\nwith each benchmark function annotated with the `#[bench]` attribute.\nSimilarly to tests:\n\n* Benchmarks are placed in the [`benches` directory](https://doc.rust-lang.org/cargo/guide/project-layout.html).\n* Benchmark functions defined in libraries and binaries have access to the\n *private* API within the target they are defined in. Benchmarks in the\n `benches` directory may use the *public* API.\n* [The `bench` field](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-bench-field) can be used to define which targets\n are benchmarked by default.\n* [The `harness` field](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-harness-field) can be used to disable the\n built-in harness.\n\n> **Note**: The [`#[bench]`\n> attribute](https://doc.rust-lang.org/unstable-book/library-features/test.html) is currently\n> unstable and only available on the [nightly channel](https://doc.rust-lang.org/book/appendix-07-nightly-rust.html). There are some\n> packages available on [crates.io](https://crates.io/keywords/benchmark) that\n> may help with running benchmarks on the stable channel, such as\n> [Criterion](https://crates.io/crates/criterion).", + "type": "array", + "items": { + "$ref": "#/definitions/Target", + "description": "Benchmarks provide a way to test the performance of your code using the\n[`cargo bench`](https://doc.rust-lang.org/cargo/commands/cargo-bench.html) command. They follow the same structure as [tests](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#tests),\nwith each benchmark function annotated with the `#[bench]` attribute.\nSimilarly to tests:\n\n* Benchmarks are placed in the [`benches` directory](https://doc.rust-lang.org/cargo/guide/project-layout.html).\n* Benchmark functions defined in libraries and binaries have access to the\n *private* API within the target they are defined in. Benchmarks in the\n `benches` directory may use the *public* API.\n* [The `bench` field](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-bench-field) can be used to define which targets\n are benchmarked by default.\n* [The `harness` field](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-harness-field) can be used to disable the\n built-in harness.\n\n> **Note**: The [`#[bench]`\n> attribute](https://doc.rust-lang.org/unstable-book/library-features/test.html) is currently\n> unstable and only available on the [nightly channel](https://doc.rust-lang.org/book/appendix-07-nightly-rust.html). There are some\n> packages available on [crates.io](https://crates.io/keywords/benchmark) that\n> may help with running benchmarks on the stable channel, such as\n> [Criterion](https://crates.io/crates/criterion).", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#benchmarks" + } + } + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#benchmarks" + } + } + }, + "bin": { + "description": "Binary targets are executable programs that can be run after being compiled.\nThe default binary filename is `src/main.rs`, which defaults to the name of\nthe package. Additional binaries are stored in the [`src/bin/`\ndirectory](https://doc.rust-lang.org/cargo/guide/project-layout.html). The settings for each binary can be [customized](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#configuring-a-target) in the `[[bin]]` tables in `Cargo.toml`.\n\nBinaries can use the public API of the package's library. They are also linked\nwith the [`[dependencies]`](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html) defined in `Cargo.toml`.\n\nYou can run individual binaries with the [`cargo run`](https://doc.rust-lang.org/cargo/commands/cargo-run.html) command with the `--bin\n` option. [`cargo install`](https://doc.rust-lang.org/cargo/commands/cargo-install.html) can be used to copy the executable to a\ncommon location.\n\n```toml\n# Example of customizing binaries in Cargo.toml.\n[[bin]]\nname = \"cool-tool\"\ntest = false\nbench = false\n\n[[bin]]\nname = \"frobnicator\"\nrequired-features = [\"frobnicate\"]\n```", + "type": "array", + "items": { + "$ref": "#/definitions/Target", + "description": "Binary targets are executable programs that can be run after being compiled.\nThe default binary filename is `src/main.rs`, which defaults to the name of\nthe package. Additional binaries are stored in the [`src/bin/`\ndirectory](https://doc.rust-lang.org/cargo/guide/project-layout.html). The settings for each binary can be [customized](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#configuring-a-target) in the `[[bin]]` tables in `Cargo.toml`.\n\nBinaries can use the public API of the package's library. They are also linked\nwith the [`[dependencies]`](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html) defined in `Cargo.toml`.\n\nYou can run individual binaries with the [`cargo run`](https://doc.rust-lang.org/cargo/commands/cargo-run.html) command with the `--bin\n` option. [`cargo install`](https://doc.rust-lang.org/cargo/commands/cargo-install.html) can be used to copy the executable to a\ncommon location.\n\n```toml\n# Example of customizing binaries in Cargo.toml.\n[[bin]]\nname = \"cool-tool\"\ntest = false\nbench = false\n\n[[bin]]\nname = \"frobnicator\"\nrequired-features = [\"frobnicate\"]\n```", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#binaries" + } + } + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#binaries" + } + } + }, + "build-dependencies": { + "description": "You can depend on other Cargo-based crates for use in your build scripts.\nDependencies are declared through the `build-dependencies` section of the\nmanifest:\n\n```toml\n[build-dependencies]\ncc = \"1.0.3\"\n```\n\nThe build script **does not** have access to the dependencies listed\nin the `dependencies` or `dev-dependencies` section. Build\ndependencies will likewise not be available to the package itself\nunless listed under the `dependencies` section as well. A package\nitself and its build script are built separately, so their\ndependencies need not coincide. Cargo is kept simpler and cleaner by\nusing independent dependencies for independent purposes.", + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/Dependency" + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#build-dependencies" + }, + "plugins": ["crates"], + "crates": { + "schemas": "dependencies" + } + } + }, + "build_dependencies": { + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/Dependency" + }, + "x-taplo": { + "hidden": true + } + }, + "cargo-features": { + "type": "array", + "items": { + "type": "string" + } + }, + "dependencies": { + "description": "Cargo is configured to look for dependencies on [crates.io](https://crates.io) by default. Only\nthe name and a version string are required in this case. In [the cargo\nguide](https://doc.rust-lang.org/cargo/guide/index.html), we specified a dependency on the `time` crate:\n\n```toml\n[dependencies]\ntime = \"0.1.12\"\n```\n\nThe string `\"0.1.12\"` is a [semver](https://github.com/steveklabnik/semver#requirements) version requirement. Since this\nstring does not have any operators in it, it is interpreted the same way as\nif we had specified `\"^0.1.12\"`, which is called a caret requirement.\n\nA dependency can also be defined by a table with additional options:\n\n```toml\n[dependencies]\ntime = { path = \"../time\", version = \"0.1.12\" }\n```", + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/Dependency" + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html" + } + } + }, + "dev-dependencies": { + "description": "The format of `[dev-dependencies]` is equivalent to `[dependencies]`:\n\n```toml\n[dev-dependencies]\ntempdir = \"0.3\"\n```\n\nDev-dependencies are not used when compiling\na package for building, but are used for compiling tests, examples, and\nbenchmarks.\n\nThese dependencies are *not* propagated to other packages which depend on this\npackage.\n\nYou can also have target-specific development dependencies by using\n`dev-dependencies` in the target section header instead of `dependencies`. For\nexample:\n\n```toml\n[target.'cfg(unix)'.dev-dependencies]\nmio = \"0.0.1\"\n```\n\n> **Note**: When a package is published, only dev-dependencies that specify a\n> `version` will be included in the published crate. For most use cases,\n> dev-dependencies are not needed when published, though some users (like OS\n> packagers) may want to run tests within a crate, so providing a `version` if\n> possible can still be beneficial.\n", + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/Dependency" + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#development-dependencies" + }, + "plugins": ["crates"], + "crates": { + "schemas": "dependencies" + } + } + }, + "dev_dependencies": { + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/Dependency" + }, + "x-taplo": { + "hidden": true + } + }, + "example": { + "description": "Files located under the [examples directory](https://doc.rust-lang.org/cargo/guide/project-layout.html) are example uses of the functionality provided by the library. When compiled, they are placed in the[ target/debug/examples directory](https://doc.rust-lang.org/cargo/guide/build-cache.html).\n\nExamples can use the public API of the package's library. They are also linked with the [dependencies](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html) and [dev-dependencies](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#development-dependencies) defined in Cargo.toml.\n\nBy default, examples are executable binaries (with a `main()` function). You\ncan specify the [`crate-type` field](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-crate-type-field) to make an example\nbe compiled as a library:\n\n```toml\n[[example]]\nname = \"foo\"\ncrate-type = [\"staticlib\"]\n```\n\nYou can run individual executable examples with the [`cargo run`](https://doc.rust-lang.org/cargo/commands/cargo-run.html) command with\nthe `--example ` option. Library examples can be built with\n[`cargo build`](https://doc.rust-lang.org/cargo/commands/cargo-build.html) with the `--example ` option. [`cargo install`](https://doc.rust-lang.org/cargo/commands/cargo-install.html)\nwith the `--example ` option can be used to copy executable\nbinaries to a common location. Examples are compiled by [`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html) by\ndefault to protect them from bit-rotting. Set [the `test`\nfield](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-test-field) to `true` if you have `#[test]` functions in the\nexample that you want to run with [`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html).\n", + "type": "array", + "items": { + "$ref": "#/definitions/Target", + "description": "Files located under the [examples directory](https://doc.rust-lang.org/cargo/guide/project-layout.html) are example uses of the functionality provided by the library. When compiled, they are placed in the[ target/debug/examples directory](https://doc.rust-lang.org/cargo/guide/build-cache.html).\n\nExamples can use the public API of the package's library. They are also linked with the [dependencies](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html) and [dev-dependencies](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#development-dependencies) defined in Cargo.toml.\n\nBy default, examples are executable binaries (with a `main()` function). You\ncan specify the [`crate-type` field](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-crate-type-field) to make an example\nbe compiled as a library:\n\n```toml\n[[example]]\nname = \"foo\"\ncrate-type = [\"staticlib\"]\n```\n\nYou can run individual executable examples with the [`cargo run`](https://doc.rust-lang.org/cargo/commands/cargo-run.html) command with\nthe `--example ` option. Library examples can be built with\n[`cargo build`](https://doc.rust-lang.org/cargo/commands/cargo-build.html) with the `--example ` option. [`cargo install`](https://doc.rust-lang.org/cargo/commands/cargo-install.html)\nwith the `--example ` option can be used to copy executable\nbinaries to a common location. Examples are compiled by [`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html) by\ndefault to protect them from bit-rotting. Set [the `test`\nfield](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-test-field) to `true` if you have `#[test]` functions in the\nexample that you want to run with [`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html).\n", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#examples" + } + } + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#examples" + } + } + }, + "features": { + "description": "Cargo supports features to allow expression of:\n\n* conditional compilation options (usable through `cfg` attributes);\n* optional dependencies, which enhance a package, but are not required; and\n* clusters of optional dependencies, such as `postgres-all`, that would include the\n `postgres` package, the `postgres-macros` package, and possibly other packages\n (such as development-time mocking libraries, debugging tools, etc.).\n\nA feature of a package is either an optional dependency, or a set of other\nfeatures.\n", + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "type": "string" + } + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/features.html" + } + } + }, + "lib": { + "$ref": "#/definitions/Target", + "x-taplo": { + "docs": { + "main": "The library target defines a \"library\" that can be used and linked by other\nlibraries and executables. The filename defaults to `src/lib.rs`, and the name\nof the library defaults to the name of the package. A package can have only\none library. The settings for the library can be [customized](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#configuring-a-target) in the `[lib]`\ntable in `Cargo.toml`.\n\n```toml\n# Example of customizing the library in Cargo.toml.\n[lib]\ncrate-type = [\"cdylib\"]\nbench = false\n```\n" + }, + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#library" + } + } + }, + "package": { + "$ref": "#/definitions/Package" + }, + "patch": { + "description": "The `[patch]` section of `Cargo.toml` can be used to override dependencies\nwith other copies. The syntax is similar to the\n[`[dependencies]`](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html) section.\n\n", + "type": "object", + "additionalProperties": { + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/Dependency" + } + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/overriding-dependencies.html#the-patch-section" + } + } + }, + "profile": { + "$ref": "#/definitions/Profiles" + }, + "project": { + "$ref": "#/definitions/Package", + "x-taplo": { + "hidden": true + } + }, + "replace": { + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/Dependency" + }, + "x-taplo": { + "hidden": true + } + }, + "target": { + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/Platform" + } + }, + "test": { + "description": "Files located under the [`tests` directory](https://doc.rust-lang.org/cargo/guide/project-layout.html) are integration\ntests. When you run [`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html), Cargo will compile each of these files as\na separate crate, and execute them.\n\nIntegration tests can use the public API of the package's library. They are\nalso linked with the [`[dependencies]`](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html) and\n[`[dev-dependencies]`](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#development-dependencies) defined in `Cargo.toml`.\n\nIf you want to share code among multiple integration tests, you can place it\nin a separate module such as `tests/common/mod.rs` and then put `mod common;`\nin each test to import it.\n\nEach integration test results in a separate executable binary, and [`cargo\ntest`](https://doc.rust-lang.org/cargo/commands/cargo-test.html) will run them serially. In some cases this can be inefficient, as it\ncan take longer to compile, and may not make full use of multiple CPUs when\nrunning the tests. If you have a lot of integration tests, you may want to\nconsider creating a single integration test, and split the tests into multiple\nmodules. The libtest harness will automatically find all of the `#[test]`\nannotated functions and run them in parallel. You can pass module names to\n[`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html) to only run the tests within that module.\n\nBinary targets are automatically built if there is an integration test. This\nallows an integration test to execute the binary to exercise and test its\nbehavior. The `CARGO_BIN_EXE_` [environment variable](https://doc.rust-lang.org/cargo/reference/environment-variables.html#environment-variables-cargo-sets-for-crates) is set when the\nintegration test is built so that it can use the [`env` macro](https://doc.rust-lang.org/std/macro.env.html) to locate the\nexecutable.", + "type": "array", + "items": { + "$ref": "#/definitions/Target", + "description": "Files located under the [`tests` directory](https://doc.rust-lang.org/cargo/guide/project-layout.html) are integration\ntests. When you run [`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html), Cargo will compile each of these files as\na separate crate, and execute them.\n\nIntegration tests can use the public API of the package's library. They are\nalso linked with the [`[dependencies]`](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html) and\n[`[dev-dependencies]`](https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#development-dependencies) defined in `Cargo.toml`.\n\nIf you want to share code among multiple integration tests, you can place it\nin a separate module such as `tests/common/mod.rs` and then put `mod common;`\nin each test to import it.\n\nEach integration test results in a separate executable binary, and [`cargo\ntest`](https://doc.rust-lang.org/cargo/commands/cargo-test.html) will run them serially. In some cases this can be inefficient, as it\ncan take longer to compile, and may not make full use of multiple CPUs when\nrunning the tests. If you have a lot of integration tests, you may want to\nconsider creating a single integration test, and split the tests into multiple\nmodules. The libtest harness will automatically find all of the `#[test]`\nannotated functions and run them in parallel. You can pass module names to\n[`cargo test`](https://doc.rust-lang.org/cargo/commands/cargo-test.html) to only run the tests within that module.\n\nBinary targets are automatically built if there is an integration test. This\nallows an integration test to execute the binary to exercise and test its\nbehavior. The `CARGO_BIN_EXE_` [environment variable](https://doc.rust-lang.org/cargo/reference/environment-variables.html#environment-variables-cargo-sets-for-crates) is set when the\nintegration test is built so that it can use the [`env` macro](https://doc.rust-lang.org/std/macro.env.html) to locate the\nexecutable.", + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#integration-tests" + } + } + }, + "x-taplo": { + "links": { + "key": "https://doc.rust-lang.org/cargo/reference/cargo-targets.html#integration-tests" + } + } + }, + "workspace": { + "$ref": "#/definitions/Workspace" + } + }, + "title": "Cargo.toml", + "type": "object", + "x-taplo-info": { + "authors": ["tamasfe (https://github.com/tamasfe)"], + "patterns": ["^(.*(/|\\\\)Cargo\\.toml|Cargo\\.toml)$"] } } diff --git a/site/site/public/schemas/dein.toml.json b/site/site/public/schemas/dein.toml.json index 40326276c..f1c6c87e5 100644 --- a/site/site/public/schemas/dein.toml.json +++ b/site/site/public/schemas/dein.toml.json @@ -1,102 +1,12 @@ { "$schema": "http://json-schema.org/draft-07/schema#", - "title": "dein.vim", - "type": "object", - "description": "A schema for config of dein.vim (https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L963)", - "x-taplo-info": { - "authors": [ - "kkiyama117 (https://github.com/kkiyama117)", - "raa0121 (https://github.com/raa0121)", - "Hibiki (https://github.com/4513ECHO)" - ], - "version": "0.1.0", - "patterns": [ - "^(.*(/|\\\\)\\.*dein.*\\.toml|\\.*dein.*\\.toml)$" - ] - }, - "required": [ - "plugins" - ], + "$id": "https://json.schemastore.org/dein.json", "additionalProperties": false, - "properties": { - "plugins": { - "title": "Definition properties table for installing a vim plugin", - "description": "Definition properties table for installing a vim plugin.\nIt is converted to |dein#add()|.", - "type": "array", - "uniqueness": true, - "additionalItems": false, - "items": { - "$ref": "#/definitions/Plugin" - }, - "x-taplo": { - "links": { - "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L1068" - } - } - }, - "ftplugin": { - "title": "ftplugin definition", - "description": "'_' key is executed after all ftplugin.\n'{filetype}' key is executed {filetype} ftplugin.\n You can define multiple filetypes by '{filetype1}_{filetype2}' key.", - "type": "object", - "additionalProperties": false, - "properties": { - "_": { - "title": "all filetypes", - "description": "'_' key is executed after all ftplugin.", - "type": "string", - "x-taplo": { - "links": { - "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L1056" - } - } - } - }, - "patternProperties": { - "^[0-9a-zA-Z].+$": { - "title": "filetype", - "description": "'{filetype}' key is executed {filetype} ftplugin.\nYou can define multiple filetypes by '{filetype1}_{filetype2}' key.\n'b:undo_ftplugin' is defined automatically.", - "type": "string" - } - }, - "x-taplo": { - "links": { - "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L1054" - } - } - }, - "hook_add": { - "title": "hook_add definition", - "description": "It is the global |dein-options-hook_add|.\nIt is executed in |dein#end()|.", - "type": "string", - "x-taplo": { - "links": { - "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L1063" - } - } - }, - "multiple_plugins": { - "title": "It is converted to |dein-toml-hook_add|", - "description": "It is converted to |dein-toml-hook_add|\n\"plugins\" key is needed.", - "type": "array", - "uniqueness": true, - "additionalItems": false, - "items": { - "$ref": "#/definitions/MultiplePlugin" - }, - "x-taplo": { - "links": { - "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L1073" - } - } - } - }, "definitions": { "Plugin": { "title": "Pattern for a definition of vim plugin", "type": "object", - "required": [ - "repo" - ], + "required": ["repo"], "additionalProperties": false, "properties": { "repo": { @@ -138,8 +48,8 @@ } }, "depends": { - "description": "Specify a list of plugins a plugin depends on. List items are '{plugin-name}'. Those specified in the list are NOT installed automatically. Note: The loading order is not guaranteed in non lazy plugins.", "$ref": "#/definitions/ArrayOrString", + "description": "Specify a list of plugins a plugin depends on. List items are '{plugin-name}'. Those specified in the list are NOT installed automatically. Note: The loading order is not guaranteed in non lazy plugins.", "x-taplo": { "links": { "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L719" @@ -147,8 +57,8 @@ } }, "frozen": { - "description": "If set to v:true, dein doesn't update it automatically. It is useful for outdated plugins that can no longer be updated.", "$ref": "#/definitions/Boolean", + "description": "If set to v:true, dein doesn't update it automatically. It is useful for outdated plugins that can no longer be updated.", "x-taplo": { "links": { "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L726" @@ -186,10 +96,16 @@ }, "if": { "description": "If set to v:false, dein doesn't register the plugin, i.e. the plugin will be disabled. If it is String, dein will eval it. If you don't set it, dein will register (enable) the plugin", - "type": [ - "boolean", - "integer", - "string" + "anyOf": [ + { + "type": "boolean" + }, + { + "type": "integer" + }, + { + "type": "string" + } ], "x-taplo": { "links": { @@ -199,9 +115,13 @@ }, "lazy": { "description": "If set to v:true, dein doesn't add the path to 'runtimepath' automatically. If you don't set it, dein will set it automatically when the conditions are met. Note: You should not specify the plugins which have no 'plugin/' directory as lazy load plugins. It is meaningless and just increases the overhead. You can get the no meaning lazy plugins by |dein#check_lazy_plugins()|.", - "type": [ - "boolean", - "integer" + "anyOf": [ + { + "type": "boolean" + }, + { + "type": "integer" + } ], "x-taplo": { "links": { @@ -210,8 +130,8 @@ } }, "merged": { - "description": "If set to v:false, dein doesn't merge the plugin directory. It is useful for the plugin files conflicts.", "$ref": "#/definitions/Boolean", + "description": "If set to v:false, dein doesn't merge the plugin directory. It is useful for the plugin files conflicts.", "x-taplo": { "links": { "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L757" @@ -219,8 +139,8 @@ } }, "merge_ftdetect": { - "description": "If set to v:true, dein merge the plugin \"ftdetect\" directory. It is useful to enable file detection when lazy loaded plugin. Note: It does not work if ftdetect script depends on lazy plugin functions.", "$ref": "#/definitions/Boolean", + "description": "If set to v:true, dein merge the plugin \"ftdetect\" directory. It is useful to enable file detection when lazy loaded plugin. Note: It does not work if ftdetect script depends on lazy plugin functions.", "x-taplo": { "links": { "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L764" @@ -246,8 +166,8 @@ } }, "on_cmd": { - "description": "If it is matched to the executed command, dein will call |dein#source()|.", "$ref": "#/definitions/ArrayOrString", + "description": "If it is matched to the executed command, dein will call |dein#source()|.", "x-taplo": { "links": { "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L796" @@ -255,8 +175,8 @@ } }, "on_event": { - "description": "dein will call |dein#source()| on the events.", "$ref": "#/definitions/ArrayOrString", + "description": "dein will call |dein#source()| on the events.", "x-taplo": { "links": { "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L801" @@ -264,8 +184,8 @@ } }, "on_func": { - "description": "If it is matched to the called function, dein will call |dein#source()|.", "$ref": "#/definitions/ArrayOrString", + "description": "If it is matched to the called function, dein will call |dein#source()|.", "x-taplo": { "links": { "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L805" @@ -273,8 +193,8 @@ } }, "on_ft": { - "description": "If it is matched to 'filetype', dein will call |dein#source()|.", "$ref": "#/definitions/ArrayOrString", + "description": "If it is matched to 'filetype', dein will call |dein#source()|.", "x-taplo": { "links": { "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L811" @@ -291,8 +211,8 @@ } }, "on_lua": { - "description": "If it is matched to the required lua module root, dein will call |dein#source()|. Note: It is for neovim only. Note: It does not work for neovim standard modules.", "$ref": "#/definitions/ArrayOrString", + "description": "If it is matched to the required lua module root, dein will call |dein#source()|. Note: It is for neovim only. Note: It does not work for neovim standard modules.", "x-taplo": { "links": { "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L829" @@ -319,8 +239,8 @@ } }, "on_path": { - "description": "If set to '.*', dein will call |dein#source()| on editing allfiles. Otherwise, dein will call |dein#source()| if thebuffer name is matched to the string pattern.Note: It is useful for explorer behavior plugins.", "$ref": "#/definitions/ArrayOrString", + "description": "If set to '.*', dein will call |dein#source()| on editing allfiles. Otherwise, dein will call |dein#source()| if thebuffer name is matched to the string pattern.Note: It is useful for explorer behavior plugins.", "x-taplo": { "links": { "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L874" @@ -328,8 +248,8 @@ } }, "on_source": { - "description": "If set to '.*', dein will call |dein#source()| on editing allfiles. Otherwise, dein will call |dein#source()| if thebuffer name is matched to the string pattern.Note: It is useful for explorer behavior plugins. ", "$ref": "#/definitions/ArrayOrString", + "description": "If set to '.*', dein will call |dein#source()| on editing allfiles. Otherwise, dein will call |dein#source()| if thebuffer name is matched to the string pattern.Note: It is useful for explorer behavior plugins. ", "x-taplo": { "links": { "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L881" @@ -337,8 +257,8 @@ } }, "overwrite": { - "description": "If set to v:true, dein overwrite existing plugin config when |dein#add()|.", "$ref": "#/definitions/Boolean", + "description": "If set to v:true, dein overwrite existing plugin config when |dein#add()|.", "x-taplo": { "links": { "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L886" @@ -376,12 +296,7 @@ "script_type": { "description": "Specify the script type. It is useful for non-official categorized plugins. For example: 'indent', 'plugin', 'ftplugin', ... Note: You must not specify it for categorized plugins.", "type": "string", - "enum": [ - "indent", - "plugin", - "colors", - "ftplugin" - ], + "enum": ["indent", "plugin", "colors", "ftplugin"], "x-taplo": { "links": { "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L919" @@ -398,8 +313,8 @@ } }, "trusted": { - "description": "If set to v:true, dein will load the plugin in 'sudo' mode. If you don't set it, dein won't load it.", "$ref": "#/definitions/Boolean", + "description": "If set to v:true, dein will load the plugin in 'sudo' mode. If you don't set it, dein won't load it.", "x-taplo": { "links": { "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L940" @@ -409,11 +324,7 @@ "type": { "description": "Specify the repository type. If it is omitted, a guess is made based on {repository}.", "type": "string", - "enum": [ - "none", - "raw", - "git" - ], + "enum": ["none", "raw", "git"], "x-taplo": { "docs": { "enumValues": [ @@ -485,27 +396,42 @@ "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L1021" } } + }, + "lua_add": { + "description": "Lua language string hook instead of Vim script.\nIt is converted to \"hook_add\" key.", + "type": "string", + "x-taplo": { + "links": { + "key": "https://github.com/Shougo/dein.vim/blob/4a888738849c67294ab6264d8776324c7d6b2441/doc/dein.txt#L1084" + } + } + }, + "lua_source": { + "description": "Lua language string hook instead of Vim script.\nIt is converted to \"hook_source\" key.", + "type": "string", + "x-taplo": { + "links": { + "key": "https://github.com/Shougo/dein.vim/blob/4a888738849c67294ab6264d8776324c7d6b2441/doc/dein.txt#L1084" + } + } } }, "x-taplo": { "links": { "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L115" }, - "initKeys": [ - "repo" - ] + "initKeys": ["repo"] } }, "MultiplePlugins": { "title": "Pattern for multiple definition of vim plugin", "type": "object", - "required": [ - "plugins" - ], + "required": ["plugins"], "additionalProperties": false, "properties": { "plugins": { "title": "plugins", + "type": "array", "description": "The repository URI or local repository directory path.", "items": { "$ref": "#/definitions/repo-string-pattern" @@ -554,14 +480,12 @@ }, "on_map-array1": { "type": "array", - "additionalItems": false, "items": { "$ref": "#/definitions/on_map-string" } }, "on_map-array2": { "type": "array", - "additionalItems": false, "items": { "$ref": "#/definitions/vim-mode-key-mapping-string" } @@ -581,7 +505,7 @@ "additionalProperties": false, "patternProperties": { "^[nvxsomilct]+$": { - "description": "Pattern for vim key binding. You can use plugin prefix mappings. You can use '' keyword as {mapping}. If{mapping} is '', '(normalized_name' isused. linter support is now under developping", + "description": "Pattern for vim key binding. You can use plugin prefix mappings. You can use '' keyword as {mapping}. If{mapping} is '', '(normalized_name' is used. linter support is now under development", "oneOf": [ { "$ref": "#/definitions/vim-mode-key-mapping-string" @@ -596,7 +520,6 @@ "ArrayOrString": { "oneOf": [ { - "additionalItems": false, "items": { "type": "string" }, @@ -613,13 +536,92 @@ "type": "boolean" }, { - "enum": [ - 0, - 1 - ], + "enum": [0, 1], "type": "number" } ] } + }, + "description": "A schema for config of dein.vim (https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L963)", + "properties": { + "plugins": { + "title": "Definition properties table for installing a vim plugin", + "description": "Definition properties table for installing a vim plugin.\nIt is converted to |dein#add()|.", + "type": "array", + "items": { + "$ref": "#/definitions/Plugin" + }, + "x-taplo": { + "links": { + "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L1068" + } + } + }, + "ftplugin": { + "title": "ftplugin definition", + "description": "'_' key is executed after all ftplugin.\n'{filetype}' key is executed {filetype} ftplugin.\n You can define multiple filetypes by '{filetype1}_{filetype2}' key.", + "type": "object", + "additionalProperties": false, + "properties": { + "_": { + "title": "all filetypes", + "description": "'_' key is executed after all ftplugin.", + "type": "string", + "x-taplo": { + "links": { + "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L1056" + } + } + } + }, + "patternProperties": { + "^[0-9a-zA-Z].+$": { + "title": "filetype", + "description": "'{filetype}' key is executed {filetype} ftplugin.\nYou can define multiple filetypes by '{filetype1}_{filetype2}' key.\n'b:undo_ftplugin' is defined automatically.", + "type": "string" + } + }, + "x-taplo": { + "links": { + "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L1054" + } + } + }, + "hook_add": { + "title": "hook_add definition", + "description": "It is the global |dein-options-hook_add|.\nIt is executed in |dein#end()|.", + "type": "string", + "x-taplo": { + "links": { + "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L1063" + } + } + }, + "multiple_plugins": { + "title": "It is converted to |dein-toml-hook_add|", + "description": "It is converted to |dein-toml-hook_add|\n\"plugins\" key is needed.", + "type": "array", + "items": { + "$ref": "#/definitions/MultiplePlugins" + }, + "x-taplo": { + "links": { + "key": "https://github.com/Shougo/dein.vim/blob/f93be8c/doc/dein.txt#L1073" + } + } + } + }, + "required": ["plugins"], + "title": "dein.vim", + "type": "object", + "x-taplo-info": { + "authors": [ + "kkiyama117 (https://github.com/kkiyama117)", + "raa0121 (https://github.com/raa0121)", + "Hibiki (https://github.com/4513ECHO)", + "mikan (https://github.com/mikanIchinose)" + ], + "version": "0.1.0", + "patterns": ["^(.*(/|\\\\)\\.*dein.*\\.toml|\\.*dein.*\\.toml)$"] } } diff --git a/site/site/public/schemas/fly.toml.json b/site/site/public/schemas/fly.toml.json index 09433fe9d..54e707f94 100644 --- a/site/site/public/schemas/fly.toml.json +++ b/site/site/public/schemas/fly.toml.json @@ -1,12 +1,231 @@ { - "$schema": "http://json-schema.org/draft-07/schema", - "title": "Fly.io config schema (fly.toml)", - "description": "https://fly.io/docs/reference/configuration", - "x-taplo-info": { - "authors": ["Joshua Sierles (https://github.com/jsierles)"], - "patterns": ["\\.*fly(.*)?\\.toml?$"] + "$schema": "http://json-schema.org/draft-07/schema#", + "$id": "https://json.schemastore.org/fly.json", + "definitions": { + "statics": { + "type": "object", + "required": ["guest_path", "url_prefix"], + "additionalProperties": false, + "properties": { + "guest_path": { + "description": "The path inside your container where the assets to serve are located.", + "type": "string" + }, + "url_prefix": { + "description": "The URL prefix that should serve the static assets.", + "type": "string" + } + } + }, + "services": { + "description": "Configure the mapping of ports from the public Fly proxy to your application.\n\nYou can have:\n* **No services section**: The application has no mappings to the external internet - typically apps like databases or background job workers that talk over 6PN private networking to other apps.\n* **One services section**: One internal port mapped to one external port on the internet.\n* **Multiple services sections**: Map multiple internal ports to multiple external ports.", + "type": "object", + "properties": { + "script_checks": { + "deprecated": true, + "description": "Health checks that run as one-off commands directly on the VM.\n\nThis type of check is **deprecated**. See `tcp_checks` or `http_checks` for alternatives." + }, + "protocol": { + "description": "The protocol used to communicate with your application. Can be: `tcp` or `udp`.", + "type": "string", + "enum": ["tcp", "udp"] + }, + "internal_port": { + "description": "The port this application listens on to communicate with clients. The default is 8080. We recommend applications use the default.", + "type": "integer", + "default": 8080 + }, + "concurrency": { + "type": "object", + "description": "Control autoscaling metrics (connections or requests) and limits (hard and soft).", + "properties": { + "type": { + "type": "string", + "default": "connections", + "x-taplo": { + "docs": { + "enumValues": [ + "Autoscale based on number of concurrent connections", + "Autoscale based on number of concurrent requests" + ] + } + }, + "enum": ["connections", "requests"] + }, + "hard_limit": { + "default": 25, + "type": "integer", + "description": "When an application instance is __at__ or __over__ this number, the system will bring up another instance." + }, + "soft_limit": { + "default": 20, + "type": "integer", + "description": "When an application instance is __at__ or __over__ this number, the system is likely to bring up another instance." + } + } + }, + "ports": { + "description": "For each external port you want to accept connections on, add a `ports` section.", + "type": "array", + "items": { + "type": "object", + "properties": { + "handlers": { + "x-taplo": { + "links": { + "key": "https://fly.io/docs/reference/services/#connection-handlers" + } + }, + "description": "An array of strings that select handlers to terminate the connection at the edge.\n\nValid options: http, tls, proxy_proto, pg_tls, edge_http.", + "type": "array", + "items": { + "type": "string", + "minLength": 1, + "enum": ["http", "tls", "proxy_proto", "pg_tls", "edge_http"] + } + }, + "port": { + "default": 8080, + "type": "integer", + "description": "The port to accept traffic on. Valid ports: 1-65535" + }, + "force_https": { + "type": "boolean", + "description": "Force HTTP connections to HTTPS. `force_https` requires the `http` handler in the `handlers` section." + } + } + } + }, + "tcp_checks": { + "description": "Basic TCP connection health checks. This is the default check that runs against the configured `internal_port`.", + "type": "array", + "x-taplo": { + "links": { + "key": "https://fly.io/docs/reference/configuration/#services-tcp_checks" + } + }, + "items": { + "type": "object", + "properties": { + "grace_period": { + "description": "The time to wait after a VM starts before checking its health. Units are milliseconds unless you specify them like `10s` or `1m`.", + "oneOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "interval": { + "description": "Length of the pause between connectivity checks. Units are milliseconds unless you specify them like `10s` or `1m`.", + "oneOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "restart_limit": { + "default": 0, + "description": "The number of consecutive TCP check failures to allow before attempting to restart the VM. The default is `0`, which disables restarts based on failed TCP health checks.", + "type": "integer" + }, + "timeout": { + "description": "The maximum time a connection can take before being reported as failing its healthcheck. Units are milliseconds unless you specify them like `10s` or `1m`.", + "oneOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + } + } + } + }, + "http_checks": { + "description": "HTTP-based health checks run against the `internal_port`. These checks will pass when receiving a 2xx response. Any other response is considered a failure.", + "type": "array", + "x-taplo": { + "links": { + "key": "https://fly.io/docs/reference/configuration/#services-http_checks" + } + }, + "items": { + "type": "object", + "properties": { + "grace_period": { + "description": "The time to wait after a VM starts before checking its health. Units are milliseconds unless you specify them like `10s` or `1m`.", + "oneOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "interval": { + "description": "Length of the pause between connectivity checks. Units are milliseconds unless you specify them like `10s` or `1m`.", + "oneOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "restart_limit": { + "default": 0, + "description": "The number of consecutive check failures to allow before attempting to restart the VM. The default is `0`, which disables restarts based on failed health checks.", + "type": "integer" + }, + "timeout": { + "description": "The maximum time a connection can take before being reported as failing its healthcheck. Units are milliseconds unless you specify them like `10s` or `1m`.", + "oneOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "method": { + "description": "The HTTP method to be used for the check.", + "type": "string" + }, + "path": { + "description": "The path of the URL to be requested.", + "type": "string" + }, + "protocol": { + "description": "The protocol to be used (`http` or `https`)", + "type": "string", + "enum": ["http", "https"] + }, + "tls_skip_verify": { + "type": "boolean", + "default": false, + "description": "When set to `true` (and `protocol` is set to `https`), skip verifying the certificates sent by the server." + }, + "headers": { + "type": "object", + "description": "Set key/value pairs of HTTP headers to pass along with the check request." + } + } + } + } + } + } }, - "type": "object", + "description": "https://fly.io/docs/reference/configuration", "properties": { "app": { "description": "Fly.io application name", @@ -14,7 +233,14 @@ }, "kill_timeout": { "description": "Seconds to wait before forcing a VM process to exit. Default is 5 seconds.", - "type": "integer" + "oneOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] }, "kill_signal": { "description": "Signal to send to a process to shut it down gracefully. Default is SIGINT.", @@ -31,198 +257,35 @@ }, "statics": { "description": "The `statics` sections expose static assets built into your application's container to Fly's Anycast network. You can serve HTML files, Javascript, and images without needing to run a web server inside your container.", - "required": ["guest_path", "url_prefix"], - "additionalProperties": false, "x-taplo": { "links": { "key": "https://fly.io/docs/reference/configuration/#the-statics-sections" } }, - "type": ["object", "array"], - "items": { - "type": "object", - "properties": { - "guest_path": { - "description": "The path inside your container where the assets to serve are located.", - "type": "string" - }, - "url_prefix": { - "description": "The URL prefix that should serve the static assets.", - "type": "string" + "anyOf": [ + { + "$ref": "#/definitions/statics" + }, + { + "type": "array", + "items": { + "$ref": "#/definitions/statics" } } - } + ] }, - "services": { - "description": "Configure the mapping of ports from the public Fly proxy to your application.\n\nYou can have:\n* **No services section**: The application has no mappings to the external internet - typically apps like databases or background job workers that talk over 6PN private networking to other apps.\n* **One services section**: One internal port mapped to one external port on the internet.\n* **Multiple services sections**: Map multiple internal ports to multiple external ports.", - "type": "array", - "required": ["port", "internal_port"], - "additionalProperties": false, - "items": { - "type": ["object", "array"], - "properties": { - "script_checks": { - "deprecated": true, - "description": "Health checks that run as one-off commands directly on the VM.\n\nThis type of check is **deprecated**. See `tcp_checks` or `http_checks` for alternatives." - }, - "protocol": { - "description": "The protocol used to communicate with your application. Can be: `tcp` or `udp`.", - "type": "string", - "enum": ["tcp", "udp"] - }, - "internal_port": { - "description": "The port this application listens on to communicate with clients. The default is 8080. We recommend applications use the default.", - "type": "integer", - "default": 8080 - }, - "concurrency": { - "type": "object", - "description": "Control autoscaling metrics (connections or requests) and limits (hard and soft).", - "properties": { - "type": { - "type": "string", - "default": "connections", - "x-taplo": { - "docs": { - "enumValues": [ - "Autoscale based on number of concurrent connections", - "Autoscale based on number of concurrent requests" - ] - } - }, - "enum": ["connections", "requests"] - }, - "hard_limit": { - "default": 25, - "type": "integer", - "description": "When an application instance is __at__ or __over__ this number, the system will bring up another instance." - }, - "soft_limit": { - "default": 20, - "type": "integer", - "description": "When an application instance is __at__ or __over__ this number, the system is likely to bring up another instance." - } - } - }, - "ports": { - "description": "For each external port you want to accept connections on, add a `ports` section.", - "type": "array", - "items": { - "type": "object", - "properties": { - "handlers": { - "x-taplo": { - "links": { - "key": "https://fly.io/docs/reference/services/#connection-handlers" - } - }, - "description": "An array of strings that select handlers to terminate the connection at the edge.\n\nValid options: http, tls, proxy_proto.", - "type": "array", - "items": { - "type": "string", - "minLength": 1, - "enum": ["http", "tls", "proxy_proto"] - } - }, - "port": { - "default": 8080, - "type": "integer", - "description": "The port to accept traffic on. Valid ports: 1-65535" - }, - "force_https": { - "type": "boolean", - "description": "Force HTTP connections to HTTPS. `force_https` requires the `http` handler in the `handlers` section." - } - } - } - }, - "tcp_checks": { - "description": "Basic TCP connection health checks. This is the default check that runs against the configured `internal_port`.", - "type": "array", - "x-taplo": { - "links": { - "key": "https://fly.io/docs/reference/configuration/#services-tcp_checks" - } - }, - "items": { - "type": "object", - "properties": { - "grace_period": { - "description": "The time to wait after a VM starts before checking its health. Units are milliseconds unless you specify them like `10s` or `1m`.", - "type": "string" - }, - "interval": { - "description": "Length of the pause between connectivity checks. Units are milliseconds unless you specify them like `10s` or `1m`.", - "type": "string" - }, - "restart_limit": { - "default": 0, - "description": "The number of consecutive TCP check failures to allow before attempting to restart the VM. The default is `0`, which disables restarts based on failed TCP health checks.", - "type": "integer" - }, - "timeout": { - "description": "The maximum time a connection can take before being reported as failing its healthcheck. Units are milliseconds unless you specify them like `10s` or `1m`.", - "type": "string" - } - } - } - }, - "http_checks": { - "description": "HTTP-based health checks run against the `internal_port`. These checks will pass when receiving a 2xx response. Any other response is considered a failure.", - "type": "array", - "x-taplo": { - "links": { - "key": "https://fly.io/docs/reference/configuration/#services-http_checks" - } - }, - "items": { - "type": "object", - "properties": { - "grace_period": { - "description": "The time to wait after a VM starts before checking its health. Units are milliseconds unless you specify them like `10s` or `1m`.", - "type": "string" - }, - "interval": { - "description": "Length of the pause between connectivity checks. Units are milliseconds unless you specify them like `10s` or `1m`.", - "type": "string" - }, - "restart_limit": { - "default": 0, - "description": "The number of consecutive check failures to allow before attempting to restart the VM. The default is `0`, which disables restarts based on failed health checks.", - "type": "integer" - }, - "timeout": { - "description": "The maximum time a connection can take before being reported as failing its healthcheck. Units are milliseconds unless you specify them like `10s` or `1m`.", - "type": "string" - }, - "method": { - "description": "The HTTP method to be used for the check.", - "type": "string" - }, - "path": { - "description": "The path of the URL to be requested.", - "type": "string" - }, - "protocol": { - "description": "The protocol to be used (`http` or `https`)", - "type": "string", - "enum": ["http", "https"] - }, - "tls_skip_verify": { - "type": "boolean", - "default": false, - "description": "When set to `true` (and `protocol` is set to `https`), skip verifying the certificates sent by the server." - }, - "headers": { - "type": "object", - "description": "Set key/value pairs of HTTP headers to pass along with the check request." - } - } - } + "oneOf": [ + { + "$ref": "#/definitions/services" + }, + { + "type": "array", + "items": { + "$ref": "#/definitions/services" } } - } + ] }, "deploy": { "type": "object", @@ -279,6 +342,14 @@ "destination": { "description": "The path at which the `source` volume should be mounted in the running app VM.", "type": "string" + }, + "processes": { + "description": "The name of the process(es) to which this mount should be applied. See [multiple processes](https://community.fly.io/t/preview-multi-process-apps-get-your-workers-here/2316).", + "type": "array", + "items": { + "type": "string", + "minLength": 1 + } } } }, @@ -288,11 +359,31 @@ "properties": { "cmd": { "description": "Override the server command (CMD) set by the Dockerfile. Specify as an array of strings:\n\n```toml\ncmd = [\"path/to/command\", \"arg1\", \"arg2\"]\n```", - "type": ["array", "string"] + "anyOf": [ + { + "type": "string" + }, + { + "type": "array", + "items": { + "type": "string" + } + } + ] }, "entrypoint": { "description": "Override the ENTRYPOINT set by the Dockerfile. Specify as an array of strings:\n\n```toml\nentrypoint = [\"path/to/command\", \"arg1\", \"arg2\"]\n```", - "type": ["array", "string"] + "anyOf": [ + { + "type": "string" + }, + { + "type": "array", + "items": { + "type": "string" + } + } + ] }, "auto_rollback": { "description": "Failed deployments should roll back automatically to the previous successfully deployed release. Defaults to `true`", @@ -308,8 +399,8 @@ "env": { "description": "Set non-sensitive information as environment variables in the application's [runtime environment](https://fly.io/docs/reference/runtime-environment/).\nFor sensitive information, such as credentials or passwords, use the [secrets command](https://fly.io/docs/reference/secrets). For anything else though, the `env` section provides a simple way to set environment variables. Here's an example:\n```toml\n[env]\n LOG_LEVEL = \"debug\"\n S3_BUCKET = \"my-bucket\"\n```", "type": "object", - "items": { - "type": "object" + "additionalProperties": { + "type": "string" } }, "build": { @@ -333,8 +424,8 @@ "args": { "description": "Build arguments passed to both Dockerfile and Buildpack builds. These arguments are **not available** on VMs at runtime.\n```toml\n[build.args]\n USER = \"julieta\"\n MODE = \"production\"\n```", "type": "object", - "items": { - "type": "object" + "additionalProperties": { + "type": "string" } }, "build-target": { @@ -349,9 +440,19 @@ "description": "Dockerfile used for builds. Defaults to './Dockerfile'", "type": "string" }, - "additionalProperties": false - } - }, - "additionalProperties": true + "ignorefile": { + "description": "A relative path to a .dockerignore file. Defaults to './.dockerignore'", + "type": "string" + } + }, + "additionalProperties": false + } + }, + "additionalProperties": true, + "title": "Fly.io config schema (fly.toml)", + "type": "object", + "x-taplo-info": { + "authors": ["Joshua Sierles (https://github.com/jsierles)"], + "patterns": ["\\.*fly(.*)?\\.toml?$"] } } diff --git a/site/site/public/schemas/makefile.toml.json b/site/site/public/schemas/makefile.toml.json index 8bf95c183..03c066f41 100644 --- a/site/site/public/schemas/makefile.toml.json +++ b/site/site/public/schemas/makefile.toml.json @@ -1,462 +1,145 @@ { "$schema": "http://json-schema.org/draft-07/schema#", "$id": "https://github.com/sagiegurari/cargo-make", - "title": "Makefile.toml", - "description": "A schema for cargo-make makefiles", - "x-taplo-info": { - "authors": [ - "Kathryn Long (https://github.com/starkat99)" - ], - "version": "0.35.0", - "patterns": [ - "^(.*(/|\\\\)Makefile\\.toml|Makefile\\.toml)$" - ] - }, - "type": "object", "additionalProperties": false, - "properties": { + "definitions": { + "semver": { + "title": "Semantic Version", + "type": "string", + "pattern": "^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)(?:-((?:0|[1-9][0-9]*|[0-9]*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9][0-9]*|[0-9]*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$" + }, "extend": { - "title": "Extend External Makefile", - "description": "Extend an external makefile by importing its tasks and properties to this file. Paths are relative to this makefile", + "title": "External Makefile", + "description": "A potentially optional external makefile to extend", + "type": "object", "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-workspace-extending-external-makefile" - } + "initKeys": ["optional"] }, - "default": "path/to/Makefile.toml", - "examples": [ - "path/to/Makefile.toml", - { - "path": "path/to/Makefile.toml", - "optional": true - }, - [ - { - "path": "path/to/Makefile.toml", - "optional": true - } - ] - ], - "oneOf": [ - { + "required": ["path"], + "additionalProperties": false, + "properties": { + "path": { "title": "File Path", - "description": "File path to external makefile relative to this file", + "description": "The path of the external makefile, relative to this file", "type": "string", - "examples": [ - "path/to/Makefile.toml" - ] + "default": "path/to/Makefile.toml" }, + "optional": { + "description": "If true, the external makefile is optional and does not need to exist", + "type": "boolean", + "default": true + } + } + }, + "script": { + "title": "Script", + "oneOf": [ { - "$ref": "#/definitions/extend" + "title": "Script Line", + "type": "string" }, { - "title": "External Makefile List", - "description": "List of external makefiles to extend", + "title": "Script Lines", "type": "array", "items": { - "$ref": "#/definitions/extend" - }, - "uniqueItems": true - } - ] - }, - "config": { - "title": "Config", - "description": "Configuration options for this makefile", - "type": "object", - "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/api/cli/types/struct.ConfigSection.html" - }, - "initKeys": [ - "min_version" - ] - }, - "additionalProperties": false, - "properties": { - "skip_core_tasks": { - "description": "If true, the default core tasks will not be loaded", - "default": true, - "type": "boolean", - "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-predefined-flows-disable" - } + "type": "string" } }, - "modify_core_tasks": { - "description": "Options to modify all the core tasks", + { + "title": "Script File", "type": "object", - "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-predefined-flows-modify" - } - }, "examples": [ { - "private": true - }, - { - "namespace": "default" + "file": "path/to/script" }, { - "private": true, - "namespace": "default" + "file": "path/to/script", + "absolute_path": true } ], + "required": ["file"], "additionalProperties": false, "properties": { - "private": { - "description": "If true, all core tasks will be set to private (default false)", + "file": { + "title": "File Path", + "description": "Script file name", + "type": "string", + "default": "path/to/script" + }, + "absolute_path": { + "description": "If true, the `file` value is an absolute path", "default": true, "type": "boolean" - }, - "namespace": { - "title": "Namespace", - "description": "If set to some value, all core tasks are modified to: `namespace::name`", - "type": "string", - "default": "default" } } }, - "init_task": { - "title": "Task Name", - "description": "Init task name which will be invoked at the start of every run", - "type": "string", + { + "title": "Split Script", + "description": "Script content split to parts to enable a more fine tuned extension capability", + "type": "object", "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-init-end-tasks" - } + "initKeys": ["pre", "main", "post"] }, - "default": "init" - }, - "end_task": { - "title": "Task Name", - "description": "End task name which will be invoked at the end of every run", - "default": "end", - "type": "string", - "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-init-end-tasks" + "additionalProperties": false, + "properties": { + "pre": { + "title": "Pre-Main Script", + "description": "Pre-main script section", + "type": "string" + }, + "main": { + "title": "Main Script", + "description": "Main script section", + "type": "string" + }, + "post": { + "title": "Post-Main Script", + "description": "Post-main script section", + "type": "string" } } - }, - "on_error_task": { - "title": "Task Name", - "description": "The name of the task to run in case of any error during the invocation of the flow", - "type": "string", - "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-catching-errors" - } - }, - "default": "catch" - }, - "legacy_migration_task": { - "title": "Task Name", - "description": "The name of the task which runs legacy migration flows", - "default": "legacy-migration", + } + ] + }, + "env_files": { + "title": "List of Env Files", + "description": "Load environment files", + "type": "array", + "default": [], + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-env-file" + } + }, + "items": { + "$ref": "#/definitions/envfile" + }, + "uniqueItems": true + }, + "envfile": { + "title": "Env File", + "description": "File containing environment variables and their values", + "examples": [ + "path/to/env.env", + { + "path": "path/to/env.env", + "profile": "development" + } + ], + "oneOf": [ + { + "title": "File Path", + "description": "The path to the env file", "type": "string", - "x-taplo": { - "hidden": true - } + "default": "path/to/env.env" }, - "additional_profiles": { - "title": "List of Profiles", - "description": "Additional profile names to load", - "default": [], - "type": "array", + { + "description": "The env file path and attributes", + "type": "object", "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-profiles" - } - }, - "examples": [ - [ - "additional_profile" - ] - ], - "items": { - "title": "Profile", - "description": "Additional profile name to load", - "type": "string", - "default": "additional_profile" + "initKeys": ["profile"] }, - "uniqueItems": true - }, - "min_version": { - "description": "Minimum cargo-make/makers version", - "$ref": "#/definitions/semver", - "default": "0.35.0", - "examples": [ - "0.35.0", - "0.34.0", - "0.33.0" - ], - "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-min-version" - } - } - }, - "default_to_workspace": { - "description": "The default value for the `workspace` value of tasks in this makefile", - "default": false, - "type": "boolean", - "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-workspace-disabling-workspace-support" - } - } - }, - "reduce_output": { - "description": "Set to true to reduce console output for non CI execution", - "default": true, - "type": "boolean" - }, - "time_summary": { - "description": "Set to true to print time summary at the end of the flow", - "default": true, - "type": "boolean" - }, - "load_cargo_aliases": { - "description": "Automatically load cargo aliases as cargo-make tasks", - "default": true, - "type": "boolean", - "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-cargo-alias-tasks" - } - } - }, - "main_project_member": { - "title": "Crate", - "description": "The project information member (used by workspaces)", - "type": "string", - "default": "main-crate" - }, - "load_script": { - "description": "Invoked while loading the descriptor file but before loading any extended descriptor", - "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-load-scripts" - } - }, - "$ref": "#/definitions/script" - }, - "linux_load_script": { - "description": "Invoked while loading the descriptor file but before loading any extended descriptor. Takes precedence over `load_script` if runtime OS is Linux.", - "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-load-scripts" - } - }, - "$ref": "#/definitions/script" - }, - "windows_load_script": { - "description": "Invoked while loading the descriptor file but before loading any extended descriptor. Takes precedence over `load_script` if runtime OS is Windows.", - "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-load-scripts" - } - }, - "$ref": "#/definitions/script" - }, - "mac_load_script": { - "description": "Invoked while loading the descriptor file but before loading any extended descriptor. Takes precedence over `load_script` if runtime OS is Mac.", - "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-load-scripts" - } - }, - "$ref": "#/definitions/script" - } - } - }, - "env_files": { - "description": "The environment files to setup before running any tasks", - "$ref": "#/definitions/env_files" - }, - "env_scripts": { - "title": "List of Env Scripts", - "description": "The environment scripts to execute after environment files and the env block. These scripts can be used to run anything needed before starting up the flow.", - "type": "array", - "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-env-file" - } - }, - "default": [], - "items": { - "description": "Env script", - "type": "string", - "$ref": "#/definitions/script" - } - }, - "env": { - "description": "The environment variables to setup before running any tasks", - "$ref": "#/definitions/env" - }, - "tasks": { - "description": "Task definitions", - "type": "object", - "additionalProperties": { - "$ref": "#/definitions/task" - } - } - }, - "definitions": { - "semver": { - "title": "Semantic Version", - "type": "string", - "pattern": "^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)(?:-((?:0|[1-9][0-9]*|[0-9]*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9][0-9]*|[0-9]*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$" - }, - "extend": { - "title": "External Makefile", - "description": "A potentially optional external makefile to extend", - "type": "object", - "x-taplo": { - "initKeys": [ - "optional" - ] - }, - "required": [ - "path" - ], - "additionalProperties": false, - "properties": { - "path": { - "title": "File Path", - "description": "The path of the external makefile, relative to this file", - "type": "string", - "default": "path/to/Makefile.toml" - }, - "optional": { - "description": "If true, the external makefile is optional and does not need to exist", - "type": "boolean", - "default": true - } - } - }, - "script": { - "title": "Script", - "oneOf": [ - { - "title": "Script Line", - "type": "string" - }, - { - "title": "Script Lines", - "type": "array", - "items": { - "type": "string" - } - }, - { - "title": "Script File", - "type": "object", - "examples": [ - { - "file": "path/to/script" - }, - { - "file": "path/to/script", - "absolute_path": true - } - ], - "required": [ - "file" - ], - "additionalProperties": false, - "properties": { - "file": { - "title": "File Path", - "description": "Scipt file name", - "type": "string", - "default": "path/to/script" - }, - "absolute_path": { - "description": "If true, the `file` value is an absolute path", - "default": true, - "type": "boolean" - } - } - }, - { - "title": "Split Script", - "description": "Script content split to parts to enable a more fine tuned extension capability", - "type": "object", - "x-taplo": { - "initKeys": [ - "pre", - "main", - "post" - ] - }, - "additionalProperties": false, - "properties": { - "pre": { - "title": "Pre-Main Script", - "description": "Pre-main script section", - "type": "string" - }, - "main": { - "title": "Main Script", - "description": "Main script section", - "type": "string" - }, - "post": { - "title": "Post-Main Script", - "description": "Post-main script section", - "type": "string" - } - } - } - ] - }, - "env_files": { - "title": "List of Env Files", - "description": "Load environment files", - "type": "array", - "default": [], - "x-taplo": { - "links": { - "key": "https://sagiegurari.github.io/cargo-make/#usage-env-file" - } - }, - "items": { - "$ref": "#/definitions/envfile" - }, - "uniqueItems": true - }, - "envfile": { - "title": "Env File", - "description": "File containing environment variables and their values", - "examples": [ - "path/to/env.env", - { - "path": "path/to/env.env", - "profile": "development" - } - ], - "oneOf": [ - { - "title": "File Path", - "description": "The path to the env file", - "type": "string", - "default": "path/to/env.env" - }, - { - "description": "The env file path and attributes", - "type": "object", - "x-taplo": { - "initKeys": [ - "profile" - ] - }, - "required": [ - "path" - ], + "required": ["path"], "additionalProperties": false, "properties": { "path": { @@ -476,10 +159,7 @@ "description": "The profile name this file is relevant to", "type": "string", "default": "development", - "examples": [ - "development", - "production" - ] + "examples": ["development", "production"] } } } @@ -543,9 +223,9 @@ "$ref": "#/definitions/env_value_path_glob" }, { + "$ref": "#/definitions/env", "title": "Profile Env Vars", - "description": "Profile dependent environment variables", - "$ref": "#/definitions/env" + "description": "Profile dependent environment variables" } ] }, @@ -553,9 +233,7 @@ "title": "Unset", "description": "Unsets environment variable", "type": "object", - "required": [ - "unset" - ], + "required": ["unset"], "additionalProperties": false, "properties": { "unset": { @@ -569,9 +247,7 @@ "title": "Env Value Script", "description": "Provide environment variable via script", "type": "object", - "required": [ - "script" - ], + "required": ["script"], "additionalProperties": false, "properties": { "script": { @@ -594,14 +270,9 @@ "description": "Environment variable value provided by decoding other values", "type": "object", "x-taplo": { - "initKeys": [ - "default_value" - ] + "initKeys": ["default_value"] }, - "required": [ - "source", - "mapping" - ], + "required": ["source", "mapping"], "additionalProperties": false, "properties": { "source": { @@ -631,13 +302,9 @@ "description": "Environment variable value set if condition is met", "type": "object", "x-taplo": { - "initKeys": [ - "condition" - ] + "initKeys": ["condition"] }, - "required": [ - "value" - ], + "required": ["value"], "additionalProperties": false, "properties": { "value": { @@ -646,8 +313,8 @@ "type": "string" }, "condition": { - "description": "Condition to evaluate to see whether to set the environment value or not", - "$ref": "#/definitions/task_condition" + "$ref": "#/definitions/task_condition", + "description": "Condition to evaluate to see whether to set the environment value or not" } } }, @@ -655,9 +322,7 @@ "title": "Env Value Glob", "description": "Environment value holding a list of paths based on given glob definitions", "type": "object", - "required": [ - "glob" - ], + "required": ["glob"], "additionalProperties": false, "properties": { "glob": { @@ -678,9 +343,7 @@ "ignore_type": { "title": "Ignore Source", "description": "An ignore source that enables respecting ignore files from that source", - "enum": [ - "git" - ], + "enum": ["git"], "type": "string", "default": "git" } @@ -721,11 +384,7 @@ "items": { "title": "Platform", "description": "Platform name", - "enum": [ - "linux", - "windows", - "mac" - ], + "enum": ["linux", "windows", "mac"], "type": "string" } }, @@ -736,11 +395,7 @@ "items": { "title": "Channel", "description": "Rust channel", - "enum": [ - "stable", - "beta", - "nightly" - ], + "enum": ["stable", "beta", "nightly"], "type": "string", "default": "stable" } @@ -810,23 +465,21 @@ "description": "A definition of min, max and/or specific rust version", "type": "object", "x-taplo": { - "initKeys": [ - "min" - ] + "initKeys": ["min"] }, "additionalProperties": false, "properties": { "min": { - "description": "Minimum Rust version", - "$ref": "#/definitions/semver" + "$ref": "#/definitions/semver", + "description": "Minimum Rust version" }, "max": { - "description": "Maximum Rust version", - "$ref": "#/definitions/semver" + "$ref": "#/definitions/semver", + "description": "Maximum Rust version" }, "equal": { - "description": "Exact Rust version", - "$ref": "#/definitions/semver" + "$ref": "#/definitions/semver", + "description": "Exact Rust version" } } }, @@ -849,6 +502,30 @@ "description": "File path", "type": "string" } + }, + "files_modified": { + "title": "Lists input and output globs", + "description": "If any input file is newer than all output files, the condition is met. Environment substitution is supported so you can define relative paths", + "type": "object", + "additionalProperties": false, + "properties": { + "input": { + "description": "List of input globs", + "type": "array", + "items": { + "description": "glob", + "type": "string" + } + }, + "output": { + "description": "List of output globs", + "type": "array", + "items": { + "description": "glob", + "type": "string" + } + } + } } } }, @@ -952,15 +629,13 @@ "title": "Watch Options", "type": "object", "x-taplo": { - "initKeys": [ - "watch" - ] + "initKeys": ["watch"] }, "additionalProperties": false, "properties": { "version": { - "description": "Version of cargo-watch to install if it's not already installed", - "$ref": "#/definitions/semver" + "$ref": "#/definitions/semver", + "description": "Version of cargo-watch to install if it's not already installed" }, "postpone": { "description": "Postpone first run until a file changes", @@ -992,8 +667,8 @@ ] }, "condition": { - "description": "If provided all condition values must be met in order for the task to be invoked (will not stop dependencies)", - "$ref": "#/definitions/task_condition" + "$ref": "#/definitions/task_condition", + "description": "If provided all condition values must be met in order for the task to be invoked (will not stop dependencies)" }, "condition_script": { "title": "Script", @@ -1028,12 +703,12 @@ } }, "env_files": { - "description": "The env files to setup before running the task commands", - "$ref": "#/definitions/env_files" + "$ref": "#/definitions/env_files", + "description": "The env files to setup before running the task commands" }, "env": { - "description": "The env vars to setup before running the task commands", - "$ref": "#/definitions/env" + "$ref": "#/definitions/env", + "description": "The env vars to setup before running the task commands" }, "cwd": { "title": "Directory Path", @@ -1103,11 +778,7 @@ "title": "Crate Install Options", "description": "Instructions on how to install a crate", "type": "object", - "required": [ - "crate_name", - "binary", - "test_arg" - ], + "required": ["crate_name", "binary", "test_arg"], "additionalProperties": false, "properties": { "crate_name": { @@ -1141,12 +812,17 @@ ] }, "min_version": { - "description": "Minimum version of installed crate before it needs to be reinstalled", - "$ref": "#/definitions/semver" + "$ref": "#/definitions/semver", + "description": "Minimum version of installed crate before it needs to be reinstalled" }, "version": { - "description": "Exact version of installed crate", - "$ref": "#/definitions/semver" + "$ref": "#/definitions/semver", + "description": "Exact version of installed crate" + }, + "install_command": { + "title": "Install Command", + "description": "The alternative cargo install command to install the crate", + "type": "string" } } }, @@ -1154,9 +830,7 @@ "title": "Component Install Options", "description": "Instructions on how to install a rustup component", "type": "object", - "required": [ - "rustup_component_name" - ], + "required": ["rustup_component_name"], "additionalProperties": false, "properties": { "rustup_component_name": { @@ -1190,10 +864,7 @@ "title": "Plugin Install Options", "description": "Instructions on how to install a cargo plugin", "type": "object", - "required": [ - "crate_name", - "min_version" - ], + "required": ["crate_name", "min_version"], "additionalProperties": false, "properties": { "crate_name": { @@ -1202,8 +873,8 @@ "type": "string" }, "min_version": { - "description": "Minimum version of installed crate before it needs to be reinstalled", - "$ref": "#/definitions/semver" + "$ref": "#/definitions/semver", + "description": "Minimum version of installed crate before it needs to be reinstalled" } } } @@ -1218,8 +889,8 @@ } }, "install_script": { - "description": "Provided script will be executed before running the task", - "$ref": "#/definitions/script" + "$ref": "#/definitions/script", + "description": "Provided script will be executed before running the task" }, "command": { "title": "File Name", @@ -1245,8 +916,8 @@ } }, "script": { - "description": "If `command` is not defined, but `script` is defined, the provided script will be executed", "$ref": "#/definitions/script", + "description": "If `command` is not defined, but `script` is defined, the provided script will be executed", "x-taplo": { "links": { "key": "https://sagiegurari.github.io/cargo-make/#usage-task-command-script-task-examplescript" @@ -1277,9 +948,7 @@ "title": "Args", "description": "The script runner arguments before the script file path", "type": "string", - "examples": [ - "-f" - ], + "examples": ["-f"], "x-taplo": { "links": { "key": "https://sagiegurari.github.io/cargo-make/#usage-task-command-script-task-examplegeneric" @@ -1290,13 +959,7 @@ "title": "File Extension", "description": "The file extension to use for the script", "type": "string", - "examples": [ - "py", - "pl", - "js", - "php", - "ps1" - ] + "examples": ["py", "pl", "js", "php", "ps1"] }, "x-taplo": { "links": { @@ -1318,9 +981,7 @@ }, { "type": "object", - "required": [ - "name" - ], + "required": ["name"], "additionalProperties": false, "properties": { "name": { @@ -1379,9 +1040,7 @@ "items": { "description": "Sub-task routing information", "type": "object", - "required": [ - "name" - ], + "required": ["name"], "additionalProperties": false, "properties": { "name": { @@ -1432,8 +1091,8 @@ } }, "condition": { - "description": "If provided all condition values must be met in order for the task to be invoked", - "$ref": "#/definitions/task_condition" + "$ref": "#/definitions/task_condition", + "description": "If provided all condition values must be met in order for the task to be invoked" }, "condition_script": { "title": "Script", @@ -1469,13 +1128,9 @@ "description": "A task dependency potentially in another file", "type": "object", "x-taplo": { - "initKeys": [ - "path" - ] + "initKeys": ["path"] }, - "required": [ - "name" - ], + "required": ["name"], "additionalProperties": false, "properties": { "name": { @@ -1505,18 +1160,364 @@ } }, "linux": { - "description": "Override task if runtime OS is Linux (takes precedence over alias)", - "$ref": "#/definitions/task" + "$ref": "#/definitions/task", + "description": "Override task if runtime OS is Linux (takes precedence over alias)" }, "windows": { - "description": "Override task if runtime OS is Windows (takes precedence over alias)", - "$ref": "#/definitions/task" + "$ref": "#/definitions/task", + "description": "Override task if runtime OS is Windows (takes precedence over alias)" }, "mac": { - "description": "Override task if runtime OS is Mac (takes precedence over alias)", - "$ref": "#/definitions/task" + "$ref": "#/definitions/task", + "description": "Override task if runtime OS is Mac (takes precedence over alias)" } } + }, + "unstable_feature_flags": { + "title": "List of Unstable Feature Flags", + "description": "Specify unstable features to enable", + "type": "array", + "default": [], + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-unstable-features" + } + }, + "items": { + "$ref": "#/definitions/unstable_feature_flag" + }, + "uniqueItems": true + }, + "unstable_feature_flag": { + "title": "Unstable Feature Flag", + "description": "Unstable feature flag", + "enum": ["CTRL_C_HANDLING"] + } + }, + "description": "A schema for cargo-make makefiles", + "properties": { + "extend": { + "title": "Extend External Makefile", + "description": "Extend an external makefile by importing its tasks and properties to this file. Paths are relative to this makefile", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-workspace-extending-external-makefile" + } + }, + "default": "path/to/Makefile.toml", + "examples": [ + "path/to/Makefile.toml", + { + "path": "path/to/Makefile.toml", + "optional": true + }, + [ + { + "path": "path/to/Makefile.toml", + "optional": true + } + ] + ], + "oneOf": [ + { + "title": "File Path", + "description": "File path to external makefile relative to this file", + "type": "string", + "examples": ["path/to/Makefile.toml"] + }, + { + "$ref": "#/definitions/extend" + }, + { + "title": "External Makefile List", + "description": "List of external makefiles to extend", + "type": "array", + "items": { + "$ref": "#/definitions/extend" + }, + "uniqueItems": true + } + ] + }, + "config": { + "title": "Config", + "description": "Configuration options for this makefile", + "type": "object", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/api/cli/types/struct.ConfigSection.html" + }, + "initKeys": ["min_version"] + }, + "additionalProperties": false, + "properties": { + "skip_core_tasks": { + "description": "If true, the default core tasks will not be loaded", + "default": false, + "type": "boolean", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-predefined-flows-disable" + } + } + }, + "skip_git_env_info": { + "description": "If true, the Git related environment variables will not be loaded", + "default": false, + "type": "boolean", + "x-taplo": { + "links": { + "key": "https://github.com/sagiegurari/cargo-make#performance-tuning" + } + } + }, + "skip_rust_env_info": { + "description": "If true, the rust related environment variables will not be loaded", + "default": false, + "type": "boolean", + "x-taplo": { + "links": { + "key": "https://github.com/sagiegurari/cargo-make#performance-tuning" + } + } + }, + "skip_crate_env_info": { + "description": "If true, the current crate related environment variables will not be loaded", + "default": false, + "type": "boolean", + "x-taplo": { + "links": { + "key": "https://github.com/sagiegurari/cargo-make#performance-tuning" + } + } + }, + "modify_core_tasks": { + "description": "Options to modify all the core tasks", + "type": "object", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-predefined-flows-modify" + } + }, + "examples": [ + { + "private": true + }, + { + "namespace": "default" + }, + { + "private": true, + "namespace": "default" + } + ], + "additionalProperties": false, + "properties": { + "private": { + "description": "If true, all core tasks will be set to private (default false)", + "default": true, + "type": "boolean" + }, + "namespace": { + "title": "Namespace", + "description": "If set to some value, all core tasks are modified to: `namespace::name`", + "type": "string", + "default": "default" + } + } + }, + "init_task": { + "title": "Task Name", + "description": "Init task name which will be invoked at the start of every run", + "type": "string", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-init-end-tasks" + } + }, + "default": "init" + }, + "end_task": { + "title": "Task Name", + "description": "End task name which will be invoked at the end of every run", + "default": "end", + "type": "string", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-init-end-tasks" + } + } + }, + "on_error_task": { + "title": "Task Name", + "description": "The name of the task to run in case of any error during the invocation of the flow", + "type": "string", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-catching-errors" + } + }, + "default": "catch" + }, + "legacy_migration_task": { + "title": "Task Name", + "description": "The name of the task which runs legacy migration flows", + "default": "legacy-migration", + "type": "string", + "x-taplo": { + "hidden": true + } + }, + "additional_profiles": { + "title": "List of Profiles", + "description": "Additional profile names to load", + "default": [], + "type": "array", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-profiles" + } + }, + "examples": [["additional_profile"]], + "items": { + "title": "Profile", + "description": "Additional profile name to load", + "type": "string", + "default": "additional_profile" + }, + "uniqueItems": true + }, + "min_version": { + "$ref": "#/definitions/semver", + "description": "Minimum cargo-make/makers version", + "default": "0.35.0", + "examples": ["0.35.0", "0.34.0", "0.33.0"], + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-min-version" + } + } + }, + "default_to_workspace": { + "description": "The default value for the `workspace` value of tasks in this makefile", + "default": true, + "type": "boolean", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-workspace-disabling-workspace-support" + } + } + }, + "reduce_output": { + "description": "Set to true to reduce console output for non CI execution", + "default": true, + "type": "boolean" + }, + "time_summary": { + "description": "Set to true to print time summary at the end of the flow", + "default": true, + "type": "boolean" + }, + "load_cargo_aliases": { + "description": "Automatically load cargo aliases as cargo-make tasks", + "default": true, + "type": "boolean", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-cargo-alias-tasks" + } + } + }, + "main_project_member": { + "title": "Crate", + "description": "The project information member (used by workspaces)", + "type": "string", + "default": "main-crate" + }, + "load_script": { + "$ref": "#/definitions/script", + "description": "Invoked while loading the descriptor file but before loading any extended descriptor", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-load-scripts" + } + } + }, + "linux_load_script": { + "$ref": "#/definitions/script", + "description": "Invoked while loading the descriptor file but before loading any extended descriptor. Takes precedence over `load_script` if runtime OS is Linux.", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-load-scripts" + } + } + }, + "windows_load_script": { + "$ref": "#/definitions/script", + "description": "Invoked while loading the descriptor file but before loading any extended descriptor. Takes precedence over `load_script` if runtime OS is Windows.", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-load-scripts" + } + } + }, + "mac_load_script": { + "$ref": "#/definitions/script", + "description": "Invoked while loading the descriptor file but before loading any extended descriptor. Takes precedence over `load_script` if runtime OS is Mac.", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-load-scripts" + } + } + }, + "unstable_features": { + "$ref": "#/definitions/unstable_feature_flags", + "description": "Enables unstable cargo-make features", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-unstable-features" + } + } + } + } + }, + "env_files": { + "$ref": "#/definitions/env_files", + "description": "The environment files to setup before running any tasks" + }, + "env_scripts": { + "title": "List of Env Scripts", + "description": "The environment scripts to execute after environment files and the env block. These scripts can be used to run anything needed before starting up the flow.", + "type": "array", + "x-taplo": { + "links": { + "key": "https://sagiegurari.github.io/cargo-make/#usage-env-file" + } + }, + "default": [], + "items": { + "$ref": "#/definitions/script", + "description": "Env script", + "type": "string" + } + }, + "env": { + "$ref": "#/definitions/env", + "description": "The environment variables to setup before running any tasks" + }, + "tasks": { + "description": "Task definitions", + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/task" + } } + }, + "title": "Makefile.toml", + "type": "object", + "x-taplo-info": { + "authors": ["Kathryn Long (https://github.com/starkat99)"], + "version": "0.35.0", + "patterns": ["^(.*(/|\\\\)Makefile\\.toml|Makefile\\.toml)$"] } -} \ No newline at end of file +} diff --git a/site/site/public/schemas/pyproject.toml.json b/site/site/public/schemas/pyproject.toml.json index c8c9e4fb4..4f7fccd82 100644 --- a/site/site/public/schemas/pyproject.toml.json +++ b/site/site/public/schemas/pyproject.toml.json @@ -1,582 +1,628 @@ { "$schema": "http://json-schema.org/draft-07/schema#", - "title": "pyproject.toml", - "x-taplo-info": { - "authors": ["zevisert (https://github.com/zevisert)"], - "patterns": ["^(.*(/|\\\\)pyproject\\.toml|pyproject\\.toml)$"] - }, + "$id": "https://json.schemastore.org/pyproject.json", + "$comment": "there are multiple resources describing pyproject.toml. The canonical reference is at https://packaging.python.org/en/latest/specifications/declaring-project-metadata/, which refers to multiple proposals such as PEP 517, PEP 518 and PEP 621", + "additionalProperties": false, "definitions": { - "poetry-author-pattern": { - "description": "Pattern that matches `Name ` like 'King Arthur' or 'Miss Islington <miss-islington@python.org>'.", - "type": "string", - "pattern": "^(?:\\S+?\\s)+?(?:<(?:[a-z\\d!#$%&'*+/=?^_`{|}~-]+(?:\\.[a-z\\d!#$%&'*+/=?^_`{|}~-]+)*|\"(?:[\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x21\\x23-\\x5b\\x5d-\\x7f]|\\\\[\\x01-\\x09\\x0b\\x0c\\x0e-\\x7f])*\")@(?:(?:[a-z\\d](?:[a-z\\d-]*[a-z\\d])?\\.)+[a-z\\d](?:[a-z\\d-]*[a-z\\d])?|\\[(?:(?:25[0-5]|2[0-4][\\d]|[01]?[\\d][\\d]?)\\.){3}(?:25[0-5]|2[0-4][\\d]|[01]?[\\d][\\d]?|[a-z\\d-]*[a-z\\d]:(?:[\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x21-\\x5a\\x53-\\x7f]|\\\\[\\x01-\\x09\\x0b\\x0c\\x0e-\\x7f])+)\\])>)?$" - }, - "poetry-authors": { - "type": "array", - "description": "List of authors that contributed to the package. This is typically the main maintainers, not the full list.", - "items": { - "$ref": "#/definitions/poetry-author-pattern" - } - }, - "poetry-maintainers": { - "type": "array", - "description": "List of maintainers, other than the original author(s), that upkeep the package.", - "items": { - "$ref": "#/definitions/poetry-author-pattern" - } - }, - "poetry-dependency-any": { - "oneOf": [ - { - "$ref": "#/definitions/poetry-dependency" - }, - { - "$ref": "#/definitions/poetry-long-dependency" - }, - { - "$ref": "#/definitions/poetry-git-dependency" - }, - { - "$ref": "#/definitions/poetry-file-dependency" - }, + "projectAuthor": { + "type": "object", + "additionalProperties": false, + "anyOf": [ { - "$ref": "#/definitions/poetry-path-dependency" + "required": ["name"], + "properties": { + "name": true + } }, { - "$ref": "#/definitions/poetry-url-dependency" + "required": ["email"], + "properties": { + "email": true + } + } + ], + "properties": { + "name": { + "title": "Author name", + "type": "string" }, - { - "$ref": "#/definitions/poetry-multiple-constraints-dependency" + "email": { + "title": "Author email", + "type": "string", + "format": "email" } - ] - }, - "poetry-pep440-version": { - "type": "string", - "description": "A version constraint. Validates against the PEP 440's version pattern." - }, - "poetry-dependency": { - "$ref": "#/definitions/poetry-pep440-version" + } }, - "poetry-long-dependency": { + "BuildSystem": { + "$comment": "see PEP 517 (https://peps.python.org/pep-0517/) and PEP 518 (https://peps.python.org/pep-0518/)", + "title": "Project build system configuration", "type": "object", - "required": ["version"], + "x-taplo": { + "links": { + "key": "https://www.python.org/dev/peps/pep-0518/#build-system-table" + } + }, + "description": "Build-related data.\n", "additionalProperties": false, + "required": ["requires"], "properties": { - "version": { - "$ref": "#/definitions/poetry-pep440-version" - }, - "python": { - "type": "string", - "description": "The python versions for which the dependency should be installed." - }, - "platform": { - "type": "string", - "description": "The platform(s) for which the dependency should be installed." + "requires": { + "title": "Build system dependencies", + "description": "A list of strings representing [PEP 508](https://www.python.org/dev/peps/pep-0508) dependencies required to execute the build system.\n", + "type": "array", + "items": { + "type": "string" + }, + "x-taplo": { + "links": { + "key": "https://www.python.org/dev/peps/pep-0518/#build-system-table" + } + }, + "examples": ["setuptools >= 64.0"] }, - "markers": { + "build-backend": { + "title": "Build backend", + "description": "Python path to project's build backend", "type": "string", - "description": "The PEP 508 compliant environment markers for which the dependency should be installed." - }, - "allow-prereleases": { - "type": "boolean", - "description": "Whether the dependency allows prereleases or not." - }, - "allows-prereleases": { - "type": "boolean", - "description": "Whether the dependency allows prereleases or not." - }, - "optional": { - "type": "boolean", - "description": "Whether the dependency is optional or not." + "x-taplo": { + "links": { + "key": "https://www.python.org/dev/peps/pep-0517/" + } + }, + "examples": ["setuptools.build_meta", "my_build_backend:backend"] }, - "extras": { + "backend-path": { + "title": "Build backend directories", + "description": "paths to prepend to 'sys.path' when loading the build backend, relative to project root", "type": "array", - "description": "The required extras for this dependency.", "items": { "type": "string" } - }, - "source": { - "type": "string", - "description": "The exclusive source used to search for this dependency." } } + } + }, + "properties": { + "build-system": { + "$ref": "#/definitions/BuildSystem" }, - "poetry-git-dependency": { + "tool": { + "title": "Tool-specific configuration", "type": "object", - "required": ["git"], - "additionalProperties": false, + "description": "A table for tool configurations.\n\nEvery tool that is used by the project can have its own sub-table for its configuration.\n", + "additionalProperties": { + "type": "object" + }, + "x-taplo": { + "links": { + "key": "https://www.python.org/dev/peps/pep-0518/#id28" + } + }, "properties": { - "git": { - "type": "string", - "description": "The url of the git repository.", - "format": "uri" + "black": { + "$ref": "https://json.schemastore.org/partial-black.json" }, - "branch": { - "type": "string", - "description": "The branch to checkout." + "cibuildwheel": { + "$ref": "https://json.schemastore.org/partial-cibuildwheel.json" }, - "tag": { - "type": "string", - "description": "The tag to checkout." + "mypy": { + "$ref": "https://json.schemastore.org/partial-mypy.json" }, - "rev": { - "type": "string", - "description": "The revision to checkout." + "ruff": { + "$ref": "https://json.schemastore.org/ruff.json" }, - "python": { - "type": "string", - "description": "The python versions for which the dependency should be installed." - }, - "platform": { - "type": "string", - "description": "The platform(s) for which the dependency should be installed." + "hatch": { + "$ref": "https://json.schemastore.org/hatch.json" }, - "markers": { - "type": "string", - "description": "The PEP 508 compliant environment markers for which the dependency should be installed." + "scikit-build": { + "$ref": "https://json.schemastore.org/partial-scikit-build.json" }, - "allow-prereleases": { - "type": "boolean", - "description": "Whether the dependency allows prereleases or not." + "setuptools": { + "$ref": "https://json.schemastore.org/partial-setuptools.json" }, - "allows-prereleases": { - "type": "boolean", - "description": "Whether the dependency allows prereleases or not." + "poetry": { + "$ref": "https://json.schemastore.org/partial-poetry.json" }, - "optional": { - "type": "boolean", - "description": "Whether the dependency is optional or not." + "pdm": { + "$ref": "https://json.schemastore.org/partial-pdm.json" }, - "extras": { - "type": "array", - "description": "The required extras for this dependency.", - "items": { - "type": "string" + "pyright": { + "$ref": "https://json.schemastore.org/partial-pyright.json" + } + }, + "examples": [ + { + "tool": { + "isort": { + "profile": "black" + } } } - } + ] }, - "poetry-file-dependency": { + "project": { + "$comment": "see PEP 621 (https://peps.python.org/pep-0621/)", + "title": "Project metadata", "type": "object", - "required": ["file"], "additionalProperties": false, + "required": ["name"], "properties": { - "file": { + "name": { + "title": "Project name", "type": "string", - "description": "The path to the file." + "pattern": "^([a-zA-Z\\d]|[a-zA-Z\\d][\\w.-]*[a-zA-Z\\d])$" }, - "python": { + "version": { + "title": "Project version", "type": "string", - "description": "The python versions for which the dependency should be installed." + "pattern": "^v?((([0-9]+)!)?([0-9]+(\\.[0-9]+)*)([-_\\.]?(alpha|a|beta|b|preview|pre|c|rc)[-_\\.]?([0-9]+)?)?((-([0-9]+))|([-_\\.]?(post|rev|r)[-_\\.]?([0-9]+)?))?([-_\\.]?(dev)[-_\\.]?([0-9]+)?)?)(\\+([a-z0-9]+([-_\\.][a-z0-9]+)*))?$", + "examples": ["42.0.1", "0.3.9rc7.post0.dev5"] }, - "platform": { - "type": "string", - "description": "The platform(s) for which the dependency should be installed." + "description": { + "title": "Project summary description", + "type": "string" + }, + "readme": { + "title": "Project full description", + "description": "AKA the README", + "oneOf": [ + { + "title": "README file path", + "type": "string" + }, + { + "type": "object", + "required": ["content-type"], + "properties": { + "content-type": { + "title": "README text content-type", + "description": "RFC 1341 compliant content-type (with optional charset, defaulting to UTF-8)", + "type": "string" + } + }, + "oneOf": [ + { + "additionalProperties": false, + "required": ["file"], + "properties": { + "content-type": true, + "file": { + "title": "README file path", + "type": "string" + } + } + }, + { + "additionalProperties": false, + "required": ["text"], + "properties": { + "content-type": true, + "text": { + "title": "README text", + "type": "string" + } + } + } + ] + } + ], + "examples": [ + "README.md", + { + "file": "README.txt", + "content-type": "text/plain" + }, + { + "text": "# Example project\n\nAn example project", + "content-type": "text/markdown" + } + ] }, - "markers": { + "requires-python": { + "title": "Python version compatibility", "type": "string", - "description": "The PEP 508 compliant environment markers for which the dependency should be installed." + "examples": [">= 3.7"] }, - "optional": { - "type": "boolean", - "description": "Whether the dependency is optional or not." + "license": { + "title": "Project license", + "oneOf": [ + { + "type": "object", + "additionalProperties": false, + "required": ["file"], + "properties": { + "file": { + "title": "License file path", + "type": "string" + } + } + }, + { + "type": "object", + "additionalProperties": false, + "required": ["text"], + "properties": { + "text": { + "title": "License text", + "type": "string" + } + } + }, + { + "type": "string", + "description": "A SPDX license identifier" + } + ], + "examples": [ + { + "text": "MIT" + }, + { + "file": "LICENSE" + }, + "MIT", + "LicenseRef-Proprietary" + ] }, - "extras": { + "authors": { + "title": "Project authors", "type": "array", - "description": "The required extras for this dependency.", "items": { - "type": "string" + "$ref": "#/definitions/projectAuthor" } - } - } - }, - "poetry-path-dependency": { - "type": "object", - "required": ["path"], - "additionalProperties": false, - "properties": { - "path": { - "type": "string", - "description": "The path to the dependency." - }, - "python": { - "type": "string", - "description": "The python versions for which the dependency should be installed." - }, - "platform": { - "type": "string", - "description": "The platform(s) for which the dependency should be installed." - }, - "markers": { - "type": "string", - "description": "The PEP 508 compliant environment markers for which the dependency should be installed." }, - "optional": { - "type": "boolean", - "description": "Whether the dependency is optional or not." + "maintainers": { + "title": "Project maintainers", + "type": "array", + "items": { + "$ref": "#/definitions/projectAuthor" + } }, - "extras": { + "keywords": { + "title": "Project keywords", "type": "array", - "description": "The required extras for this dependency.", "items": { "type": "string" } }, - "develop": { - "type": "boolean", - "description": "Whether to install the dependency in development mode." - } - } - }, - "poetry-url-dependency": { - "type": "object", - "required": ["url"], - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The url to the file." - }, - "python": { - "type": "string", - "description": "The python versions for which the dependency should be installed." - }, - "platform": { - "type": "string", - "description": "The platform(s) for which the dependency should be installed." - }, - "markers": { - "type": "string", - "description": "The PEP 508 compliant environment markers for which the dependency should be installed." - }, - "optional": { - "type": "boolean", - "description": "Whether the dependency is optional or not." - }, - "extras": { + "classifiers": { + "title": "Applicable Trove classifiers", "type": "array", - "description": "The required extras for this dependency.", "items": { "type": "string" } - } - } - }, - "poetry-multiple-constraints-dependency": { - "type": "array", - "minItems": 1, - "items": { - "oneOf": [ - { - "$ref": "#/definitions/poetry-dependency" + }, + "urls": { + "title": "Project URLs", + "type": "object", + "additionalProperties": { + "type": "string", + "format": "uri" }, - { - "$ref": "#/definitions/poetry-long-dependency" + "examples": [ + { + "homepage": "https://example.com/example-project" + } + ] + }, + "scripts": { + "title": "Console scripts", + "type": "object", + "additionalProperties": { + "type": "string" }, - { - "$ref": "#/definitions/poetry-git-dependency" + "examples": [ + { + "mycmd": "package.module:object.function" + } + ] + }, + "gui-scripts": { + "title": "GUI scripts", + "type": "object", + "additionalProperties": { + "type": "string" }, - { - "$ref": "#/definitions/poetry-file-dependency" + "examples": [ + { + "mycmd": "package.module:object.function" + } + ] + }, + "entry-points": { + "title": "Other entry-point groups", + "type": "object", + "additionalProperties": false, + "patternProperties": { + "^\\w+(\\.\\w+)*$": { + "type": "object", + "additionalProperties": { + "type": "string" + } + } }, - { - "$ref": "#/definitions/poetry-path-dependency" + "propertyNames": { + "not": { + "anyOf": [ + { + "const": "console_scripts" + }, + { + "const": "gui_scripts" + } + ] + } }, - { - "$ref": "#/definitions/poetry-url-dependency" - } - ] - } - }, - "poetry-scripts": { - "type": "object", - "patternProperties": { - "^[a-zA-Z-_.0-9]+$": { - "oneOf": [ + "examples": [ { - "$ref": "#/definitions/poetry-script" - }, - { - "$ref": "#/definitions/poetry-extra-script" + "pygments.styles": { + "monokai": "package.module:object.attribute" + } } ] - } - } - }, - "poetry-script": { - "type": "string", - "description": "A simple script pointing to a callable object." - }, - "poetry-extra-script": { - "type": "object", - "description": "A script that should be installed only if extras are activated.", - "additionalProperties": false, - "properties": { - "callable": { - "$ref": "#/definitions/poetry-script" }, - "extras": { + "dependencies": { + "title": "Project dependency requirements", "type": "array", - "description": "The required extras for this script.", "items": { "type": "string" - } - } - } - }, - "poetry-repository": { - "type": "object", - "additionalProperties": false, - "properties": { - "name": { - "type": "string", - "description": "The name of the repository" - }, - "url": { - "type": "string", - "description": "The url of the repository", - "format": "uri" + }, + "examples": [["attrs", "requests ~= 2.28"]] }, - "default": { - "type": "boolean", - "description": "Make this repository the default (disable PyPI)" + "optional-dependencies": { + "title": "Project extra dependency requirements", + "description": "keys are extra names", + "type": "object", + "patternProperties": { + "^([a-z\\d]|[a-z\\d]([a-z\\d-](?!--))*[a-z\\d])$": { + "type": "array", + "items": { + "type": "string" + } + } + }, + "examples": [ + { + "typing": ["boto3-stubs", "typing-extensions ~= 4.1"] + } + ] }, - "secondary": { - "type": "boolean", - "description": "Declare this repository as secondary, i.e. it will only be looked up last for packages." - } - } - }, - - "BuildSystem": { - "title": "Build System", - "type": "object", - "x-taplo": { - "links": { - "key": "https://www.python.org/dev/peps/pep-0518/#build-system-table" - } - }, - "description": "Build-related data.\n", - "required": ["requires"], - "properties": { - "requires": { - "description": "A list of strings representing [PEP 508](https://www.python.org/dev/peps/pep-0508) dependencies required to execute the build system.\n", + "dynamic": { + "title": "Dynamic metadata values", "type": "array", "items": { - "type": "string" + "type": "string", + "enum": [ + "version", + "description", + "readme", + "requires-python", + "license", + "authors", + "maintainers", + "keywords", + "classifiers", + "urls", + "scripts", + "gui-scripts", + "entry-points", + "dependencies", + "optional-dependencies" + ] }, - "x-taplo": { - "links": { - "key": "https://www.python.org/dev/peps/pep-0518/#build-system-table" + "examples": [["version"]] + } + }, + "oneOf": [ + { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "version" + } } } }, - "build-backend": { - "description": "The build backend for the package.\n", - "type": "string", - "x-taplo": { - "links": { - "key": "https://www.python.org/dev/peps/pep-0517/" - } + { + "required": ["version"], + "properties": { + "version": true } } - } - } - }, - "type": "object", - "properties": { - "build-system": { - "$ref": "#/definitions/BuildSystem" - }, - "tool": { - "type": "object", - "description": "A table for tool configurations.\n\nEvery tool that is used by the project can have its own sub-table for its configuration.\n", - "additionalProperties": true, - "x-taplo": { - "links": { - "key": "https://www.python.org/dev/peps/pep-0518/#id28" - } - }, - "properties": { - "poetry": { - "name": "Package", - "type": "object", - "additionalProperties": false, - "required": ["name", "version", "description"], - "properties": { - "name": { - "type": "string", - "description": "Package name." - }, - "version": { - "type": "string", - "description": "Version of the package. It should follow semantic versioning, but it is not enforced." - }, - "description": { - "type": "string", - "description": "Short package description." - }, - "keywords": { - "type": "array", - "items": { - "type": "string", - "description": "A tag/keyword that this package relates to." + ], + "dependencies": { + "version": { + "not": { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "version" + } } - }, - "homepage": { - "type": "string", - "description": "Homepage URL for the project.", - "format": "uri" - }, - "repository": { - "type": "string", - "description": "Repository URL for the project.", - "format": "uri" - }, - "documentation": { - "type": "string", - "description": "Documentation URL for the project.", - "format": "uri" - }, - "license": { - "type": "string", - "description": "License name." - }, - "authors": { - "$ref": "#/definitions/poetry-authors" - }, - "maintainers": { - "$ref": "#/definitions/poetry-maintainers" - }, - "readme": { - "type": "string", - "description": "The path to the README file" - }, - "classifiers": { - "type": "array", - "description": "A list of trove classifers." - }, - "packages": { - "type": "array", - "description": "A list of packages to include in the final distribution.", - "items": { - "type": "object", - "description": "Information about where the package resides.", - "additionalProperties": false, - "required": ["include"], - "properties": { - "include": { - "type": "string", - "description": "What to include in the package." - }, - "from": { - "type": "string", - "description": "Where the source directory of the package resides." - }, - "format": { - "oneOf": [ - { - "type": "string" - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ], - "description": "The format(s) for which the package must be included." - } + } + } + }, + "description": { + "not": { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "description" } } - }, - "include": { - "type": "array", - "description": "A list of files and folders to include." - }, - "exclude": { - "type": "array", - "description": "A list of files and folders to exclude." - }, - "dependencies": { - "type": "object", - "description": "This is a hash of package name (keys) and version constraints (values) that are required to run this package.", - "required": ["python"], - "properties": { - "python": { - "type": "string", - "description": "The Python versions the package is compatible with.", - "$ref": "#/definitions/poetry-dependency" + } + } + }, + "readme": { + "not": { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "readme" } - }, - "patternProperties": { - "^[a-zA-Z-_.0-9]+$": { - "$ref": "#/definitions/poetry-dependency-any" + } + } + } + }, + "requires-python": { + "not": { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "requires-python" } } - }, - "dev-dependencies": { - "type": "object", - "description": "This is a hash of package name (keys) and version constraints (values) that this package requires for developing it (testing tools and such).", - "patternProperties": { - "^[a-zA-Z-_.0-9]+$": { - "$ref": "#/definitions/poetry-dependency-any" + } + } + }, + "license": { + "not": { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "license" } } - }, - "extras": { - "type": "object", - "patternProperties": { - "^[a-zA-Z-_.0-9]+$": { - "type": "array", - "items": { - "type": "string" - } + } + } + }, + "authors": { + "not": { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "authors" } } - }, - "build": { - "type": "string", - "description": "The file used to build extensions." - }, - "source": { - "type": "array", - "description": "A set of additional repositories where packages can be found.", - "additionalProperties": { - "$ref": "#/definitions/poetry-repository" - }, - "items": { - "$ref": "#/definitions/poetry-repository" + } + } + }, + "maintainers": { + "not": { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "maintainers" + } } - }, - "scripts": { - "type": "object", - "description": "A hash of scripts to be installed.", - "items": { - "type": "string" + } + } + }, + "keywords": { + "not": { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "keywords" + } } - }, - "plugins": { - "type": "object", - "description": "A hash of hashes representing plugins", - "patternProperties": { - "^[a-zA-Z-_.0-9]+$": { - "type": "object", - "patternProperties": { - "^[a-zA-Z-_.0-9]+$": { - "type": "string" - } - } + } + } + }, + "classifiers": { + "not": { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "classifiers" } } - }, - "urls": { - "type": "object", - "patternProperties": { - "^.+$": { - "type": "string", - "description": "The full url of the custom url." + } + } + }, + "urls": { + "not": { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "urls" + } + } + } + } + }, + "scripts": { + "not": { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "scripts" + } + } + } + } + }, + "gui-scripts": { + "not": { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "gui-scripts" + } + } + } + } + }, + "entry-points": { + "not": { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "entry-points" + } + } + } + } + }, + "dependencies": { + "not": { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "dependencies" + } + } + } + } + }, + "optional-dependencies": { + "not": { + "required": ["dynamic"], + "properties": { + "dynamic": { + "type": "array", + "contains": { + "const": "optional-dependencies" } } } @@ -585,5 +631,10 @@ } } }, - "additionalProperties": true + "title": "JSON schema for Python project metadata and configuration", + "type": "object", + "x-taplo-info": { + "authors": ["zevisert (https://github.com/zevisert)"], + "pattern": ["^(.*(/|\\\\)pyproject\\.toml|pyproject\\.toml)$"] + } } diff --git a/site/site/public/schemas/replit.toml.json b/site/site/public/schemas/replit.toml.json index 7bb7b6919..157fabcdc 100644 --- a/site/site/public/schemas/replit.toml.json +++ b/site/site/public/schemas/replit.toml.json @@ -1,218 +1,225 @@ { - "$schema": "http://json-schema.org/draft-07/schema", - "title": "Repl.it config schema (.replit)", - "description": "https://docs.replit.com/programming-ide/configuring-repl", - "x-taplo-info": { - "authors": ["Emily Grace Seville (https://github.com/EmilySeville7cfg)"], - "patterns": ["\\.replit(?:\\.toml)?$"] + "$schema": "http://json-schema.org/draft-07/schema#", + "$id": "https://json.schemastore.org/replit.json", + "additionalProperties": false, + "description": "https://docs.replit.com/programming-ide/configuring-repl", + "properties": { + "run": { + "description": "Command to run REPL", + "anyOf": [ + { + "type": "string" + }, + { + "type": "array", + "items": { + "type": "string" + } + } + ] }, - "type": "object", - "properties": { - "run": { - "description": "Command to run REPL", - "type": ["string", "array"], - "items": { - "type": "string" - } + "language": { + "$comment": "List is taken from https://replit.com/talk/learn/How-to-Get-a-List-of-All-Replit-Langauges/34411", + "description": "Language name used in REPL", + "type": "string", + "enum": [ + "clojure", + "haskell", + "kotlin", + "qbasic", + "forth", + "lolcode", + "brainf***", + "emoticon", + "bloop", + "react_native", + "unlambda", + "javascript", + "babel", + "coffeescript", + "scheme", + "apl", + "lua", + "python", + "ruby", + "roy", + "php", + "python3", + "nodejs", + "enzyme", + "go", + "java", + "cpp", + "cpp11", + "c", + "csharp", + "fsharp", + "web_project", + "html", + "rust", + "swift", + "python_turtle", + "basic", + "jest", + "django", + "express", + "sinatra", + "rails", + "rlang", + "nextjs", + "gatsbyjs", + "reactjs", + "reactts", + "reactre", + "flow", + "bash", + "quil", + "polygott", + "crystal", + "julia", + "perl6", + "elixir", + "nim", + "dart", + "gatsbyjsv2", + "reason_nodejs", + "tcl", + "erlang", + "typescript", + "ocaml", + "pygame", + "love2d", + "reason", + "Tkinter", + "tkinter", + "java_swing", + "php_server", + "nodejs_prybar", + "elisp", + "php7", + "sqlite", + "java10", + "php_cli", + "nodejs_beta", + "pyxel", + "static", + "go_beta", + "nodejs_static", + "python3_beta", + "raku", + "testj", + "wasm", + "java10_beta", + "python_beta", + "html_beta", + "testj_beta", + "scala", + "riddlejs", + "java_maven" + ] + }, + "audio": { + "description": "Enable/disable system-wide audio in REPL", + "type": "boolean" + }, + "packager": { + "description": "Universal Package Manager (UPM) configuration", + "type": "object", + "properties": { + "afterInstall": { + "description": "Command to run on new package install", + "type": "string" }, - "language": { - "description": "Language name used in REPL", + "ignoredPaths": { + "description": "List of ignored path", + "type": "array", + "items": { "type": "string", - "$comment": "List is taken from https://replit.com/talk/learn/How-to-Get-a-List-of-All-Replit-Langauges/34411", - "enum": [ - "clojure", - "haskell", - "kotlin", - "qbasic", - "forth", - "lolcode", - "brainf***", - "emoticon", - "bloop", - "react_native", - "unlambda", - "javascript", - "babel", - "coffeescript", - "scheme", - "apl", - "lua", - "python", - "ruby", - "roy", - "php", - "python3", - "nodejs", - "enzyme", - "go", - "java", - "cpp", - "cpp11", - "c", - "csharp", - "fsharp", - "web_project", - "html", - "rust", - "swift", - "python_turtle", - "basic", - "jest", - "django", - "express", - "sinatra", - "rails", - "rlang", - "nextjs", - "gatsbyjs", - "reactjs", - "reactts", - "reactre", - "flow", - "bash", - "quil", - "polygott", - "crystal", - "julia", - "perl6", - "elixir", - "nim", - "dart", - "gatsbyjsv2", - "reason_nodejs", - "tcl", - "erlang", - "typescript", - "ocaml", - "pygame", - "love2d", - "reason", - "Tkinter", - "tkinter", - "java_swing", - "php_server", - "nodejs_prybar", - "elisp", - "php7", - "sqlite", - "java10", - "php_cli", - "nodejs_beta", - "pyxel", - "static", - "go_beta", - "nodejs_static", - "python3_beta", - "raku", - "testj", - "wasm", - "java10_beta", - "python_beta", - "html_beta", - "testj_beta", - "scala", - "riddlejs", - "java_maven" - ] + "minLength": 1 + }, + "uniqueItems": true, + "minItems": 1 }, - "audio": { - "description": "Enable/disable system-wide audio in REPL", - "type": "boolean" + "ignoredPackages": { + "description": "List of ignored packages", + "type": "array", + "items": { + "type": "string", + "minLength": 1 + }, + "uniqueItems": true, + "minItems": 1 }, - "packager": { - "description": "Universal Package Manager (UPM) configuration", - "type": "object", - "properties": { - "afterInstall": { - "description": "Command to run on new package install", - "type": "string" - }, - "ignoredPaths": { - "description": "List of ignored path", - "type": "array", - "items": { - "type": "string", - "minLength": 1 - }, - "uniqueItems": true, - "minItems": 1 - }, - "ignoredPackages": { - "description": "List of ignored packages", - "type": "array", - "items": { - "type": "string", - "minLength": 1 - }, - "uniqueItems": true, - "minItems": 1 - }, - "language": { - "description": "Language name", - "type": "string", - "enum": [ - "python-python3-poetry", - "python-python2-poetry", - "nodejs-npm", - "nodejs-yarn", - "ruby-bundler", - "elisp-cask", - "dart-pub", - "java-maven", - "rlang", - "dotnet", - "rust" - ] - }, - "features": { - "description": "Universal Package Manager (UPM) features", - "type": "object", - "properties": { - "packageSearch": { - "description": "Enable/disable package search panel", - "type": "boolean" - }, - "guessImports": { - "description": "Enable/disable guessing required packages", - "type": "boolean" - } - }, - "additionalProperties": false - } - }, - "additionalProperties": false + "language": { + "description": "Language name", + "type": "string", + "enum": [ + "python-python3-poetry", + "python-python2-poetry", + "nodejs-npm", + "nodejs-yarn", + "ruby-bundler", + "elisp-cask", + "dart-pub", + "java-maven", + "rlang", + "dotnet", + "rust" + ] }, - "languages": { - "description": "Language configuration", - "type": "object", - "patternProperties": { - ".": { - "description": "Language configuration", - "type": "object", - "properties": { - "glob": { - "description": "Glob for language files", - "type": "string", - "minLength": 1 - }, - "languageServer": { - "description": "Language Server Protocol (LSP) configuration", - "type": "object", - "properties": { - "start": { - "description": "Command to run server", - "type": "string" - } - }, - "additionalProperties": false - } - }, - "additionalProperties": false - } + "features": { + "description": "Universal Package Manager (UPM) features", + "type": "object", + "properties": { + "packageSearch": { + "description": "Enable/disable package search panel", + "type": "boolean" }, - "additionalProperties": false + "guessImports": { + "description": "Enable/disable guessing required packages", + "type": "boolean" + } + }, + "additionalProperties": false } + }, + "additionalProperties": false }, - "additionalProperties": false + "languages": { + "description": "Language configuration", + "type": "object", + "patternProperties": { + ".": { + "description": "Language configuration", + "type": "object", + "properties": { + "glob": { + "description": "Glob for language files", + "type": "string", + "minLength": 1 + }, + "languageServer": { + "description": "Language Server Protocol (LSP) configuration", + "type": "object", + "properties": { + "start": { + "description": "Command to run server", + "type": "string" + } + }, + "additionalProperties": false + } + }, + "additionalProperties": false + } + }, + "additionalProperties": false + } + }, + "title": "Repl.it config schema (.replit)", + "type": "object", + "x-taplo-info": { + "authors": ["Emily Grace Seville (https://github.com/EmilySeville7cfg)"], + "patterns": ["\\.replit(?:\\.toml)?$"] + } } - diff --git a/site/site/public/schemas/rust-toolchain.toml.json b/site/site/public/schemas/rust-toolchain.toml.json index 4de85554b..6f224861f 100644 --- a/site/site/public/schemas/rust-toolchain.toml.json +++ b/site/site/public/schemas/rust-toolchain.toml.json @@ -1,346 +1,420 @@ { - "$schema": "http://json-schema.org/draft-07/schema", - "title": "Schema for rust-toolchain.toml", + "$schema": "http://json-schema.org/draft-07/schema#", + "$id": "https://json.schemastore.org/rust-toolchain.json", "description": "https://rust-lang.github.io/rustup/overrides.html#the-toolchain-file", - "x-taplo-info": { - "authors": [ - "ian-h-chamberlain (https://github.com/ian-h-chamberlain)" - ], - "patterns": [ - "^(.*(/|\\\\)rust-toolchain([.]toml)?)$" - ] - }, "properties": { "toolchain": { - "description": "A \"toolchain\" is a complete installation of the Rust\ncompiler (`rustc`) and related tools (like `cargo`). A toolchain\nspecification includes the release channel or version, and the host\nplatform that the toolchain runs on.", + "description": "A `toolchain` is a complete installation of the Rust compiler (`rustc`) and related tools (like `cargo`). A toolchain specification includes the release channel or version, and the host platform that the toolchain runs on.\n\n Get more from [`Toolchains`](https://rust-lang.github.io/rustup/concepts/toolchains.html)", "type": "object", "minProperties": 1, + "properties": { + "channel": { + "description": "`channel` is a named release channel, a major and minor version number such as `1.42`, or a fully specified version number, such as `1.42.0`. Channel names can be optionally appended with an archive date, as in `nightly-2014-12-18`, in which case the toolchain is downloaded from the archive for that date. Get more from [`Toolchain specification`](https://rust-lang.github.io/rustup/concepts/toolchains.html).\n\nOther valid channel like `stable`,`1.63`,`1.63.0`,`nightly-2022-09-20`,`stable-x86_64-pc-windows-msvc`,`1.63.0-riscv64gc-unknown-linux-gnu`,`nightly-2022-09-20-x86_64-unknown-nux-gnu`", + "type": "string", + "pattern": "^(?:stable|beta|nightly|\\d+(?:\\.\\d+){1,2})(?:-\\d{4}(?:-\\d{2}){2})?(?:-\\D[^-]*(?:(?:-(?:[^-]+)){1,3}))?$", + "examples": [ + "stable", + "1.63", + "1.63.0", + "nightly-2022-09-20", + "stable-x86_64-pc-windows-msvc", + "1.63.0-riscv64gc-unknown-linux-gnu", + "nightly-2022-09-20-x86_64-unknown-linux-gnu" + ], + "x-taplo": { + "links": { + "key": "https://rust-lang.github.io/rustup/concepts/channels.html" + } + } + }, + "components": { + "description": "Each release of Rust includes several \"components\", some of\nwhich are required (like `rustc`) and some that are optional (like [`clippy`](https://github.com/rust-lang/rust-clippy)) \n\n Learn more from [`Components`](https://rust-lang.github.io/rustup/concepts/components.html)", + "type": "array", + "items": { + "$comment": "Empty schema to allow for forward compatibility of new components", + "type": "string", + "enum": [ + "rustc", + "cargo", + "rustfmt", + "rust-std", + "rust-docs", + "rls", + "clippy", + "miri", + "rust-src", + "rust", + "rust-analysis", + "llvm-tools", + "rustc-docs", + "rustc-dev", + "rust-analyzer", + "reproducible-artifacts", + "rust-docs-json" + ], + "x-taplo": { + "docs": { + "enumValues": [ + "The Rust compiler and [Rustdoc].\n\n[rustdoc]: https://doc.rust-lang.org/rustdoc/", + "[Cargo] is a package manager and build tool.\n\n[cargo]: https://doc.rust-lang.org/cargo/", + "[Rustfmt] is a tool for automatically formatting code.\n\n[rustfmt]: https://github.com/rust-lang/rustfmt", + "This is the Rust [standard library]. There is a separate\n `rust-std` component for each target that `rustc` supports, such as\n `rust-std-x86_64-pc-windows-msvc`. See the [Cross-compilation] chapter for\n more detail.\n\n[standard library]: https://doc.rust-lang.org/std/\n[cross-compilation]: .https://rust-lang.github.io/rustup/cross-compilation.html", + "This is a local copy of the [Rust documentation]. Use the\n `rustup doc` command to open the documentation in a web browser. Run `rustup\n doc --help` for more options.\n\n[rust documentation]: https://doc.rust-lang.org/", + "[RLS] is a language server that provides support for editors and\n IDEs.\n\n[RLS]: https://github.com/rust-lang/rls", + "[Clippy] is a lint tool that provides extra checks for common\n mistakes and stylistic choices.\n\n[clippy]: https://github.com/rust-lang/rust-clippy", + "[Miri] is an experimental Rust interpreter, which can be used for\n checking for undefined-behavior.\n\n[miri]: https://github.com/rust-lang/miri/", + "This is a local copy of the source code of the Rust standard\n library. This can be used by some tools, such as [RLS], to provide\n auto-completion for functions within the standard library; [Miri] which is a\n Rust interpreter; and Cargo's experimental [build-std] feature, which allows\n you to rebuild the standard library locally.\n\n[RLS]: https://github.com/rust-lang/rls\n[miri]: https://github.com/rust-lang/miri/\n[build-std]: https://doc.rust-lang.org/nightly/cargo/reference/unstable.html#build-std", + "Metadata about the standard library, used by tools like\n [RLS].\n\n[RLS]: https://github.com/rust-lang/rls", + "This contains a linker and platform libraries for building on\n the `x86_64-pc-windows-gnu` platform.", + "This is an experimental component which contains a\n collection of [LLVM] tools.\n\n[LLVM]: https://llvm.org/", + "This component contains the compiler as a library. Most users\n will not need this; it is only needed for development *of* tools that link\n to the compiler, such as making modifications to [Clippy].\n\n[clippy]: https://github.com/rust-lang/rust-clippy" + ] + } + } + }, + "x-taplo": { + "links": { + "key": "https://rust-lang.github.io/rustup/concepts/components.html" + } + } + }, + "targets": { + "$comment": "Allow arbitrary strings for new targets or custom target JSON", + "description": "`rustc` is capable of generating code for many platforms. The `target` specifies the platform that the code will be generated for. By default, `cargo` and `rustc` use the host toolchain's platform as the target. To build for a different `target`, usually the target's standard library needs to be installed first via the `rustup target` command. Or you can run `rustc --print target-list` to list [`\"built-in\" targets`](https://doc.rust-lang.org/rustc/targets/built-in.html) \n\n Get more from [`Platform Support`](https://doc.rust-lang.org/rustc/platform-support.html) and [`Targets`](https://doc.rust-lang.org/rustc/targets/index.html)", + "type": "array", + "items": { + "$comment": "From `rustc +nightly --print target-list` or targets listed in https://doc.rust-lang.org/rustc/platform-support.html or https://github.com/rust-lang/rust/blob/master/src/doc/rustc/src/platform-support.md", + "type": "string", + "enum": [ + "aarch64-unknown-linux-gnu", + "i686-pc-windows-gnu", + "i686-pc-windows-msvc", + "i686-unknown-linux-gnu", + "x86_64-apple-darwin", + "x86_64-pc-windows-gnu", + "x86_64-pc-windows-msvc", + "x86_64-unknown-linux-gnu", + "aarch64-apple-darwin", + "aarch64-pc-windows-msvc", + "aarch64-unknown-linux-musl", + "arm-unknown-linux-gnueabi", + "arm-unknown-linux-gnueabihf", + "armv7-unknown-linux-gnueabihf", + "loongarch64-unknown-linux-gnu", + "mips-unknown-linux-gnu", + "mips64-unknown-linux-gnuabi64", + "mips64el-unknown-linux-gnuabi64", + "mipsel-unknown-linux-gnu", + "powerpc-unknown-linux-gnu", + "powerpc64-unknown-linux-gnu", + "powerpc64le-unknown-linux-gnu", + "riscv64gc-unknown-linux-gnu", + "s390x-unknown-linux-gnu", + "x86_64-unknown-freebsd", + "x86_64-unknown-illumos", + "x86_64-unknown-linux-musl", + "x86_64-unknown-netbsd", + "aarch64-apple-ios", + "aarch64-apple-ios-sim", + "aarch64-fuchsia", + "aarch64-unknown-fuchsia", + "aarch64-linux-android", + "aarch64-unknown-none-softfloat", + "aarch64-unknown-none", + "aarch64-unknown-uefi", + "arm-linux-androideabi", + "arm-unknown-linux-musleabi", + "arm-unknown-linux-musleabihf", + "armebv7r-none-eabi", + "armebv7r-none-eabihf", + "armv5te-unknown-linux-gnueabi", + "armv5te-unknown-linux-musleabi", + "armv7-linux-androideabi", + "armv7-unknown-linux-gnueabi", + "armv7-unknown-linux-musleabi", + "armv7-unknown-linux-musleabihf", + "armv7a-none-eabi", + "armv7r-none-eabi", + "armv7r-none-eabihf", + "asmjs-unknown-emscripten", + "i586-pc-windows-msvc", + "i586-unknown-linux-gnu", + "i586-unknown-linux-musl", + "i686-linux-android", + "i686-unknown-freebsd", + "i686-unknown-linux-musl", + "i686-unknown-uefi", + "mips-unknown-linux-musl", + "mips64-unknown-linux-muslabi64", + "mips64el-unknown-linux-muslabi64", + "mipsel-unknown-linux-musl", + "nvptx64-nvidia-cuda", + "riscv32i-unknown-none-elf", + "riscv32imac-unknown-none-elf", + "riscv32imc-unknown-none-elf", + "riscv64gc-unknown-none-elf", + "riscv64imac-unknown-none-elf", + "sparc64-unknown-linux-gnu", + "sparcv9-sun-solaris", + "thumbv6m-none-eabi", + "thumbv7em-none-eabi", + "thumbv7em-none-eabihf", + "thumbv7m-none-eabi", + "thumbv7neon-linux-androideabi", + "thumbv7neon-unknown-linux-gnueabihf", + "thumbv8m.base-none-eabi", + "thumbv8m.main-none-eabi", + "thumbv8m.main-none-eabihf", + "wasm32-unknown-emscripten", + "wasm32-unknown-unknown", + "wasm32-wasi", + "wasm32-wasi-preview1-threads", + "x86_64-apple-ios", + "x86_64-fortanix-unknown-sgx", + "x86_64-fuchsia", + "x86_64-unknown-fuchsia", + "x86_64-linux-android", + "x86_64-pc-solaris", + "x86_64-unknown-linux-gnux32", + "x86_64-unknown-none", + "x86_64-unknown-redox", + "x86_64-unknown-uefi", + "aarch64-apple-ios-macabi", + "aarch64-apple-tvos", + "aarch64-apple-watchos-sim", + "aarch64-kmc-solid_asp3", + "aarch64-nintendo-switch-freestanding", + "aarch64-pc-windows-gnullvm", + "aarch64-unknown-linux-ohos", + "aarch64-unknown-teeos", + "aarch64-unknown-nto-qnx710", + "aarch64-unknown-freebsd", + "aarch64-unknown-hermit", + "aarch64-unknown-linux-gnu_ilp32", + "aarch64-unknown-netbsd", + "aarch64-unknown-openbsd", + "aarch64-unknown-redox", + "aarch64-uwp-windows-msvc", + "aarch64-wrs-vxworks", + "aarch64_be-unknown-linux-gnu_ilp32", + "aarch64_be-unknown-linux-gnu", + "aarch64_be-unknown-netbsd", + "arm64_32-apple-watchos", + "armeb-unknown-linux-gnueabi", + "armv4t-none-eabi", + "armv4t-unknown-linux-gnueabi", + "armv5te-none-eabi", + "armv5te-unknown-linux-uclibceabi", + "armv6-unknown-freebsd", + "armv6-unknown-netbsd-eabihf", + "armv6k-nintendo-3ds", + "armv7-apple-ios", + "armv7-sony-vita-newlibeabihf", + "armv7-unknown-linux-ohos", + "armv7-unknown-linux-uclibceabi", + "armv7-unknown-linux-uclibceabihf", + "armv7-unknown-freebsd", + "armv7-unknown-netbsd-eabihf", + "armv7-wrs-vxworks-eabihf", + "armv7a-kmc-solid_asp3-eabi", + "armv7a-kmc-solid_asp3-eabihf", + "armv7a-none-eabihf", + "armv7k-apple-watchos", + "armv7s-apple-ios", + "avr-unknown-gnu-atmega328", + "bpfeb-unknown-none", + "bpfel-unknown-none", + "csky-unknown-linux-gnuabiv2", + "hexagon-unknown-linux-musl", + "i386-apple-ios", + "i586-pc-nto-qnx700", + "i686-apple-darwin", + "i686-pc-windows-gnullvm", + "i686-unknown-haiku", + "i686-unknown-hurd-gnu", + "i686-unknown-netbsd", + "i686-unknown-openbsd", + "i686-uwp-windows-gnu", + "i686-uwp-windows-msvc", + "i686-wrs-vxworks", + "loongarch64-unknown-none", + "loongarch64-unknown-none-softfloat", + "m68k-unknown-linux-gnu", + "mips-unknown-linux-uclibc", + "mips64-openwrt-linux-musl", + "mipsel-sony-psp", + "mipsel-sony-psx", + "mipsel-unknown-linux-uclibc", + "mipsel-unknown-none", + "mipsisa32r6-unknown-linux-gnu", + "mipsisa32r6el-unknown-linux-gnu", + "mipsisa64r6-unknown-linux-gnuabi64", + "mipsisa64r6el-unknown-linux-gnuabi64", + "msp430-none-elf", + "powerpc-unknown-linux-gnuspe", + "powerpc-unknown-linux-musl", + "powerpc-unknown-netbsd", + "powerpc-unknown-openbsd", + "powerpc-wrs-vxworks-spe", + "powerpc-wrs-vxworks", + "powerpc64-unknown-freebsd", + "powerpc64le-unknown-freebsd", + "powerpc-unknown-freebsd", + "powerpc64-unknown-linux-musl", + "powerpc64-wrs-vxworks", + "powerpc64le-unknown-linux-musl", + "powerpc64-unknown-openbsd", + "powerpc64-ibm-aix", + "riscv32gc-unknown-linux-gnu", + "riscv32gc-unknown-linux-musl", + "riscv32im-unknown-none-elf", + "riscv32imac-unknown-xous-elf", + "riscv32imc-esp-espidf", + "riscv32imac-esp-espidf", + "riscv64gc-unknown-hermit", + "riscv64gc-unknown-freebsd", + "riscv64gc-unknown-fuchsia", + "riscv64gc-unknown-linux-musl", + "riscv64gc-unknown-netbsd", + "riscv64gc-unknown-openbsd", + "riscv64-linux-android", + "s390x-unknown-linux-musl", + "sparc-unknown-linux-gnu", + "sparc-unknown-none-elf", + "sparc64-unknown-netbsd", + "sparc64-unknown-openbsd", + "thumbv4t-none-eabi", + "thumbv5te-none-eabi", + "thumbv7a-pc-windows-msvc", + "thumbv7a-uwp-windows-msvc", + "thumbv7neon-unknown-linux-musleabihf", + "wasm64-unknown-unknown", + "x86_64-apple-ios-macabi", + "x86_64-apple-tvos", + "x86_64-apple-watchos-sim", + "x86_64-pc-nto-qnx710", + "x86_64-pc-windows-gnullvm", + "x86_64-sun-solaris", + "x86_64-unikraft-linux-musl", + "x86_64-unknown-dragonfly", + "x86_64-unknown-haiku", + "x86_64-unknown-hermit", + "x86_64-unknown-l4re-uclibc", + "x86_64-unknown-linux-ohos", + "x86_64-unknown-openbsd", + "x86_64-uwp-windows-gnu", + "x86_64-uwp-windows-msvc", + "x86_64-wrs-vxworks", + "x86_64h-apple-darwin" + ] + }, + "x-taplo": { + "links": { + "key": "https://rust-lang.github.io/rustup/cross-compilation.html" + } + } + }, + "profile": { + "description": "[`Profiles`](https://rust-lang.github.io/rustup/concepts/profiles.htm) are groups of [`components`](https://rust-lang.github.io/rustup/concepts/components.html) you can choose to download while installing a new Rust [`toolchain`](https://rust-lang.github.io/rustup/concepts/toolchains.html).\n\n The `profiles` available at this time are `minimal`, `default`, and `complete`.", + "type": "string", + "default": "default", + "enum": ["minimal", "default", "complete"], + "x-taplo": { + "links": { + "key": "https://rust-lang.github.io/rustup/concepts/profiles.html" + }, + "docs": { + "enumValues": [ + "This profile includes as few components as possible to get a\nworking compiler (`rustc`, `rust-std`, and `cargo`). It's recommended to use\nthis component on Windows systems if you don't use local documentation (the\nlarge number of files can cause issues with some Antivirus systems), and in\nCI.", + "This profile includes all of components in the **minimal**\nprofile, and adds `rust-docs`, `rustfmt`, and `clippy`. This profile will be\nused by `rustup` by default, and it's the one recommended for general use.", + "This profile includes all the components available through\n`rustup`. This should never be used, as it includes *every* component ever\nincluded in the metadata and thus will almost always fail. If you are\nlooking for a way to install devtools such as `miri` or IDE integration\ntools (`rls`), you should use the `default` profile and\ninstall the needed additional components manually, either by using `rustup\ncomponent add` or by using `-c` when installing the toolchain." + ] + } + } + }, + "path": { + "type": "string", + "description": "Path to a custom local toolchain. Since a `path` directive directly names a local toolchain, other options\nlike `components`, `targets`, and `profile` have no effect. `channel`\nand `path` are mutually exclusive, since a `path` already points to a\nspecific toolchain. A relative `path` is resolved relative to the\nlocation of the `rust-toolchain.toml` file.\n\n Learn more from [`Custom toolchains`](https://rust-lang.github.io/rustup/concepts/toolchains.html#custom-toolchains)" + } + }, "oneOf": [ { - "properties": { - "channel": { - "description": "Rust is released to three different \"channels\": stable, beta,\nand nightly.", - "type": "string", - "oneOf": [ - { - "enum": [ - "stable", - "beta", - "nightly" - ] - }, - { - "$comment": "Empty schema allows for custom rustup toolchains, specific nightlies, etc." - } - ], - "x-taplo": { - "links": { - "key": "https://rust-lang.github.io/rustup/concepts/channels.html" - } + "not": { + "properties": { + "path": { + "type": "string" } }, - "components": { - "description": "Each release of Rust includes several \"components\", some of\nwhich are required (like `rustc`) and some that are optional (like\n[`clippy`][clippy]).\n\n[clippy]: https://github.com/rust-lang/rust-clippy", - "type": "array", - "items": { - "type": "string", - "oneOf": [ - { - "enum": [ - "rustc", - "cargo", - "rustfmt", - "rust-std", - "rust-docs", - "rls", - "clippy", - "miri", - "rust-src", - "rust-analysis", - "rust-mingw", - "llvm-tools-preview", - "rustc-dev" - ], - "x-taplo": { - "docs": { - "enumValues": [ - "The Rust compiler and [Rustdoc].\n\n[rustdoc]: https://doc.rust-lang.org/rustdoc/", - "[Cargo] is a package manager and build tool.\n\n[cargo]: https://doc.rust-lang.org/cargo/", - "[Rustfmt] is a tool for automatically formatting code.\n\n[rustfmt]: https://github.com/rust-lang/rustfmt", - "This is the Rust [standard library]. There is a separate\n `rust-std` component for each target that `rustc` supports, such as\n `rust-std-x86_64-pc-windows-msvc`. See the [Cross-compilation] chapter for\n more detail.\n\n[standard library]: https://doc.rust-lang.org/std/\n[cross-compilation]: .https://rust-lang.github.io/rustup/cross-compilation.html", - "This is a local copy of the [Rust documentation]. Use the\n `rustup doc` command to open the documentation in a web browser. Run `rustup\n doc --help` for more options.\n\n[rust documentation]: https://doc.rust-lang.org/", - "[RLS] is a language server that provides support for editors and\n IDEs.\n\n[RLS]: https://github.com/rust-lang/rls", - "[Clippy] is a lint tool that provides extra checks for common\n mistakes and stylistic choices.\n\n[clippy]: https://github.com/rust-lang/rust-clippy", - "[Miri] is an experimental Rust interpreter, which can be used for\n checking for undefined-behavior.\n\n[miri]: https://github.com/rust-lang/miri/", - "This is a local copy of the source code of the Rust standard\n library. This can be used by some tools, such as [RLS], to provide\n auto-completion for functions within the standard library; [Miri] which is a\n Rust interpreter; and Cargo's experimental [build-std] feature, which allows\n you to rebuild the standard library locally.\n\n[RLS]: https://github.com/rust-lang/rls\n[miri]: https://github.com/rust-lang/miri/\n[build-std]: https://doc.rust-lang.org/nightly/cargo/reference/unstable.html#build-std", - "Metadata about the standard library, used by tools like\n [RLS].\n\n[RLS]: https://github.com/rust-lang/rls", - "This contains a linker and platform libraries for building on\n the `x86_64-pc-windows-gnu` platform.", - "This is an experimental component which contains a\n collection of [LLVM] tools.\n\n[LLVM]: https://llvm.org/", - "This component contains the compiler as a library. Most users\n will not need this; it is only needed for development *of* tools that link\n to the compiler, such as making modifications to [Clippy].\n\n[clippy]: https://github.com/rust-lang/rust-clippy" - ] - } - } - }, - { - "$comment": "Empty schema to allow for forward compatibility of new components" - } - ] - }, - "x-taplo": { - "links": { - "key": "https://rust-lang.github.io/rustup/concepts/components.html" - } + "required": ["path"] + } + }, + { + "required": ["path"] + } + ], + "dependencies": { + "path": { + "not": { + "properties": { + "channel": { + "type": "string" } }, - "targets": { - "description": "`rustc` is capable of generating code for many platforms. The\n\"target\" specifies the platform that the code will be generated for. By\ndefault, `cargo` and `rustc` use the host toolchain's platform as the\ntarget. To build for a different target, usually the target's standard\nlibrary needs to be installed first via the `rustup target` command.", - "type": "array", - "items": { - "oneOf": [ - { - "$comment": "Allow arbitary strings for new targets or custom target JSON", - "type": "string" - }, - { - "$comment": "From `rustc +nightly --print target-list`", - "enum": [ - "aarch64-apple-darwin", - "aarch64-apple-ios", - "aarch64-apple-ios-macabi", - "aarch64-apple-ios-sim", - "aarch64-apple-tvos", - "aarch64-fuchsia", - "aarch64-kmc-solid_asp3", - "aarch64-linux-android", - "aarch64-pc-windows-msvc", - "aarch64-unknown-freebsd", - "aarch64-unknown-hermit", - "aarch64-unknown-linux-gnu", - "aarch64-unknown-linux-gnu_ilp32", - "aarch64-unknown-linux-musl", - "aarch64-unknown-netbsd", - "aarch64-unknown-none", - "aarch64-unknown-none-softfloat", - "aarch64-unknown-openbsd", - "aarch64-unknown-redox", - "aarch64-unknown-uefi", - "aarch64-uwp-windows-msvc", - "aarch64-wrs-vxworks", - "aarch64_be-unknown-linux-gnu", - "aarch64_be-unknown-linux-gnu_ilp32", - "arm-linux-androideabi", - "arm-unknown-linux-gnueabi", - "arm-unknown-linux-gnueabihf", - "arm-unknown-linux-musleabi", - "arm-unknown-linux-musleabihf", - "armebv7r-none-eabi", - "armebv7r-none-eabihf", - "armv4t-unknown-linux-gnueabi", - "armv5te-unknown-linux-gnueabi", - "armv5te-unknown-linux-musleabi", - "armv5te-unknown-linux-uclibceabi", - "armv6-unknown-freebsd", - "armv6-unknown-netbsd-eabihf", - "armv6k-nintendo-3ds", - "armv7-apple-ios", - "armv7-linux-androideabi", - "armv7-unknown-freebsd", - "armv7-unknown-linux-gnueabi", - "armv7-unknown-linux-gnueabihf", - "armv7-unknown-linux-musleabi", - "armv7-unknown-linux-musleabihf", - "armv7-unknown-linux-uclibceabihf", - "armv7-unknown-netbsd-eabihf", - "armv7-wrs-vxworks-eabihf", - "armv7a-kmc-solid_asp3-eabi", - "armv7a-kmc-solid_asp3-eabihf", - "armv7a-none-eabi", - "armv7a-none-eabihf", - "armv7r-none-eabi", - "armv7r-none-eabihf", - "armv7s-apple-ios", - "asmjs-unknown-emscripten", - "avr-unknown-gnu-atmega328", - "bpfeb-unknown-none", - "bpfel-unknown-none", - "hexagon-unknown-linux-musl", - "i386-apple-ios", - "i586-pc-windows-msvc", - "i586-unknown-linux-gnu", - "i586-unknown-linux-musl", - "i686-apple-darwin", - "i686-linux-android", - "i686-pc-windows-gnu", - "i686-pc-windows-msvc", - "i686-unknown-freebsd", - "i686-unknown-haiku", - "i686-unknown-linux-gnu", - "i686-unknown-linux-musl", - "i686-unknown-netbsd", - "i686-unknown-openbsd", - "i686-unknown-uefi", - "i686-uwp-windows-gnu", - "i686-uwp-windows-msvc", - "i686-wrs-vxworks", - "m68k-unknown-linux-gnu", - "mips-unknown-linux-gnu", - "mips-unknown-linux-musl", - "mips-unknown-linux-uclibc", - "mips64-unknown-linux-gnuabi64", - "mips64-unknown-linux-muslabi64", - "mips64el-unknown-linux-gnuabi64", - "mips64el-unknown-linux-muslabi64", - "mipsel-sony-psp", - "mipsel-unknown-linux-gnu", - "mipsel-unknown-linux-musl", - "mipsel-unknown-linux-uclibc", - "mipsel-unknown-none", - "mipsisa32r6-unknown-linux-gnu", - "mipsisa32r6el-unknown-linux-gnu", - "mipsisa64r6-unknown-linux-gnuabi64", - "mipsisa64r6el-unknown-linux-gnuabi64", - "msp430-none-elf", - "nvptx64-nvidia-cuda", - "powerpc-unknown-freebsd", - "powerpc-unknown-linux-gnu", - "powerpc-unknown-linux-gnuspe", - "powerpc-unknown-linux-musl", - "powerpc-unknown-netbsd", - "powerpc-unknown-openbsd", - "powerpc-wrs-vxworks", - "powerpc-wrs-vxworks-spe", - "powerpc64-unknown-freebsd", - "powerpc64-unknown-linux-gnu", - "powerpc64-unknown-linux-musl", - "powerpc64-wrs-vxworks", - "powerpc64le-unknown-freebsd", - "powerpc64le-unknown-linux-gnu", - "powerpc64le-unknown-linux-musl", - "riscv32gc-unknown-linux-gnu", - "riscv32gc-unknown-linux-musl", - "riscv32i-unknown-none-elf", - "riscv32imac-unknown-none-elf", - "riscv32imc-esp-espidf", - "riscv32imc-unknown-none-elf", - "riscv64gc-unknown-freebsd", - "riscv64gc-unknown-linux-gnu", - "riscv64gc-unknown-linux-musl", - "riscv64gc-unknown-none-elf", - "riscv64imac-unknown-none-elf", - "s390x-unknown-linux-gnu", - "s390x-unknown-linux-musl", - "sparc-unknown-linux-gnu", - "sparc64-unknown-linux-gnu", - "sparc64-unknown-netbsd", - "sparc64-unknown-openbsd", - "sparcv9-sun-solaris", - "thumbv4t-none-eabi", - "thumbv6m-none-eabi", - "thumbv7a-pc-windows-msvc", - "thumbv7a-uwp-windows-msvc", - "thumbv7em-none-eabi", - "thumbv7em-none-eabihf", - "thumbv7m-none-eabi", - "thumbv7neon-linux-androideabi", - "thumbv7neon-unknown-linux-gnueabihf", - "thumbv7neon-unknown-linux-musleabihf", - "thumbv8m.base-none-eabi", - "thumbv8m.main-none-eabi", - "thumbv8m.main-none-eabihf", - "wasm32-unknown-emscripten", - "wasm32-unknown-unknown", - "wasm32-wasi", - "wasm64-unknown-unknown", - "x86_64-apple-darwin", - "x86_64-apple-ios", - "x86_64-apple-ios-macabi", - "x86_64-apple-tvos", - "x86_64-fortanix-unknown-sgx", - "x86_64-fuchsia", - "x86_64-linux-android", - "x86_64-pc-solaris", - "x86_64-pc-windows-gnu", - "x86_64-pc-windows-msvc", - "x86_64-sun-solaris", - "x86_64-unknown-dragonfly", - "x86_64-unknown-freebsd", - "x86_64-unknown-haiku", - "x86_64-unknown-hermit", - "x86_64-unknown-illumos", - "x86_64-unknown-l4re-uclibc", - "x86_64-unknown-linux-gnu", - "x86_64-unknown-linux-gnux32", - "x86_64-unknown-linux-musl", - "x86_64-unknown-netbsd", - "x86_64-unknown-none", - "x86_64-unknown-none-hermitkernel", - "x86_64-unknown-none-linuxkernel", - "x86_64-unknown-openbsd", - "x86_64-unknown-redox", - "x86_64-unknown-uefi", - "x86_64-uwp-windows-gnu", - "x86_64-uwp-windows-msvc", - "x86_64-wrs-vxworks" - ] - } - ] + "required": ["channel"] + } + }, + "channel": { + "not": { + "properties": { + "path": { + "type": "string" + } + }, + "required": ["path"] + } + }, + "profile": { + "anyOf": [ + { + "properties": { + "channel": { + "type": "string" + } }, - "x-taplo": { - "links": { - "key": "https://rust-lang.github.io/rustup/cross-compilation.html" + "required": ["channel"] + }, + { + "properties": { + "components": { + "type": "array" } - } + }, + "required": ["components"] }, - "profile": { - "description": "In order to make it easier to work with components, a\n\"profile\" defines a grouping of components.", - "type": "string", - "default": "default", - "enum": [ - "minimal", - "default", - "complete" - ], - "x-taplo": { - "links": { - "key": "https://rust-lang.github.io/rustup/concepts/profiles.html" - }, - "docs": { - "enumValues": [ - "This profile includes as few components as possible to get a\nworking compiler (`rustc`, `rust-std`, and `cargo`). It's recommended to use\nthis component on Windows systems if you don't use local documentation (the\nlarge number of files can cause issues with some Antivirus systems), and in\nCI.", - "This profile includes all of components in the **minimal**\nprofile, and adds `rust-docs`, `rustfmt`, and `clippy`. This profile will be\nused by `rustup` by default, and it's the one recommended for general use.", - "This profile includes all the components available through\n`rustup`. This should never be used, as it includes *every* component ever\nincluded in the metadata and thus will almost always fail. If you are\nlooking for a way to install devtools such as `miri` or IDE integration\ntools (`rls`), you should use the `default` profile and\ninstall the needed additional components manually, either by using `rustup\ncomponent add` or by using `-c` when installing the toolchain." - ] + { + "properties": { + "targets": { + "type": "array" } - } - } - }, - "required": [ - "channel" - ] - }, - { - "properties": { - "path": { - "type": "string", - "description": "Path to a custom local toolchain. Since a `path` directive directly names a local toolchain, other options\nlike `components`, `targets`, and `profile` have no effect. `channel`\nand `path` are mutually exclusive, since a `path` already points to a\nspecific toolchain. A relative `path` is resolved relative to the\nlocation of the `rust-toolchain.toml` file." + }, + "required": ["targets"] } - }, - "required": [ - "path" ] } - ], + }, "x-taplo": { "links": { "key": "https://rust-lang.github.io/rustup/concepts/toolchains.html" }, - "initKeys": [ - "channel" - ] + "initKeys": ["channel"] } } }, - "required": [ - "toolchain" - ] + "required": ["toolchain"], + "title": "Schema for rust-toolchain.toml", + "type": "object", + "x-taplo-info": { + "authors": ["ian-h-chamberlain (https://github.com/ian-h-chamberlain)"], + "patterns": ["^(.*(/|\\\\)rust-toolchain([.]toml)?)$"] + } } diff --git a/site/site/public/schemas/rustfmt.toml.json b/site/site/public/schemas/rustfmt.toml.json index 901f19922..87f900b1c 100644 --- a/site/site/public/schemas/rustfmt.toml.json +++ b/site/site/public/schemas/rustfmt.toml.json @@ -1,12 +1,7 @@ { "$schema": "http://json-schema.org/draft-07/schema#", - "title": "rustfmt schema", - "type": "object", + "$id": "https://json.schemastore.org/rustfmt.json", "description": "https://rust-lang.github.io/rustfmt", - "x-taplo-info": { - "authors": ["Aloso (https://github.com/Aloso)"], - "patterns": ["^(.*(/|\\\\)\\.?rustfmt\\.toml|rustfmt\\.toml)$"] - }, "properties": { "array_width": { "type": "integer", @@ -312,7 +307,7 @@ }, "print_misformatted_file_names": { "type": "boolean", - "description": "Prints the names of mismatched files that were formatted. Prints the names of files that would be formated when used with `--check` mode.\n\n[Documentation](https://rust-lang.github.io/rustfmt/#print_misformatted_file_names)", + "description": "Prints the names of mismatched files that were formatted. Prints the names of files that would be formatted when used with `--check` mode.\n\n[Documentation](https://rust-lang.github.io/rustfmt/#print_misformatted_file_names)", "default": false, "enum": [true, false] }, @@ -472,5 +467,11 @@ "default": false, "enum": [true, false] } + }, + "title": "rustfmt schema", + "type": "object", + "x-taplo-info": { + "authors": ["Aloso (https://github.com/Aloso)"], + "patterns": ["^(.*(/|\\\\)\\.?rustfmt\\.toml|rustfmt\\.toml)$"] } }