diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 3d622ec..49ba69d 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -5,7 +5,7 @@ on: branches: [main] pull_request: workflow_dispatch: -# allow manual runs on branches without a PR + # allow manual runs on branches without a PR env: FORCE_COLOR: "1" @@ -22,12 +22,12 @@ jobs: uses: actions/checkout@v6 - name: Install uv - uses: astral-sh/setup-uv@v8.1.0 + uses: astral-sh/setup-uv@v8.2.0 with: enable-cache: true - name: "Set up Python" - uses: actions/setup-python@v6 + uses: actions/setup-python@v6.2.0 with: python-version-file: ".python-version" @@ -42,15 +42,15 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@v6 + uses: actions/checkout@v7 - name: Install uv - uses: astral-sh/setup-uv@v8.1.0 + uses: astral-sh/setup-uv@v8.2.0 with: enable-cache: true - name: "Set up Python" - uses: actions/setup-python@v6 + uses: actions/setup-python@v6.2.0 with: python-version-file: ".python-version" @@ -65,7 +65,7 @@ jobs: needs: [lint, tests] runs-on: ubuntu-latest steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v7 - name: Build snap uses: snapcore/action-build@v1 diff --git a/.github/workflows/publish-tagged.yml b/.github/workflows/publish-tagged.yml index 2a4aa35..11c3cb9 100644 --- a/.github/workflows/publish-tagged.yml +++ b/.github/workflows/publish-tagged.yml @@ -20,7 +20,7 @@ jobs: contents: read id-token: write steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v7 with: ref: "${{ (inputs.tag != null) && format('refs/tags/{0}', inputs.tag) || '' }}" - uses: "DeterminateSystems/nix-installer-action@main" @@ -39,7 +39,7 @@ jobs: - ubuntu-24.04-arm runs-on: ${{ matrix.system }} steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v7 - uses: snapcore/action-build@v1 id: build - uses: snapcore/action-publish@v1 diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index d9d06a6..e7e9302 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -14,17 +14,17 @@ jobs: VERSION: ${{ steps.build.outputs.VERSION }} steps: - name: Checkout - uses: actions/checkout@v6 + uses: actions/checkout@v7 with: fetch-depth: 0 - name: Install uv - uses: astral-sh/setup-uv@v8.1.0 + uses: astral-sh/setup-uv@v8.2.0 with: enable-cache: true - name: "Set up Python" - uses: actions/setup-python@v6 + uses: actions/setup-python@v6.2.0 with: python-version-file: ".python-version" @@ -56,7 +56,7 @@ jobs: steps: - name: Checkout - uses: actions/checkout@v6 + uses: actions/checkout@v7 with: fetch-depth: 0 @@ -67,7 +67,7 @@ jobs: path: dist/ - name: Sign the dists with Sigstore - uses: sigstore/gh-action-sigstore-python@v3.3.0 + uses: sigstore/gh-action-sigstore-python@v3.4.0 with: inputs: >- ./dist/*.tar.gz diff --git a/dev/snap_01_add_ids.patch b/dev/snap_01_add_ids.patch index a12db54..377f9bb 100644 --- a/dev/snap_01_add_ids.patch +++ b/dev/snap_01_add_ids.patch @@ -1,64 +1,72 @@ ---- .build/snapcraft_upstream.json.orig 2025-10-31 14:39:20.642999620 +0100 -+++ src/craft_ls/schemas/snapcraft.json 2025-10-31 15:10:13.397566863 +0100 +--- snapcraft.json 2026-06-19 13:57:41.806308756 +0200 ++++ .build/snapcraft_upstream.json 2026-06-19 14:07:56.295766948 +0200 @@ -1,4 +1,5 @@ { + "$id": "#snapcraft", "$defs": { "App": { "additionalProperties": false, -@@ -503,6 +504,7 @@ +@@ -522,6 +523,7 @@ "type": "object" }, "BareCore22Project": { -+ "$id": "urn:snapcraft:bare22", ++ "$id": "urn:snapcraft:bare22", "additionalProperties": false, "properties": { "name": { -@@ -1090,6 +1092,7 @@ +@@ -1108,6 +1110,7 @@ "type": "object" }, "BareCore24Project": { -+ "$id": "urn:snapcraft:bare24", ++ "$id": "urn:snapcraft:bare24", "additionalProperties": false, "properties": { "name": { -@@ -1678,6 +1681,7 @@ +@@ -1694,6 +1697,7 @@ "type": "object" }, - "BaseCore22Project": { -+ "$id": "urn:snapcraft:base22", + "BareCore26Project": { ++ "$id": "urn:snapcraft:bare26", "additionalProperties": false, "properties": { "name": { -@@ -2259,6 +2263,7 @@ +@@ -2280,6 +2284,7 @@ "type": "object" }, - "BaseCore24Project": { -+ "$id": "urn:snapcraft:base24", + "BareDevelProject": { ++ "$id": "urn:snapcraft:baredevel", "additionalProperties": false, "properties": { "name": { -@@ -2840,6 +2845,7 @@ +@@ -2983,6 +2988,7 @@ "type": "object" }, - "BaseDevelProject": { -+ "$id": "urn:snapcraft:devel", + "Core22Project": { ++ "$id": "urn:snapcraft:core22", "additionalProperties": false, "properties": { "name": { -@@ -3555,6 +3561,7 @@ +@@ -3578,6 +3584,7 @@ "type": "object" }, - "Core22Project": { -+ "$id": "urn:snapcraft:core22", + "Core24Project": { ++ "$id": "urn:snapcraft:core24", "additionalProperties": false, "properties": { "name": { -@@ -4151,6 +4158,7 @@ +@@ -4173,6 +4180,7 @@ "type": "object" }, - "Core24Project": { -+ "$id": "urn:snapcraft:core24", + "Core26Project": { ++ "$id": "urn:snapcraft:core26", + "additionalProperties": false, + "properties": { + "name": { +@@ -4768,6 +4776,7 @@ + "type": "object" + }, + "DevelBaseProject": { ++ "$id": "urn:snapcraft:basedevel", "additionalProperties": false, "properties": { "name": { diff --git a/noxfile.py b/noxfile.py index 84f80ca..594dc53 100644 --- a/noxfile.py +++ b/noxfile.py @@ -9,12 +9,11 @@ nox.options.reuse_venv = "yes" nox.options.sessions = ["fmt", "lint"] -# TODO: Pin versions to tagged release for all tools -CHARM_VERSION = "4.0.1" -SNAP_VERSION = "551a793ae20241db56b7edf9049070a72f5f593b" -ROCK_VERSION = "6553ac9de239be758f5cf648eb65c580709c4fc5" -SNAPCRAFT_URL = f"https://raw.githubusercontent.com/canonical/snapcraft/{SNAP_VERSION}/schema/snapcraft.json" -ROCKCRAFT_URL = f"https://raw.githubusercontent.com/canonical/rockcraft/{ROCK_VERSION}/schema/rockcraft.json" +CHARM_VERSION = "4.2.1" +SNAP_VERSION = "9.0.0" +ROCK_VERSION = "1.19.0" +SNAPCRAFT_URL = f"https://raw.githubusercontent.com/canonical/snapcraft/refs/tags/{SNAP_VERSION}/schema/snapcraft.json" +ROCKCRAFT_URL = f"https://raw.githubusercontent.com/canonical/rockcraft/refs/tags/{ROCK_VERSION}/schema/rockcraft.json" CHARMCRAFT_URL = f"https://raw.githubusercontent.com/canonical/charmcraft/refs/tags/{CHARM_VERSION}/schema/charmcraft.json" diff --git a/src/craft_ls/core.py b/src/craft_ls/core.py index f1ccb90..5879229 100644 --- a/src/craft_ls/core.py +++ b/src/craft_ls/core.py @@ -113,6 +113,12 @@ def get_validator_and_parse( # noqa: C901 .lookup("urn:snapcraft:core24") .contents ) + case "core26", _: + validator = Draft202012Validator( + schema=snapcraft_registry.resolver() + .lookup("urn:snapcraft:core26") + .contents + ) case "bare", "core22": validator = Draft202012Validator( schema=snapcraft_registry.resolver() @@ -125,6 +131,12 @@ def get_validator_and_parse( # noqa: C901 .lookup("urn:snapcraft:bare24") .contents ) + case "bare", "core26": + validator = Draft202012Validator( + schema=snapcraft_registry.resolver() + .lookup("urn:snapcraft:bare26") + .contents + ) case _, "core22": validator = Draft202012Validator( schema=snapcraft_registry.resolver() @@ -140,7 +152,7 @@ def get_validator_and_parse( # noqa: C901 case _, "devel": validator = Draft202012Validator( schema=snapcraft_registry.resolver() - .lookup("urn:snapcraft:devel") + .lookup("urn:snapcraft:basedevel") .contents ) diff --git a/src/craft_ls/schemas/charmcraft.json b/src/craft_ls/schemas/charmcraft.json index 8ea0787..5abaa4f 100644 --- a/src/craft_ls/schemas/charmcraft.json +++ b/src/craft_ls/schemas/charmcraft.json @@ -58,7 +58,6 @@ ], "maxLength": 40, "minLength": 1, - "pattern": "^([a-z0-9][a-z0-9-]?)*[a-z]+([a-z0-9-]?[a-z0-9])*$", "title": "Project Name", "type": "string" }, @@ -855,7 +854,6 @@ ], "maxLength": 40, "minLength": 1, - "pattern": "^([a-z0-9][a-z0-9-]?)*[a-z]+([a-z0-9-]?[a-z0-9])*$", "title": "Project Name", "type": "string" }, @@ -902,13 +900,16 @@ "ubuntu@20.04", "ubuntu@22.04", "ubuntu@24.04", - "ubuntu@24.10", "ubuntu@25.04", "ubuntu@25.10", "almalinux@9" ], "type": "string" }, + { + "const": "ubuntu@26.04", + "type": "string" + }, { "type": "null" } @@ -924,7 +925,6 @@ "ubuntu@20.04", "ubuntu@22.04", "ubuntu@24.04", - "ubuntu@24.10", "ubuntu@25.04", "ubuntu@25.10", "almalinux@9" @@ -991,6 +991,19 @@ ] } }, + "propertyNames": { + "description": "The name of this platform. May not contain '/'", + "examples": [ + "riscv64", + "my-special-platform" + ], + "not": { + "enum": [ + "*", + "any" + ] + } + }, "title": "Platforms", "type": "object" }, diff --git a/src/craft_ls/schemas/rockcraft.json b/src/craft_ls/schemas/rockcraft.json index b2a2caa..c94dd3d 100644 --- a/src/craft_ls/schemas/rockcraft.json +++ b/src/craft_ls/schemas/rockcraft.json @@ -868,12 +868,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -882,11 +884,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -1030,7 +1033,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -1128,7 +1131,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -1198,6 +1201,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -1266,7 +1285,7 @@ "if": { "properties": { "plugin": { - "const": "ant" + "const": "dump" } } }, @@ -1290,12 +1309,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -1304,11 +1325,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -1331,15 +1353,16 @@ ], "title": "Source" }, - "ant-build-targets": { - "default": [], - "items": { - "type": "string" - }, - "title": "Ant-Build-Targets", - "type": "array" + "source-checksum": { + "default": "", + "description": "The checksum of the downloaded source, to ensure integrity.", + "examples": [ + "sha256/1451d01ee3a21100340aed867d0b799f46f0b1749680028d38c3f5d0128fb8a7" + ], + "title": "Source-Checksum", + "type": "string" }, - "ant-build-file": { + "source-channel": { "anyOf": [ { "type": "string" @@ -1349,16 +1372,1363 @@ } ], "default": null, - "title": "Ant-Build-File" + "title": "Source-Channel" }, - "ant-properties": { + "source-branch": { + "default": "", + "description": "The target branch for Git sources.", + "examples": [ + "main", + "hotfix/2.10" + ], + "title": "Source-Branch", + "type": "string" + }, + "source-commit": { + "default": "", + "description": "The target commit for Git sources.", + "examples": [ + "36086af03fc4941a8ac219648ce77401743f3ae0" + ], + "title": "Source-Commit", + "type": "string" + }, + "source-depth": { + "default": 0, + "description": "The commit depth to fetch for Git sources.", + "examples": [ + "1" + ], + "title": "Source-Depth", + "type": "integer" + }, + "source-subdir": { + "default": "", + "description": "The subdirectory of the unpacked source where the build will occur.", + "examples": [ + "src", + "demo_nodes_cpp" + ], + "title": "Source-Subdir", + "type": "string" + }, + "source-submodules": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The registered submodules to fetch from Git sources.", + "examples": [ + "[third_party/googletest, third_party/jsoncpp]", + "[libbpf]" + ], + "title": "Source-Submodules" + }, + "source-tag": { + "default": "", + "description": "The target tag for Git sources.", + "examples": [ + "1.0.1" + ], + "title": "Source-Tag", + "type": "string" + }, + "source-type": { + "default": "", + "description": "The format of the part's source.", + "examples": [ + "git", + "local" + ], + "title": "Source-Type", + "type": "string" + }, + "disable-parallel": { + "default": false, + "description": "Whether to disable CPU multithreading during the build step.", + "examples": [ + "true" + ], + "title": "Disable-Parallel", + "type": "boolean" + }, + "after": { + "default": [], + "description": "The parts to process before starting this part's build.", + "examples": [ + "[build-deps, daemon]" + ], + "items": { + "type": "string" + }, + "title": "After", + "type": "array" + }, + "overlay-packages": { + "default": [], + "description": "The packages to install in the part's layer.", + "examples": [ + "[ed]" + ], + "items": { + "type": "string" + }, + "title": "Overlay-Packages", + "type": "array" + }, + "stage-snaps": { + "default": [], + "description": "The snaps to include in the stage environment.", + "examples": [ + "[go/1.17, chisel/latest/candidate, mir-kiosk-x11]" + ], + "items": { + "type": "string" + }, + "title": "Stage-Snaps", + "type": "array" + }, + "stage-packages": { + "default": [], + "description": "The packages or Chisel slices to include in the stage environment.", + "examples": [ + "[curl, libxml2]" + ], + "items": { + "type": "string" + }, + "title": "Stage-Packages", + "type": "array" + }, + "build-snaps": { + "default": [], + "description": "The snaps to install in the build environment.", + "examples": [ + "[go/latest/stable, node/stable]" + ], + "items": { + "type": "string" + }, + "title": "Build-Snaps", + "type": "array" + }, + "build-packages": { + "default": [], + "description": "The packages to install in the build environment.", + "examples": [ + "[git, libffi-dev, libssl-dev]" + ], + "items": { + "type": "string" + }, + "title": "Build-Packages", + "type": "array" + }, + "build-environment": { + "default": [], + "description": "The environment variables to define for the build step, as key-value pairs.", + "examples": [ + "[{MESSAGE: \"Hello world!\"}, {NAME: \"Craft Parts\"}]" + ], + "items": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "title": "Build-Environment", + "type": "array" + }, + "build-attributes": { + "default": [], + "description": "Identifiers that control specific behaviors during the build.", + "examples": [ + "[enable-usrmerge]", + "[disable-usrmerge]" + ], + "items": { + "type": "string" + }, + "title": "Build-Attributes", + "type": "array" + }, + "organize": { "additionalProperties": { "type": "string" }, - "default": {}, - "title": "Ant-Properties", + "description": "A map of files from the build directory to their destinations in the stage directory.", + "examples": [ + "{hello.py: bin/hello}" + ], + "title": "Organize", "type": "object" }, + "overlay": { + "description": "The files to copy from the part's layer to the stage directory.", + "examples": [ + "[bin, usr/bin]", + "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" + ], + "items": { + "type": "string" + }, + "title": "Overlay", + "type": "array" + }, + "stage": { + "description": "The files to copy from the build directory to the stage directory.", + "examples": [ + "[usr/bin/*, usr/share]", + "[-usr, zfsutils-linux]" + ], + "items": { + "description": "relative path", + "minLength": 1, + "type": "string" + }, + "title": "Stage", + "type": "array" + }, + "prime": { + "description": "", + "examples": [ + "[usr/lib/*/qt6/plugins/tls/*, -usr/share/thumbnailers]" + ], + "items": { + "description": "relative path", + "minLength": 1, + "type": "string" + }, + "title": "Prime", + "type": "array" + }, + "override-pull": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The commands to run instead of the default behavior of the pull step.", + "examples": [ + "|\n craftctl default\n rm $CRAFT_PART_SRC/pyproject.toml" + ], + "title": "Override-Pull" + }, + "overlay-script": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The commands to run after the part's overlay packages are installed.", + "examples": [ + "|\n rm -f ${CRAFT_OVERLAY}/usr/bin/vi ${CRAFT_OVERLAY}/usr/bin/vim*\n rm -f ${CRAFT_OVERLAY}/usr/bin/emacs*\n rm -f ${CRAFT_OVERLAY}/bin/nano" + ], + "title": "Overlay-Script" + }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, + "override-build": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The commands to run instead of the default behavior of the build step.", + "examples": [ + "|\n cd cmd/webhook\n mkdir $CRAFT_PART_INSTALL/ko-app\n go build -o $CRAFT_PART_INSTALL/ko-app/webhook -a ." + ], + "title": "Override-Build" + }, + "override-stage": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The commands to run instead of the default behavior of the stage step.", + "examples": [ + "|\n craftctl default\n chown -R 499 \"${CRAFT_PART_INSTALL}/entrypoint.sh\"" + ], + "title": "Override-Stage" + }, + "override-prime": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The commands to run instead of the default behavior of the prime step.", + "examples": [ + "|\n craftctl default\n mkdir -p $CRAFT_PRIME/var/lib/mysql\n mkdir -p $CRAFT_PRIME/var/lib/mysqld" + ], + "title": "Override-Prime" + }, + "permissions": { + "default": [], + "description": "The ownership and permission settings for a set of files in the part's prime directory.", + "examples": [ + "[{owner: 2000, group: 2000}, {path: srv/indico/start-indico.sh, mode: \"544\"}, {path: etc/, mode: \"755\"}]" + ], + "items": { + "$ref": "#/$defs/Permissions" + }, + "title": "Permissions", + "type": "array" + } + }, + "additionalProperties": false + } + }, + { + "if": { + "properties": { + "plugin": { + "const": "nil" + } + } + }, + "then": { + "$comment": "common properties had to be repeated here or they would be considered invalid by the schema validator otherwise", + "properties": { + "plugin": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The plugin to build the part with.", + "examples": [ + "python", + "dump" + ], + "title": "Plugin", + "enum": [ + "dump", + "nil", + "ant", + "autotools", + "bazel", + "cargo-use", + "cmake", + "dotnet", + "go", + "go-use", + "gradle", + "jlink", + "make", + "maven", + "maven-use", + "meson", + "npm", + "npm-use", + "poetry", + "python", + "qmake", + "ruby", + "rust", + "scons", + "uv" + ] + }, + "source": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The location of the source files for the part.", + "examples": [ + ".", + "https://github.com/canonical/dqlite" + ], + "title": "Source" + }, + "source-checksum": { + "default": "", + "description": "The checksum of the downloaded source, to ensure integrity.", + "examples": [ + "sha256/1451d01ee3a21100340aed867d0b799f46f0b1749680028d38c3f5d0128fb8a7" + ], + "title": "Source-Checksum", + "type": "string" + }, + "source-channel": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "title": "Source-Channel" + }, + "source-branch": { + "default": "", + "description": "The target branch for Git sources.", + "examples": [ + "main", + "hotfix/2.10" + ], + "title": "Source-Branch", + "type": "string" + }, + "source-commit": { + "default": "", + "description": "The target commit for Git sources.", + "examples": [ + "36086af03fc4941a8ac219648ce77401743f3ae0" + ], + "title": "Source-Commit", + "type": "string" + }, + "source-depth": { + "default": 0, + "description": "The commit depth to fetch for Git sources.", + "examples": [ + "1" + ], + "title": "Source-Depth", + "type": "integer" + }, + "source-subdir": { + "default": "", + "description": "The subdirectory of the unpacked source where the build will occur.", + "examples": [ + "src", + "demo_nodes_cpp" + ], + "title": "Source-Subdir", + "type": "string" + }, + "source-submodules": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The registered submodules to fetch from Git sources.", + "examples": [ + "[third_party/googletest, third_party/jsoncpp]", + "[libbpf]" + ], + "title": "Source-Submodules" + }, + "source-tag": { + "default": "", + "description": "The target tag for Git sources.", + "examples": [ + "1.0.1" + ], + "title": "Source-Tag", + "type": "string" + }, + "source-type": { + "default": "", + "description": "The format of the part's source.", + "examples": [ + "git", + "local" + ], + "title": "Source-Type", + "type": "string" + }, + "disable-parallel": { + "default": false, + "description": "Whether to disable CPU multithreading during the build step.", + "examples": [ + "true" + ], + "title": "Disable-Parallel", + "type": "boolean" + }, + "after": { + "default": [], + "description": "The parts to process before starting this part's build.", + "examples": [ + "[build-deps, daemon]" + ], + "items": { + "type": "string" + }, + "title": "After", + "type": "array" + }, + "overlay-packages": { + "default": [], + "description": "The packages to install in the part's layer.", + "examples": [ + "[ed]" + ], + "items": { + "type": "string" + }, + "title": "Overlay-Packages", + "type": "array" + }, + "stage-snaps": { + "default": [], + "description": "The snaps to include in the stage environment.", + "examples": [ + "[go/1.17, chisel/latest/candidate, mir-kiosk-x11]" + ], + "items": { + "type": "string" + }, + "title": "Stage-Snaps", + "type": "array" + }, + "stage-packages": { + "default": [], + "description": "The packages or Chisel slices to include in the stage environment.", + "examples": [ + "[curl, libxml2]" + ], + "items": { + "type": "string" + }, + "title": "Stage-Packages", + "type": "array" + }, + "build-snaps": { + "default": [], + "description": "The snaps to install in the build environment.", + "examples": [ + "[go/latest/stable, node/stable]" + ], + "items": { + "type": "string" + }, + "title": "Build-Snaps", + "type": "array" + }, + "build-packages": { + "default": [], + "description": "The packages to install in the build environment.", + "examples": [ + "[git, libffi-dev, libssl-dev]" + ], + "items": { + "type": "string" + }, + "title": "Build-Packages", + "type": "array" + }, + "build-environment": { + "default": [], + "description": "The environment variables to define for the build step, as key-value pairs.", + "examples": [ + "[{MESSAGE: \"Hello world!\"}, {NAME: \"Craft Parts\"}]" + ], + "items": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "title": "Build-Environment", + "type": "array" + }, + "build-attributes": { + "default": [], + "description": "Identifiers that control specific behaviors during the build.", + "examples": [ + "[enable-usrmerge]", + "[disable-usrmerge]" + ], + "items": { + "type": "string" + }, + "title": "Build-Attributes", + "type": "array" + }, + "organize": { + "additionalProperties": { + "type": "string" + }, + "description": "A map of files from the build directory to their destinations in the stage directory.", + "examples": [ + "{hello.py: bin/hello}" + ], + "title": "Organize", + "type": "object" + }, + "overlay": { + "description": "The files to copy from the part's layer to the stage directory.", + "examples": [ + "[bin, usr/bin]", + "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" + ], + "items": { + "type": "string" + }, + "title": "Overlay", + "type": "array" + }, + "stage": { + "description": "The files to copy from the build directory to the stage directory.", + "examples": [ + "[usr/bin/*, usr/share]", + "[-usr, zfsutils-linux]" + ], + "items": { + "description": "relative path", + "minLength": 1, + "type": "string" + }, + "title": "Stage", + "type": "array" + }, + "prime": { + "description": "", + "examples": [ + "[usr/lib/*/qt6/plugins/tls/*, -usr/share/thumbnailers]" + ], + "items": { + "description": "relative path", + "minLength": 1, + "type": "string" + }, + "title": "Prime", + "type": "array" + }, + "override-pull": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The commands to run instead of the default behavior of the pull step.", + "examples": [ + "|\n craftctl default\n rm $CRAFT_PART_SRC/pyproject.toml" + ], + "title": "Override-Pull" + }, + "overlay-script": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The commands to run after the part's overlay packages are installed.", + "examples": [ + "|\n rm -f ${CRAFT_OVERLAY}/usr/bin/vi ${CRAFT_OVERLAY}/usr/bin/vim*\n rm -f ${CRAFT_OVERLAY}/usr/bin/emacs*\n rm -f ${CRAFT_OVERLAY}/bin/nano" + ], + "title": "Overlay-Script" + }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, + "override-build": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The commands to run instead of the default behavior of the build step.", + "examples": [ + "|\n cd cmd/webhook\n mkdir $CRAFT_PART_INSTALL/ko-app\n go build -o $CRAFT_PART_INSTALL/ko-app/webhook -a ." + ], + "title": "Override-Build" + }, + "override-stage": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The commands to run instead of the default behavior of the stage step.", + "examples": [ + "|\n craftctl default\n chown -R 499 \"${CRAFT_PART_INSTALL}/entrypoint.sh\"" + ], + "title": "Override-Stage" + }, + "override-prime": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The commands to run instead of the default behavior of the prime step.", + "examples": [ + "|\n craftctl default\n mkdir -p $CRAFT_PRIME/var/lib/mysql\n mkdir -p $CRAFT_PRIME/var/lib/mysqld" + ], + "title": "Override-Prime" + }, + "permissions": { + "default": [], + "description": "The ownership and permission settings for a set of files in the part's prime directory.", + "examples": [ + "[{owner: 2000, group: 2000}, {path: srv/indico/start-indico.sh, mode: \"544\"}, {path: etc/, mode: \"755\"}]" + ], + "items": { + "$ref": "#/$defs/Permissions" + }, + "title": "Permissions", + "type": "array" + } + }, + "additionalProperties": false + } + }, + { + "if": { + "properties": { + "plugin": { + "const": "ant" + } + } + }, + "then": { + "$comment": "common properties had to be repeated here or they would be considered invalid by the schema validator otherwise", + "properties": { + "plugin": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The plugin to build the part with.", + "examples": [ + "python", + "dump" + ], + "title": "Plugin", + "enum": [ + "dump", + "nil", + "ant", + "autotools", + "bazel", + "cargo-use", + "cmake", + "dotnet", + "go", + "go-use", + "gradle", + "jlink", + "make", + "maven", + "maven-use", + "meson", + "npm", + "npm-use", + "poetry", + "python", + "qmake", + "ruby", + "rust", + "scons", + "uv" + ] + }, + "source": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The location of the source files for the part.", + "examples": [ + ".", + "https://github.com/canonical/dqlite" + ], + "title": "Source" + }, + "ant-build-targets": { + "default": [], + "items": { + "type": "string" + }, + "title": "Ant-Build-Targets", + "type": "array" + }, + "ant-build-file": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "title": "Ant-Build-File" + }, + "ant-properties": { + "additionalProperties": { + "type": "string" + }, + "default": {}, + "title": "Ant-Properties", + "type": "object" + }, + "source-checksum": { + "default": "", + "description": "The checksum of the downloaded source, to ensure integrity.", + "examples": [ + "sha256/1451d01ee3a21100340aed867d0b799f46f0b1749680028d38c3f5d0128fb8a7" + ], + "title": "Source-Checksum", + "type": "string" + }, + "source-channel": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "title": "Source-Channel" + }, + "source-branch": { + "default": "", + "description": "The target branch for Git sources.", + "examples": [ + "main", + "hotfix/2.10" + ], + "title": "Source-Branch", + "type": "string" + }, + "source-commit": { + "default": "", + "description": "The target commit for Git sources.", + "examples": [ + "36086af03fc4941a8ac219648ce77401743f3ae0" + ], + "title": "Source-Commit", + "type": "string" + }, + "source-depth": { + "default": 0, + "description": "The commit depth to fetch for Git sources.", + "examples": [ + "1" + ], + "title": "Source-Depth", + "type": "integer" + }, + "source-subdir": { + "default": "", + "description": "The subdirectory of the unpacked source where the build will occur.", + "examples": [ + "src", + "demo_nodes_cpp" + ], + "title": "Source-Subdir", + "type": "string" + }, + "source-submodules": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The registered submodules to fetch from Git sources.", + "examples": [ + "[third_party/googletest, third_party/jsoncpp]", + "[libbpf]" + ], + "title": "Source-Submodules" + }, + "source-tag": { + "default": "", + "description": "The target tag for Git sources.", + "examples": [ + "1.0.1" + ], + "title": "Source-Tag", + "type": "string" + }, + "source-type": { + "default": "", + "description": "The format of the part's source.", + "examples": [ + "git", + "local" + ], + "title": "Source-Type", + "type": "string" + }, + "disable-parallel": { + "default": false, + "description": "Whether to disable CPU multithreading during the build step.", + "examples": [ + "true" + ], + "title": "Disable-Parallel", + "type": "boolean" + }, + "after": { + "default": [], + "description": "The parts to process before starting this part's build.", + "examples": [ + "[build-deps, daemon]" + ], + "items": { + "type": "string" + }, + "title": "After", + "type": "array" + }, + "overlay-packages": { + "default": [], + "description": "The packages to install in the part's layer.", + "examples": [ + "[ed]" + ], + "items": { + "type": "string" + }, + "title": "Overlay-Packages", + "type": "array" + }, + "stage-snaps": { + "default": [], + "description": "The snaps to include in the stage environment.", + "examples": [ + "[go/1.17, chisel/latest/candidate, mir-kiosk-x11]" + ], + "items": { + "type": "string" + }, + "title": "Stage-Snaps", + "type": "array" + }, + "stage-packages": { + "default": [], + "description": "The packages or Chisel slices to include in the stage environment.", + "examples": [ + "[curl, libxml2]" + ], + "items": { + "type": "string" + }, + "title": "Stage-Packages", + "type": "array" + }, + "build-snaps": { + "default": [], + "description": "The snaps to install in the build environment.", + "examples": [ + "[go/latest/stable, node/stable]" + ], + "items": { + "type": "string" + }, + "title": "Build-Snaps", + "type": "array" + }, + "build-packages": { + "default": [], + "description": "The packages to install in the build environment.", + "examples": [ + "[git, libffi-dev, libssl-dev]" + ], + "items": { + "type": "string" + }, + "title": "Build-Packages", + "type": "array" + }, + "build-environment": { + "default": [], + "description": "The environment variables to define for the build step, as key-value pairs.", + "examples": [ + "[{MESSAGE: \"Hello world!\"}, {NAME: \"Craft Parts\"}]" + ], + "items": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + "title": "Build-Environment", + "type": "array" + }, + "build-attributes": { + "default": [], + "description": "Identifiers that control specific behaviors during the build.", + "examples": [ + "[enable-usrmerge]", + "[disable-usrmerge]" + ], + "items": { + "type": "string" + }, + "title": "Build-Attributes", + "type": "array" + }, + "organize": { + "additionalProperties": { + "type": "string" + }, + "description": "A map of files from the build directory to their destinations in the stage directory.", + "examples": [ + "{hello.py: bin/hello}" + ], + "title": "Organize", + "type": "object" + }, + "overlay": { + "description": "The files to copy from the part's layer to the stage directory.", + "examples": [ + "[bin, usr/bin]", + "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" + ], + "items": { + "type": "string" + }, + "title": "Overlay", + "type": "array" + }, + "stage": { + "description": "The files to copy from the build directory to the stage directory.", + "examples": [ + "[usr/bin/*, usr/share]", + "[-usr, zfsutils-linux]" + ], + "items": { + "description": "relative path", + "minLength": 1, + "type": "string" + }, + "title": "Stage", + "type": "array" + }, + "prime": { + "description": "", + "examples": [ + "[usr/lib/*/qt6/plugins/tls/*, -usr/share/thumbnailers]" + ], + "items": { + "description": "relative path", + "minLength": 1, + "type": "string" + }, + "title": "Prime", + "type": "array" + }, + "override-pull": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The commands to run instead of the default behavior of the pull step.", + "examples": [ + "|\n craftctl default\n rm $CRAFT_PART_SRC/pyproject.toml" + ], + "title": "Override-Pull" + }, + "overlay-script": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The commands to run after the part's overlay packages are installed.", + "examples": [ + "|\n rm -f ${CRAFT_OVERLAY}/usr/bin/vi ${CRAFT_OVERLAY}/usr/bin/vim*\n rm -f ${CRAFT_OVERLAY}/usr/bin/emacs*\n rm -f ${CRAFT_OVERLAY}/bin/nano" + ], + "title": "Overlay-Script" + }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, + "override-build": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The commands to run instead of the default behavior of the build step.", + "examples": [ + "|\n cd cmd/webhook\n mkdir $CRAFT_PART_INSTALL/ko-app\n go build -o $CRAFT_PART_INSTALL/ko-app/webhook -a ." + ], + "title": "Override-Build" + }, + "override-stage": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The commands to run instead of the default behavior of the stage step.", + "examples": [ + "|\n craftctl default\n chown -R 499 \"${CRAFT_PART_INSTALL}/entrypoint.sh\"" + ], + "title": "Override-Stage" + }, + "override-prime": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The commands to run instead of the default behavior of the prime step.", + "examples": [ + "|\n craftctl default\n mkdir -p $CRAFT_PRIME/var/lib/mysql\n mkdir -p $CRAFT_PRIME/var/lib/mysqld" + ], + "title": "Override-Prime" + }, + "permissions": { + "default": [], + "description": "The ownership and permission settings for a set of files in the part's prime directory.", + "examples": [ + "[{owner: 2000, group: 2000}, {path: srv/indico/start-indico.sh, mode: \"544\"}, {path: etc/, mode: \"755\"}]" + ], + "items": { + "$ref": "#/$defs/Permissions" + }, + "title": "Permissions", + "type": "array" + } + }, + "additionalProperties": false + } + }, + { + "if": { + "properties": { + "plugin": { + "const": "autotools" + } + } + }, + "then": { + "$comment": "common properties had to be repeated here or they would be considered invalid by the schema validator otherwise", + "properties": { + "plugin": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The plugin to build the part with.", + "examples": [ + "python", + "dump" + ], + "title": "Plugin", + "enum": [ + "dump", + "nil", + "ant", + "autotools", + "bazel", + "cargo-use", + "cmake", + "dotnet", + "go", + "go-use", + "gradle", + "jlink", + "make", + "maven", + "maven-use", + "meson", + "npm", + "npm-use", + "poetry", + "python", + "qmake", + "ruby", + "rust", + "scons", + "uv" + ] + }, + "source": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The location of the source files for the part.", + "examples": [ + ".", + "https://github.com/canonical/dqlite" + ], + "title": "Source" + }, + "autotools-configure-parameters": { + "default": [], + "items": { + "type": "string" + }, + "title": "Autotools-Configure-Parameters", + "type": "array" + }, + "autotools-bootstrap-parameters": { + "default": [], + "items": { + "type": "string" + }, + "title": "Autotools-Bootstrap-Parameters", + "type": "array" + }, + "disable-parallel": { + "default": false, + "description": "Whether to disable CPU multithreading during the build step.", + "examples": [ + "true" + ], + "title": "Disable-Parallel", + "type": "boolean" + }, "source-checksum": { "default": "", "description": "The checksum of the downloaded source, to ensure integrity.", @@ -1457,15 +2827,6 @@ "title": "Source-Type", "type": "string" }, - "disable-parallel": { - "default": false, - "description": "Whether to disable CPU multithreading during the build step.", - "examples": [ - "true" - ], - "title": "Disable-Parallel", - "type": "boolean" - }, "after": { "default": [], "description": "The parts to process before starting this part's build.", @@ -1480,7 +2841,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -1578,7 +2939,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -1648,6 +3009,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -1716,7 +3093,7 @@ "if": { "properties": { "plugin": { - "const": "autotools" + "const": "bazel" } } }, @@ -1740,12 +3117,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -1754,11 +3133,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -1781,30 +3161,35 @@ ], "title": "Source" }, - "autotools-configure-parameters": { - "default": [], + "bazel-targets": { + "default": [ + "//..." + ], "items": { "type": "string" }, - "title": "Autotools-Configure-Parameters", + "title": "Bazel-Targets", "type": "array" }, - "autotools-bootstrap-parameters": { + "bazel-parameters": { "default": [], "items": { "type": "string" }, - "title": "Autotools-Bootstrap-Parameters", + "title": "Bazel-Parameters", "type": "array" }, - "disable-parallel": { - "default": false, - "description": "Whether to disable CPU multithreading during the build step.", + "after": { + "default": [], + "description": "The parts to process before starting this part's build.", "examples": [ - "true" + "[build-deps, daemon]" ], - "title": "Disable-Parallel", - "type": "boolean" + "items": { + "type": "string" + }, + "title": "After", + "type": "array" }, "source-checksum": { "default": "", @@ -1904,21 +3289,18 @@ "title": "Source-Type", "type": "string" }, - "after": { - "default": [], - "description": "The parts to process before starting this part's build.", + "disable-parallel": { + "default": false, + "description": "Whether to disable CPU multithreading during the build step.", "examples": [ - "[build-deps, daemon]" + "true" ], - "items": { - "type": "string" - }, - "title": "After", - "type": "array" + "title": "Disable-Parallel", + "type": "boolean" }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -2016,7 +3398,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -2086,6 +3468,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -2178,12 +3576,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -2192,11 +3592,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -2340,7 +3741,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -2438,7 +3839,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -2508,6 +3909,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -2600,12 +4017,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -2614,11 +4033,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -2775,7 +4195,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -2873,7 +4293,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -2943,6 +4363,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -3035,12 +4471,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -3049,11 +4487,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -3214,7 +4653,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -3312,7 +4751,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -3382,6 +4821,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -3450,7 +4905,7 @@ "if": { "properties": { "plugin": { - "const": "dump" + "const": "go" } } }, @@ -3474,12 +4929,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -3488,11 +4945,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -3515,6 +4973,22 @@ ], "title": "Source" }, + "go-buildtags": { + "default": [], + "items": { + "type": "string" + }, + "title": "Go-Buildtags", + "type": "array" + }, + "go-generate": { + "default": [], + "items": { + "type": "string" + }, + "title": "Go-Generate", + "type": "array" + }, "source-checksum": { "default": "", "description": "The checksum of the downloaded source, to ensure integrity.", @@ -3636,7 +5110,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -3734,7 +5208,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -3804,6 +5278,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -3872,7 +5362,7 @@ "if": { "properties": { "plugin": { - "const": "go" + "const": "go-use" } } }, @@ -3896,12 +5386,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -3910,11 +5402,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -3937,22 +5430,6 @@ ], "title": "Source" }, - "go-buildtags": { - "default": [], - "items": { - "type": "string" - }, - "title": "Go-Buildtags", - "type": "array" - }, - "go-generate": { - "default": [], - "items": { - "type": "string" - }, - "title": "Go-Generate", - "type": "array" - }, "source-checksum": { "default": "", "description": "The checksum of the downloaded source, to ensure integrity.", @@ -4074,7 +5551,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -4172,7 +5649,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -4242,6 +5719,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -4310,7 +5803,7 @@ "if": { "properties": { "plugin": { - "const": "go-use" + "const": "gradle" } } }, @@ -4334,12 +5827,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -4348,11 +5843,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -4375,6 +5871,29 @@ ], "title": "Source" }, + "gradle-init-script": { + "default": "", + "title": "Gradle-Init-Script", + "type": "string" + }, + "gradle-parameters": { + "default": [], + "items": { + "type": "string" + }, + "title": "Gradle-Parameters", + "type": "array" + }, + "gradle-task": { + "default": "build", + "title": "Gradle-Task", + "type": "string" + }, + "gradle-use-daemon": { + "default": false, + "title": "Gradle-Use-Daemon", + "type": "boolean" + }, "source-checksum": { "default": "", "description": "The checksum of the downloaded source, to ensure integrity.", @@ -4496,7 +6015,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -4594,7 +6113,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -4664,6 +6183,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -4732,7 +6267,7 @@ "if": { "properties": { "plugin": { - "const": "gradle" + "const": "jlink" } } }, @@ -4756,12 +6291,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -4770,11 +6307,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -4797,23 +6335,41 @@ ], "title": "Source" }, - "gradle-init-script": { - "default": "", - "title": "Gradle-Init-Script", - "type": "string" + "jlink-jars": { + "default": [], + "items": { + "type": "string" + }, + "title": "Jlink-Jars", + "type": "array" + }, + "jlink-extra-modules": { + "default": [], + "items": { + "type": "string" + }, + "title": "Jlink-Extra-Modules", + "type": "array" }, - "gradle-parameters": { + "jlink-modules": { "default": [], "items": { "type": "string" }, - "title": "Gradle-Parameters", + "title": "Jlink-Modules", "type": "array" }, - "gradle-task": { - "default": "build", - "title": "Gradle-Task", - "type": "string" + "jlink-multi-release": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "default": "base", + "title": "Jlink-Multi-Release" }, "source-checksum": { "default": "", @@ -4936,7 +6492,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -5034,7 +6590,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -5104,6 +6660,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -5172,7 +6744,7 @@ "if": { "properties": { "plugin": { - "const": "jlink" + "const": "make" } } }, @@ -5196,12 +6768,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -5210,11 +6784,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -5237,20 +6812,12 @@ ], "title": "Source" }, - "jlink-jars": { - "default": [], - "items": { - "type": "string" - }, - "title": "Jlink-Jars", - "type": "array" - }, - "jlink-extra-modules": { + "make-parameters": { "default": [], "items": { "type": "string" }, - "title": "Jlink-Extra-Modules", + "title": "Make-Parameters", "type": "array" }, "source-checksum": { @@ -5374,7 +6941,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -5472,7 +7039,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -5542,6 +7109,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -5610,7 +7193,7 @@ "if": { "properties": { "plugin": { - "const": "make" + "const": "maven" } } }, @@ -5634,12 +7217,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -5648,11 +7233,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -5675,14 +7261,19 @@ ], "title": "Source" }, - "make-parameters": { + "maven-parameters": { "default": [], "items": { "type": "string" }, - "title": "Make-Parameters", + "title": "Maven-Parameters", "type": "array" }, + "maven-use-wrapper": { + "default": false, + "title": "Maven-Use-Wrapper", + "type": "boolean" + }, "source-checksum": { "default": "", "description": "The checksum of the downloaded source, to ensure integrity.", @@ -5804,7 +7395,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -5902,7 +7493,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -5972,6 +7563,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -6040,7 +7647,7 @@ "if": { "properties": { "plugin": { - "const": "maven" + "const": "maven-use" } } }, @@ -6064,12 +7671,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -6078,11 +7687,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -6105,19 +7715,14 @@ ], "title": "Source" }, - "maven-parameters": { + "maven-use-parameters": { "default": [], "items": { "type": "string" }, - "title": "Maven-Parameters", + "title": "Maven-Use-Parameters", "type": "array" }, - "maven-use-wrapper": { - "default": false, - "title": "Maven-Use-Wrapper", - "type": "boolean" - }, "source-checksum": { "default": "", "description": "The checksum of the downloaded source, to ensure integrity.", @@ -6239,7 +7844,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -6337,7 +7942,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -6407,6 +8012,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -6475,7 +8096,7 @@ "if": { "properties": { "plugin": { - "const": "maven-use" + "const": "meson" } } }, @@ -6499,12 +8120,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -6513,11 +8136,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -6540,12 +8164,12 @@ ], "title": "Source" }, - "maven-use-parameters": { + "meson-parameters": { "default": [], "items": { "type": "string" }, - "title": "Maven-Use-Parameters", + "title": "Meson-Parameters", "type": "array" }, "source-checksum": { @@ -6669,7 +8293,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -6767,7 +8391,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -6837,6 +8461,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -6905,7 +8545,7 @@ "if": { "properties": { "plugin": { - "const": "meson" + "const": "npm" } } }, @@ -6929,12 +8569,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -6943,11 +8585,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -6970,12 +8613,34 @@ ], "title": "Source" }, - "meson-parameters": { + "npm-include-node": { + "default": false, + "title": "Npm-Include-Node", + "type": "boolean" + }, + "npm-node-version": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "title": "Npm-Node-Version" + }, + "build-attributes": { "default": [], + "description": "Identifiers that control specific behaviors during the build.", + "examples": [ + "[enable-usrmerge]", + "[disable-usrmerge]" + ], "items": { "type": "string" }, - "title": "Meson-Parameters", + "title": "Build-Attributes", "type": "array" }, "source-checksum": { @@ -7099,7 +8764,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -7172,19 +8837,6 @@ "title": "Build-Environment", "type": "array" }, - "build-attributes": { - "default": [], - "description": "Identifiers that control specific behaviors during the build.", - "examples": [ - "[enable-usrmerge]", - "[disable-usrmerge]" - ], - "items": { - "type": "string" - }, - "title": "Build-Attributes", - "type": "array" - }, "organize": { "additionalProperties": { "type": "string" @@ -7197,7 +8849,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -7267,6 +8919,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -7335,7 +9003,7 @@ "if": { "properties": { "plugin": { - "const": "nil" + "const": "npm-use" } } }, @@ -7359,12 +9027,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -7373,11 +9043,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -7400,6 +9071,36 @@ ], "title": "Source" }, + "npm-include-node": { + "default": false, + "title": "Npm-Include-Node", + "type": "boolean" + }, + "npm-node-version": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "title": "Npm-Node-Version" + }, + "build-attributes": { + "default": [], + "description": "Identifiers that control specific behaviors during the build.", + "examples": [ + "[enable-usrmerge]", + "[disable-usrmerge]" + ], + "items": { + "type": "string" + }, + "title": "Build-Attributes", + "type": "array" + }, "source-checksum": { "default": "", "description": "The checksum of the downloaded source, to ensure integrity.", @@ -7521,7 +9222,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -7594,19 +9295,6 @@ "title": "Build-Environment", "type": "array" }, - "build-attributes": { - "default": [], - "description": "Identifiers that control specific behaviors during the build.", - "examples": [ - "[enable-usrmerge]", - "[disable-usrmerge]" - ], - "items": { - "type": "string" - }, - "title": "Build-Attributes", - "type": "array" - }, "organize": { "additionalProperties": { "type": "string" @@ -7619,7 +9307,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -7689,6 +9377,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -7757,7 +9461,7 @@ "if": { "properties": { "plugin": { - "const": "npm" + "const": "poetry" } } }, @@ -7781,12 +9485,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -7795,11 +9501,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -7822,22 +9529,30 @@ ], "title": "Source" }, - "npm-include-node": { - "default": false, - "title": "Npm-Include-Node", - "type": "boolean" + "poetry-with": { + "description": "dependency groups to include. By default, only the main dependencies are included.", + "items": { + "type": "string" + }, + "title": "Dependency groups to include", + "type": "array", + "uniqueItems": true }, - "npm-node-version": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "null" - } - ], - "default": null, - "title": "Npm-Node-Version" + "poetry-export-extra-args": { + "description": "extra arguments to pass to poetry export when creating requirements.txt.", + "items": { + "type": "string" + }, + "title": "Extra arguments for poetry export", + "type": "array" + }, + "poetry-pip-extra-args": { + "description": "extra arguments to pass to pip install installing dependencies.", + "items": { + "type": "string" + }, + "title": "Extra arguments for pip install", + "type": "array" }, "source-checksum": { "default": "", @@ -7960,7 +9675,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -8058,7 +9773,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -8128,6 +9843,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -8196,7 +9927,7 @@ "if": { "properties": { "plugin": { - "const": "poetry" + "const": "python" } } }, @@ -8220,12 +9951,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -8234,11 +9967,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -8261,29 +9995,32 @@ ], "title": "Source" }, - "poetry-with": { - "description": "dependency groups to include. By default, only the main dependencies are included.", + "python-requirements": { + "default": [], "items": { "type": "string" }, - "title": "Dependency groups to include", - "type": "array", - "uniqueItems": true + "title": "Python-Requirements", + "type": "array" }, - "poetry-export-extra-args": { - "description": "extra arguments to pass to poetry export when creating requirements.txt.", + "python-constraints": { + "default": [], "items": { "type": "string" }, - "title": "Extra arguments for poetry export", + "title": "Python-Constraints", "type": "array" }, - "poetry-pip-extra-args": { - "description": "extra arguments to pass to pip install installing dependencies.", + "python-packages": { + "default": [ + "pip", + "setuptools", + "wheel" + ], "items": { "type": "string" }, - "title": "Extra arguments for pip install", + "title": "Python-Packages", "type": "array" }, "source-checksum": { @@ -8407,7 +10144,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -8505,7 +10242,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -8575,6 +10312,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -8643,7 +10396,7 @@ "if": { "properties": { "plugin": { - "const": "python" + "const": "qmake" } } }, @@ -8667,12 +10420,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -8681,11 +10436,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -8708,33 +10464,23 @@ ], "title": "Source" }, - "python-requirements": { + "qmake-parameters": { "default": [], "items": { "type": "string" }, - "title": "Python-Requirements", + "title": "Qmake-Parameters", "type": "array" }, - "python-constraints": { - "default": [], - "items": { - "type": "string" - }, - "title": "Python-Constraints", - "type": "array" + "qmake-project-file": { + "default": "", + "title": "Qmake-Project-File", + "type": "string" }, - "python-packages": { - "default": [ - "pip", - "setuptools", - "wheel" - ], - "items": { - "type": "string" - }, - "title": "Python-Packages", - "type": "array" + "qmake-major-version": { + "default": 5, + "title": "Qmake-Major-Version", + "type": "integer" }, "source-checksum": { "default": "", @@ -8857,7 +10603,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -8955,7 +10701,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -9025,6 +10771,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -9093,7 +10855,7 @@ "if": { "properties": { "plugin": { - "const": "qmake" + "const": "ruby" } } }, @@ -9117,12 +10879,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -9131,11 +10895,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -9158,23 +10923,59 @@ ], "title": "Source" }, - "qmake-parameters": { + "ruby-gems": { "default": [], "items": { "type": "string" }, - "title": "Qmake-Parameters", + "title": "Ruby-Gems", "type": "array" }, - "qmake-project-file": { - "default": "", - "title": "Qmake-Project-File", - "type": "string" + "ruby-use-bundler": { + "default": false, + "title": "Ruby-Use-Bundler", + "type": "boolean" }, - "qmake-major-version": { - "default": 5, - "title": "Qmake-Major-Version", - "type": "integer" + "ruby-flavor": { + "anyOf": [ + { + "$ref": "#/$defs/RubyFlavor" + }, + { + "type": "null" + } + ], + "default": null + }, + "ruby-version": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "title": "Ruby-Version" + }, + "ruby-use-jemalloc": { + "default": false, + "title": "Ruby-Use-Jemalloc", + "type": "boolean" + }, + "ruby-shared": { + "default": false, + "title": "Ruby-Shared", + "type": "boolean" + }, + "ruby-configure-options": { + "default": [], + "items": { + "type": "string" + }, + "title": "Ruby-Configure-Options", + "type": "array" }, "source-checksum": { "default": "", @@ -9297,7 +11098,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -9395,7 +11196,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -9465,6 +11266,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -9557,12 +11374,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -9571,11 +11390,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -9777,7 +11597,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -9875,7 +11695,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -9945,6 +11765,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -10037,12 +11873,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -10051,11 +11889,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -10207,7 +12046,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -10305,7 +12144,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -10375,6 +12214,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -10467,12 +12322,14 @@ ], "title": "Plugin", "enum": [ + "dump", + "nil", "ant", "autotools", + "bazel", "cargo-use", "cmake", "dotnet", - "dump", "go", "go-use", "gradle", @@ -10481,11 +12338,12 @@ "maven", "maven-use", "meson", - "nil", "npm", + "npm-use", "poetry", "python", "qmake", + "ruby", "rust", "scons", "uv" @@ -10647,7 +12505,7 @@ }, "overlay-packages": { "default": [], - "description": "The packages to install in the part's overlay filesystem.", + "description": "The packages to install in the part's layer.", "examples": [ "[ed]" ], @@ -10745,7 +12603,7 @@ "type": "object" }, "overlay": { - "description": "The files to copy from the part's overly filesystem to the stage directory.", + "description": "The files to copy from the part's layer to the stage directory.", "examples": [ "[bin, usr/bin]", "[-etc/cloud/cloud.cfg.d/90_dpkg.cfg]" @@ -10815,6 +12673,22 @@ ], "title": "Overlay-Script" }, + "override-overlay": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Shell script to run inside the overlay chroot after mounting.", + "examples": [ + "echo 'hello from chroot' > /root/test.txt" + ], + "title": "Override-Overlay" + }, "override-build": { "anyOf": [ { @@ -10932,6 +12806,17 @@ }, "title": "Permissions", "type": "object" + }, + "RubyFlavor": { + "description": "All Ruby implementations supported by ruby-install.", + "enum": [ + "ruby", + "jruby", + "truffleruby", + "mruby" + ], + "title": "RubyFlavor", + "type": "string" } }, "additionalProperties": false, @@ -11014,7 +12899,8 @@ "ubuntu@20.04", "ubuntu@22.04", "ubuntu@24.04", - "ubuntu@25.10" + "ubuntu@25.10", + "ubuntu@26.04" ], "title": "Base", "type": "string" @@ -11027,6 +12913,7 @@ "ubuntu@22.04", "ubuntu@24.04", "ubuntu@25.10", + "ubuntu@26.04", "devel" ], "type": "string" @@ -11099,6 +12986,19 @@ ] } }, + "propertyNames": { + "description": "The name of this platform. May not contain '/'", + "examples": [ + "riscv64", + "my-special-platform" + ], + "not": { + "enum": [ + "*", + "any" + ] + } + }, "title": "Platforms", "type": "object" }, diff --git a/src/craft_ls/schemas/snapcraft.json b/src/craft_ls/schemas/snapcraft.json index 3119bff..3c83a80 100644 --- a/src/craft_ls/schemas/snapcraft.json +++ b/src/craft_ls/schemas/snapcraft.json @@ -273,6 +273,25 @@ "examples": ["on-failure"], "title": "Restart-Condition" }, + "success-exit-status": { + "anyOf": [ + { + "items": { + "maximum": 255, + "minimum": 1, + "type": "integer" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The list of additional successful exit statuses that the service can return.", + "examples": ["[42, 250]"], + "title": "Success-Exit-Status" + }, "install-mode": { "anyOf": [ { @@ -473,8 +492,8 @@ "uniqueItems": true } ], - "description": "The architectures on which the snap can be built.", - "examples": ["[amd64, riscv64]"], + "description": "The architectures to build the snap on.", + "examples": ["arm64", "[amd64, riscv64]"], "title": "Build-On" }, "build-for": { @@ -494,8 +513,8 @@ } ], "default": null, - "description": "The single element list containing the architecture where the snap can be run", - "examples": ["[amd64]", "[riscv64]"], + "description": "The target architecture for the build.", + "examples": ["amd64", "[riscv64]"], "title": "Build-For" } }, @@ -504,7 +523,7 @@ "type": "object" }, "BareCore22Project": { - "$id": "urn:snapcraft:bare22", + "$id": "urn:snapcraft:bare22", "additionalProperties": false, "properties": { "name": { @@ -552,7 +571,7 @@ "summary": { "anyOf": [ { - "description": "A short description of the project.", + "description": "A short description of the project. Maximum length 78 characters.", "examples": ["Linux for Human Beings", "The cross-platform desktop application for JupyterLab", "Container and VM manager", "Photo Management Program", "Charm for routing MySQL databases in Kubernetes", "An open-source event streaming platform for high-performance data pipelines"], "maxLength": 78, "title": "Summary", @@ -759,8 +778,7 @@ }, "type": { "default": null, - "description": "The snap's type.", - "enum": ["app", "gadget", "kernel", "snapd", null], + "enum": ["app", "gadget", null], "title": "Type" }, "icon": { @@ -844,7 +862,7 @@ } ], "default": null, - "description": "The architecture sets where the snap can be built and where the resulting snap can run.", + "description": "The architectures that the snap builds and runs on.", "examples": ["[amd64, riscv64]", "[{build-on: [amd64], build-for: [amd64]}]", "[{build-on: [amd64, riscv64], build-for: [riscv64]}]"], "title": "Architectures" }, @@ -903,7 +921,7 @@ } ], "default": null, - "description": "The map of app names representing entry points to run for the snap.", + "description": "The individual programs and services that the snap runs.", "examples": ["{app-1: {command: bin/app-1}}"], "title": "Apps" }, @@ -982,7 +1000,7 @@ } ], "default": null, - "description": "The system usernames that the snap can use to run daemons and services.", + "description": "The system usernames the snap can use to run daemons and services.", "examples": ["{snap-daemon: shared}"], "title": "System-Usernames" }, @@ -1092,7 +1110,7 @@ "type": "object" }, "BareCore24Project": { - "$id": "urn:snapcraft:bare24", + "$id": "urn:snapcraft:bare24", "additionalProperties": false, "properties": { "name": { @@ -1140,7 +1158,7 @@ "summary": { "anyOf": [ { - "description": "A short description of the project.", + "description": "A short description of the project. Maximum length 78 characters.", "examples": ["Linux for Human Beings", "The cross-platform desktop application for JupyterLab", "Container and VM manager", "Photo Management Program", "Charm for routing MySQL databases in Kubernetes", "An open-source event streaming platform for high-performance data pipelines"], "maxLength": 78, "title": "Summary", @@ -1371,9 +1389,7 @@ }, "type": { "default": null, - "description": "The snap's type.", - "enum": ["app", "gadget", "kernel", "snapd", null], - "examples": ["kernel"], + "enum": ["app", "gadget", null], "title": "Type" }, "icon": { @@ -1492,7 +1508,7 @@ } ], "default": null, - "description": "The map of app names representing entry points to run for the snap.", + "description": "The individual programs and services that the snap runs.", "examples": ["{app-1: {command: bin/app-1}}"], "title": "Apps" }, @@ -1571,7 +1587,7 @@ } ], "default": null, - "description": "The system usernames that the snap can use to run daemons and services.", + "description": "The system usernames the snap can use to run daemons and services.", "examples": ["{snap-daemon: shared}"], "title": "System-Usernames" }, @@ -1680,8 +1696,8 @@ "title": "BareCore24Project", "type": "object" }, - "BaseCore22Project": { - "$id": "urn:snapcraft:base22", + "BareCore26Project": { + "$id": "urn:snapcraft:bare26", "additionalProperties": false, "properties": { "name": { @@ -1729,7 +1745,7 @@ "summary": { "anyOf": [ { - "description": "A short description of the project.", + "description": "A short description of the project. Maximum length 78 characters.", "examples": ["Linux for Human Beings", "The cross-platform desktop application for JupyterLab", "Container and VM manager", "Photo Management Program", "Charm for routing MySQL databases in Kubernetes", "An open-source event streaming platform for high-performance data pipelines"], "maxLength": 78, "title": "Summary", @@ -1755,11 +1771,40 @@ "description": "The full description of the project.", "title": "Description" }, + "base": { + "const": "bare", + "title": "Base", + "type": "string" + }, "build-base": { - "const": "core22", + "const": "core26", "title": "Build-Base", "type": "string" }, + "platforms": { + "anyOf": [ + { + "additionalProperties": { + "anyOf": [ + { + "$ref": "#/$defs/Platform" + }, + { + "type": "null" + } + ] + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The platforms where the snap can be built and where the resulting snap can run.", + "examples": ["{amd64: {build-on: [amd64], build-for: [amd64]}, arm64: {build-on: [amd64, arm64], build-for: [arm64]}}"], + "title": "Platforms" + }, "contact": { "anyOf": [ { @@ -1930,9 +1975,9 @@ "title": "Website" }, "type": { - "const": "base", - "title": "Type", - "type": "string" + "default": null, + "enum": ["app", "gadget", null], + "title": "Type" }, "icon": { "anyOf": [ @@ -1995,30 +2040,6 @@ "examples": ["stable", "devel"], "title": "Grade" }, - "architectures": { - "anyOf": [ - { - "items": { - "anyOf": [ - { - "type": "string" - }, - { - "$ref": "#/$defs/Architecture" - } - ] - }, - "type": "array" - }, - { - "type": "null" - } - ], - "default": null, - "description": "The architecture sets where the snap can be built and where the resulting snap can run.", - "examples": ["[amd64, riscv64]", "[{build-on: [amd64], build-for: [amd64]}]", "[{build-on: [amd64, riscv64], build-for: [riscv64]}]"], - "title": "Architectures" - }, "assumes": { "description": "The minimum version of snapd and its features that the snap requires from the host.", "examples": ["[snapd2.66, common-data-dir]"], @@ -2074,7 +2095,7 @@ } ], "default": null, - "description": "The map of app names representing entry points to run for the snap.", + "description": "The individual programs and services that the snap runs.", "examples": ["{app-1: {command: bin/app-1}}"], "title": "Apps" }, @@ -2153,7 +2174,7 @@ } ], "default": null, - "description": "The system usernames that the snap can use to run daemons and services.", + "description": "The system usernames the snap can use to run daemons and services.", "examples": ["{snap-daemon: shared}"], "title": "System-Usernames" }, @@ -2258,12 +2279,12 @@ "title": "Components" } }, - "required": ["name", "build-base", "parts", "type", "confinement"], - "title": "BaseCore22Project", + "required": ["name", "base", "build-base", "parts", "confinement"], + "title": "BareCore26Project", "type": "object" }, - "BaseCore24Project": { - "$id": "urn:snapcraft:base24", + "BareDevelProject": { + "$id": "urn:snapcraft:baredevel", "additionalProperties": false, "properties": { "name": { @@ -2311,7 +2332,7 @@ "summary": { "anyOf": [ { - "description": "A short description of the project.", + "description": "A short description of the project. Maximum length 78 characters.", "examples": ["Linux for Human Beings", "The cross-platform desktop application for JupyterLab", "Container and VM manager", "Photo Management Program", "Charm for routing MySQL databases in Kubernetes", "An open-source event streaming platform for high-performance data pipelines"], "maxLength": 78, "title": "Summary", @@ -2337,8 +2358,13 @@ "description": "The full description of the project.", "title": "Description" }, + "base": { + "const": "bare", + "title": "Base", + "type": "string" + }, "build-base": { - "const": "core24", + "const": "devel", "title": "Build-Base", "type": "string" }, @@ -2536,9 +2562,9 @@ "title": "Website" }, "type": { - "const": "base", - "title": "Type", - "type": "string" + "default": null, + "enum": ["app", "gadget", null], + "title": "Type" }, "icon": { "anyOf": [ @@ -2587,19 +2613,9 @@ "title": "Layout" }, "grade": { - "anyOf": [ - { - "enum": ["stable", "devel"], - "type": "string" - }, - { - "type": "null" - } - ], - "default": null, - "description": "The quality grade of the snap.", - "examples": ["stable", "devel"], - "title": "Grade" + "const": "devel", + "title": "Grade", + "type": "string" }, "assumes": { "description": "The minimum version of snapd and its features that the snap requires from the host.", @@ -2656,7 +2672,7 @@ } ], "default": null, - "description": "The map of app names representing entry points to run for the snap.", + "description": "The individual programs and services that the snap runs.", "examples": ["{app-1: {command: bin/app-1}}"], "title": "Apps" }, @@ -2735,7 +2751,7 @@ } ], "default": null, - "description": "The system usernames that the snap can use to run daemons and services.", + "description": "The system usernames the snap can use to run daemons and services.", "examples": ["{snap-daemon: shared}"], "title": "System-Usernames" }, @@ -2840,12 +2856,139 @@ "title": "Components" } }, - "required": ["name", "build-base", "parts", "type", "confinement"], - "title": "BaseCore24Project", + "required": ["name", "base", "build-base", "parts", "confinement", "grade"], + "title": "BareDevelProject", + "type": "object" + }, + "Component": { + "additionalProperties": false, + "description": "Snapcraft component definition.", + "properties": { + "summary": { + "description": "The summary of the component.", + "examples": ["Language translations for the app"], + "maxLength": 78, + "title": "Summary", + "type": "string" + }, + "description": { + "description": "The full description of the component.", + "examples": ["Contains optional translation packs to allow the user to change the language."], + "title": "Description", + "type": "string" + }, + "type": { + "description": "The type of the component.", + "enum": ["test", "kernel-modules", "standard"], + "examples": ["standard"], + "title": "Type", + "type": "string" + }, + "version": { + "anyOf": [ + { + "description": "The version of the project, enclosed in quotation marks.", + "examples": ["\"0.1\"", "\"1.0.0\"", "\"v1.0.0\"", "\"24.04\""], + "maxLength": 32, + "title": "version string", + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The version of the component.", + "examples": ["1.2.3"], + "title": "Version" + }, + "hooks": { + "anyOf": [ + { + "additionalProperties": { + "$ref": "#/$defs/Hook" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The configuration for the component's hooks.", + "examples": ["{configure: {plugs: [home]}}"], + "title": "Hooks" + }, + "adopt-info": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Selects a part to inherit metadata from and reuse for the component's\nmetadata.\n\nOnly the component's version can be set.\n", + "examples": ["foo-part"], + "title": "Adopt-Info" + } + }, + "required": ["summary", "description", "type"], + "title": "Component", + "type": "object" + }, + "ContentPlug": { + "additionalProperties": false, + "description": "Snapcraft project content plug definition.", + "properties": { + "content": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The name for the content type.", + "examples": ["themes"], + "title": "Content" + }, + "interface": { + "description": "The name of the interface.", + "examples": ["network"], + "title": "Interface", + "type": "string" + }, + "target": { + "description": "The path to where the producer's files will be available in the snap.", + "examples": ["$SNAP/data-dir/themes"], + "title": "Target", + "type": "string" + }, + "default-provider": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The name of the producer snap..", + "examples": ["gtk-common-themes"], + "title": "Default-Provider" + } + }, + "required": ["interface", "target"], + "title": "ContentPlug", "type": "object" }, - "BaseDevelProject": { - "$id": "urn:snapcraft:devel", + "Core22Project": { + "$id": "urn:snapcraft:core22", "additionalProperties": false, "properties": { "name": { @@ -2893,7 +3036,7 @@ "summary": { "anyOf": [ { - "description": "A short description of the project.", + "description": "A short description of the project. Maximum length 78 characters.", "examples": ["Linux for Human Beings", "The cross-platform desktop application for JupyterLab", "Container and VM manager", "Photo Management Program", "Charm for routing MySQL databases in Kubernetes", "An open-source event streaming platform for high-performance data pipelines"], "maxLength": 78, "title": "Summary", @@ -2919,27 +3062,24 @@ "description": "The full description of the project.", "title": "Description" }, - "build-base": { - "const": "devel", - "title": "Build-Base", + "base": { + "const": "core22", + "title": "Base", "type": "string" }, - "platforms": { + "build-base": { "anyOf": [ { - "additionalProperties": { - "$ref": "#/$defs/Platform" - }, - "type": "object" + "type": "string" }, { "type": "null" } ], "default": null, - "description": "The platforms where the snap can be built and where the resulting snap can run.", - "examples": ["{amd64: {build-on: [amd64], build-for: [amd64]}, arm64: {build-on: [amd64, arm64], build-for: [arm64]}}"], - "title": "Platforms" + "description": "The baseline system that the snap is built in.", + "examples": ["core22", "core24", "core26", "devel"], + "title": "Build-Base" }, "contact": { "anyOf": [ @@ -3111,9 +3251,9 @@ "title": "Website" }, "type": { - "const": "base", - "title": "Type", - "type": "string" + "default": null, + "enum": ["app", "gadget", null], + "title": "Type" }, "icon": { "anyOf": [ @@ -3162,17 +3302,27 @@ "title": "Layout" }, "grade": { - "const": "devel", - "title": "Grade", - "type": "string" - }, - "architectures": { "anyOf": [ { - "items": { - "anyOf": [ - { - "type": "string" + "enum": ["stable", "devel"], + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The quality grade of the snap.", + "examples": ["stable", "devel"], + "title": "Grade" + }, + "architectures": { + "anyOf": [ + { + "items": { + "anyOf": [ + { + "type": "string" }, { "$ref": "#/$defs/Architecture" @@ -3186,7 +3336,7 @@ } ], "default": null, - "description": "The architecture sets where the snap can be built and where the resulting snap can run.", + "description": "The architectures that the snap builds and runs on.", "examples": ["[amd64, riscv64]", "[{build-on: [amd64], build-for: [amd64]}]", "[{build-on: [amd64, riscv64], build-for: [riscv64]}]"], "title": "Architectures" }, @@ -3245,7 +3395,7 @@ } ], "default": null, - "description": "The map of app names representing entry points to run for the snap.", + "description": "The individual programs and services that the snap runs.", "examples": ["{app-1: {command: bin/app-1}}"], "title": "Apps" }, @@ -3324,7 +3474,7 @@ } ], "default": null, - "description": "The system usernames that the snap can use to run daemons and services.", + "description": "The system usernames the snap can use to run daemons and services.", "examples": ["{snap-daemon: shared}"], "title": "System-Usernames" }, @@ -3429,139 +3579,12 @@ "title": "Components" } }, - "required": ["name", "build-base", "parts", "type", "confinement", "grade"], - "title": "BaseDevelProject", - "type": "object" - }, - "Component": { - "additionalProperties": false, - "description": "Snapcraft component definition.", - "properties": { - "summary": { - "description": "The summary of the component.", - "examples": ["Language translations for the app"], - "maxLength": 78, - "title": "Summary", - "type": "string" - }, - "description": { - "description": "The full description of the component.", - "examples": ["Contains optional translation packs to allow the user to change the language."], - "title": "Description", - "type": "string" - }, - "type": { - "description": "The type of the component.", - "enum": ["test", "kernel-modules", "standard"], - "examples": ["standard"], - "title": "Type", - "type": "string" - }, - "version": { - "anyOf": [ - { - "description": "The version of the project, enclosed in quotation marks.", - "examples": ["\"0.1\"", "\"1.0.0\"", "\"v1.0.0\"", "\"24.04\""], - "maxLength": 32, - "title": "version string", - "type": "string" - }, - { - "type": "null" - } - ], - "default": null, - "description": "The version of the component.", - "examples": ["1.2.3"], - "title": "Version" - }, - "hooks": { - "anyOf": [ - { - "additionalProperties": { - "$ref": "#/$defs/Hook" - }, - "type": "object" - }, - { - "type": "null" - } - ], - "default": null, - "description": "The configuration for the component's hooks.", - "examples": ["{configure: {plugs: [home]}}"], - "title": "Hooks" - }, - "adopt-info": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "null" - } - ], - "default": null, - "description": "Selects a part to inherit metadata from and reuse for the component's metadata.\n\nOnly the component's version can be set.\n", - "examples": ["foo-part"], - "title": "Adopt-Info" - } - }, - "required": ["summary", "description", "type"], - "title": "Component", - "type": "object" - }, - "ContentPlug": { - "additionalProperties": false, - "description": "Snapcraft project content plug definition.", - "properties": { - "content": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "null" - } - ], - "default": null, - "description": "The name for the content type.", - "examples": ["themes"], - "title": "Content" - }, - "interface": { - "description": "The name of the interface.", - "examples": ["network"], - "title": "Interface", - "type": "string" - }, - "target": { - "description": "The path to where the producer's files will be available in the snap.", - "examples": ["$SNAP/data-dir/themes"], - "title": "Target", - "type": "string" - }, - "default-provider": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "null" - } - ], - "default": null, - "description": "The name of the producer snap..", - "examples": ["gtk-common-themes"], - "title": "Default-Provider" - } - }, - "required": ["interface", "target"], - "title": "ContentPlug", + "required": ["name", "base", "parts", "confinement"], + "title": "Core22Project", "type": "object" }, - "Core22Project": { - "$id": "urn:snapcraft:core22", + "Core24Project": { + "$id": "urn:snapcraft:core24", "additionalProperties": false, "properties": { "name": { @@ -3609,7 +3632,7 @@ "summary": { "anyOf": [ { - "description": "A short description of the project.", + "description": "A short description of the project. Maximum length 78 characters.", "examples": ["Linux for Human Beings", "The cross-platform desktop application for JupyterLab", "Container and VM manager", "Photo Management Program", "Charm for routing MySQL databases in Kubernetes", "An open-source event streaming platform for high-performance data pipelines"], "maxLength": 78, "title": "Summary", @@ -3636,7 +3659,7 @@ "title": "Description" }, "base": { - "const": "core22", + "const": "core24", "title": "Base", "type": "string" }, @@ -3650,10 +3673,34 @@ } ], "default": null, - "description": "The build environment to use when building the snap", - "examples": ["core20", "core22", "core24", "devel"], + "description": "The baseline system that the snap is built in.", + "examples": ["core22", "core24", "core26", "devel"], "title": "Build-Base" }, + "platforms": { + "anyOf": [ + { + "additionalProperties": { + "anyOf": [ + { + "$ref": "#/$defs/Platform" + }, + { + "type": "null" + } + ] + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The platforms where the snap can be built and where the resulting snap can run.", + "examples": ["{amd64: {build-on: [amd64], build-for: [amd64]}, arm64: {build-on: [amd64, arm64], build-for: [arm64]}}"], + "title": "Platforms" + }, "contact": { "anyOf": [ { @@ -3825,8 +3872,7 @@ }, "type": { "default": null, - "description": "The snap's type.", - "enum": ["app", "gadget", "kernel", "snapd", null], + "enum": ["app", "gadget", null], "title": "Type" }, "icon": { @@ -3890,30 +3936,6 @@ "examples": ["stable", "devel"], "title": "Grade" }, - "architectures": { - "anyOf": [ - { - "items": { - "anyOf": [ - { - "type": "string" - }, - { - "$ref": "#/$defs/Architecture" - } - ] - }, - "type": "array" - }, - { - "type": "null" - } - ], - "default": null, - "description": "The architecture sets where the snap can be built and where the resulting snap can run.", - "examples": ["[amd64, riscv64]", "[{build-on: [amd64], build-for: [amd64]}]", "[{build-on: [amd64, riscv64], build-for: [riscv64]}]"], - "title": "Architectures" - }, "assumes": { "description": "The minimum version of snapd and its features that the snap requires from the host.", "examples": ["[snapd2.66, common-data-dir]"], @@ -3969,7 +3991,7 @@ } ], "default": null, - "description": "The map of app names representing entry points to run for the snap.", + "description": "The individual programs and services that the snap runs.", "examples": ["{app-1: {command: bin/app-1}}"], "title": "Apps" }, @@ -4048,7 +4070,7 @@ } ], "default": null, - "description": "The system usernames that the snap can use to run daemons and services.", + "description": "The system usernames the snap can use to run daemons and services.", "examples": ["{snap-daemon: shared}"], "title": "System-Usernames" }, @@ -4154,11 +4176,11 @@ } }, "required": ["name", "base", "parts", "confinement"], - "title": "Core22Project", + "title": "Core24Project", "type": "object" }, - "Core24Project": { - "$id": "urn:snapcraft:core24", + "Core26Project": { + "$id": "urn:snapcraft:core26", "additionalProperties": false, "properties": { "name": { @@ -4206,7 +4228,7 @@ "summary": { "anyOf": [ { - "description": "A short description of the project.", + "description": "A short description of the project. Maximum length 78 characters.", "examples": ["Linux for Human Beings", "The cross-platform desktop application for JupyterLab", "Container and VM manager", "Photo Management Program", "Charm for routing MySQL databases in Kubernetes", "An open-source event streaming platform for high-performance data pipelines"], "maxLength": 78, "title": "Summary", @@ -4233,7 +4255,7 @@ "title": "Description" }, "base": { - "const": "core24", + "const": "core26", "title": "Base", "type": "string" }, @@ -4247,8 +4269,8 @@ } ], "default": null, - "description": "The build environment to use when building the snap", - "examples": ["core20", "core22", "core24", "devel"], + "description": "The baseline system that the snap is built in.", + "examples": ["core22", "core24", "core26", "devel"], "title": "Build-Base" }, "platforms": { @@ -4446,9 +4468,7 @@ }, "type": { "default": null, - "description": "The snap's type.", - "enum": ["app", "gadget", "kernel", "snapd", null], - "examples": ["kernel"], + "enum": ["app", "gadget", null], "title": "Type" }, "icon": { @@ -4567,7 +4587,7 @@ } ], "default": null, - "description": "The map of app names representing entry points to run for the snap.", + "description": "The individual programs and services that the snap runs.", "examples": ["{app-1: {command: bin/app-1}}"], "title": "Apps" }, @@ -4646,7 +4666,7 @@ } ], "default": null, - "description": "The system usernames that the snap can use to run daemons and services.", + "description": "The system usernames the snap can use to run daemons and services.", "examples": ["{snap-daemon: shared}"], "title": "System-Usernames" }, @@ -4752,65 +4772,1819 @@ } }, "required": ["name", "base", "parts", "confinement"], - "title": "Core24Project", + "title": "Core26Project", "type": "object" }, - "Hook": { + "DevelBaseProject": { + "$id": "urn:snapcraft:basedevel", "additionalProperties": false, - "description": "Snapcraft project hook definition.", "properties": { - "command-chain": { - "description": "The ordered list of commands to run before the hook runs.", - "examples": ["[bin/alsa-launch, bin/desktop-launch]"], - "items": { - "type": "string" - }, - "title": "Command-Chain", - "type": "array" + "name": { + "description": "The identifying name of the snap.", + "examples": ["my-app", "powershell", "jupyterlab-desktop"], + "maxLength": 40, + "title": "Name", + "type": "string" }, - "environment": { + "title": { "anyOf": [ { - "additionalProperties": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "null" - } - ] - }, - "type": "object" + "description": "A human-readable title.", + "examples": ["Ubuntu Linux", "Jupyter Lab Desktop", "LXD", "DigiKam", "Apache Kafka", "MySQL Router K8s charm"], + "maxLength": 40, + "minLength": 2, + "title": "Title", + "type": "string" }, { "type": "null" } ], "default": null, - "description": "The environment variables for the hook.", - "examples": ["{PYTHONPATH: /custom/path/:$PYTHON_PATH, DISABLE_WAYLAND: 1}"], - "title": "Environment" + "title": "Title" }, - "plugs": { + "version": { "anyOf": [ { - "items": { - "type": "string" - }, - "type": "array", - "uniqueItems": true + "description": "The version of the project, enclosed in quotation marks.", + "examples": ["\"0.1\"", "\"1.0.0\"", "\"v1.0.0\"", "\"24.04\""], + "maxLength": 32, + "title": "version string", + "type": "string" }, { "type": "null" } ], "default": null, - "description": "The list of interfaces that the hook can connect to.", - "examples": ["[home, removable-media]"], + "description": "The version of the snap.", + "examples": ["1.2.3"], + "title": "Version" + }, + "summary": { + "anyOf": [ + { + "description": "A short description of the project. Maximum length 78 characters.", + "examples": ["Linux for Human Beings", "The cross-platform desktop application for JupyterLab", "Container and VM manager", "Photo Management Program", "Charm for routing MySQL databases in Kubernetes", "An open-source event streaming platform for high-performance data pipelines"], + "maxLength": 78, + "title": "Summary", + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "title": "Summary" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The full description of the project.", + "title": "Description" + }, + "base": { + "const": "devel", + "title": "Base", + "type": "string" + }, + "build-base": { + "const": "devel", + "title": "Build-Base", + "type": "string" + }, + "platforms": { + "anyOf": [ + { + "additionalProperties": { + "anyOf": [ + { + "$ref": "#/$defs/Platform" + }, + { + "type": "null" + } + ] + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The platforms where the snap can be built and where the resulting snap can run.", + "examples": ["{amd64: {build-on: [amd64], build-for: [amd64]}, arm64: {build-on: [amd64, arm64], build-for: [arm64]}}"], + "title": "Platforms" + }, + "contact": { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The snap author's contact links and email addresses.", + "examples": ["[contact@example.com, https://example.com/contact]"], + "title": "Contact" + }, + "issues": { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The links and email addresses for submitting issues, bugs, and feature requests.", + "examples": ["[issues@email.com, https://example.com/issues]"], + "title": "Issues" + }, + "source-code": { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The links to the source code of the snap or the original project.", + "examples": ["[https://example.com/source-code]"], + "title": "Source-Code" + }, + "license": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The project's license as an SPDX expression", + "examples": ["GPL-3.0+", "Apache-2.0"], + "title": "License" + }, + "adopt-info": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Selects a part to inherit metadata from and reuse for the snap's metadata.\n\nRequired if one of ``version``, ``summary``, or ``description`` isn't set.", + "examples": ["foo-part"], + "title": "Adopt-Info" + }, + "parts": { + "additionalProperties": { + "additionalProperties": true, + "type": "object" + }, + "description": "The self-contained software pieces needed to create the final artifact.", + "examples": ["{cloud-init: {plugin: python, source-type: git, source: https://git.launchpad.net/cloud-init}}"], + "title": "Parts", + "type": "object" + }, + "package-repositories": { + "anyOf": [ + { + "items": { + "additionalProperties": true, + "type": "object" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The package repositories to use for build and stage packages.", + "examples": ["[{type: apt, components: [main], suites: [xenial], key-id: 78E1918602959B9C59103100F1831DDAFC42E99D, url: http://ppa.launchpad.net/snappy-dev/snapcraft-daily/ubuntu}]"], + "title": "Package-Repositories" + }, + "compression": { + "default": "xz", + "description": "Specifies the algorithm that compresses the snap.", + "enum": ["lzo", "xz"], + "examples": ["xz", "lzo"], + "title": "Compression", + "type": "string" + }, + "donation": { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The snap's donation links.", + "examples": ["[donate@example.com, https://example.com/donate]"], + "title": "Donation" + }, + "website": { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The links to the original software's web pages.", + "examples": ["[https://example.com]"], + "title": "Website" + }, + "type": { + "default": null, + "enum": ["app", "gadget", null], + "title": "Type" + }, + "icon": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The path to the snap's icon.", + "examples": ["snap/gui/icon.svg"], + "title": "Icon" + }, + "confinement": { + "description": "The amount of isolation the snap has from the host system.", + "enum": ["classic", "devmode", "strict"], + "examples": ["strict", "classic", "devmode"], + "title": "Confinement", + "type": "string" + }, + "layout": { + "anyOf": [ + { + "additionalProperties": { + "additionalProperties": { + "type": "string" + }, + "maxProperties": 1, + "minProperties": 1, + "propertyNames": { + "enum": ["symlink", "bind", "bind-file", "type"] + }, + "type": "object" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The file layouts in the execution environment.", + "examples": ["{/var/lib/foo: {bind: $SNAP_DATA/var/lib/foo}}"], + "title": "Layout" + }, + "grade": { + "const": "devel", + "title": "Grade", + "type": "string" + }, + "assumes": { + "description": "The minimum version of snapd and its features that the snap requires from the host.", + "examples": ["[snapd2.66, common-data-dir]"], + "items": { + "type": "string" + }, + "title": "Assumes", + "type": "array", + "uniqueItems": true + }, + "hooks": { + "anyOf": [ + { + "additionalProperties": { + "$ref": "#/$defs/Hook" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Configures the snap's hooks.", + "examples": ["{configure: {plugs: [home]}}"], + "title": "Hooks" + }, + "passthrough": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The attributes to pass to the snap's metadata file.", + "examples": ["{daemon: complex}"], + "title": "Passthrough" + }, + "apps": { + "anyOf": [ + { + "additionalProperties": { + "$ref": "#/$defs/App" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The individual programs and services that the snap runs.", + "examples": ["{app-1: {command: bin/app-1}}"], + "title": "Apps" + }, + "plugs": { + "anyOf": [ + { + "additionalProperties": { + "anyOf": [ + { + "$ref": "#/$defs/ContentPlug" + }, + {} + ] + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Declares the snap's plugs.", + "examples": ["{dot-gitconfig: {interface: personal-files, read: [$HOME/.gitconfig]}}"], + "title": "Plugs" + }, + "slots": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Declares the snap's slots.", + "examples": ["{slot-1: {interface: content, content: my-binaries, source: {read: [$SNAP/bin]}}}"], + "title": "Slots" + }, + "lint": { + "anyOf": [ + { + "$ref": "#/$defs/Lint" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The linter configuration settings.", + "examples": ["{ignore: [classic, library: [usr/lib/**/libfoo.so*]]}"] + }, + "epoch": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The epoch associated with this version of the snap.", + "examples": ["1", "2*"], + "title": "Epoch" + }, + "system-usernames": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The system usernames the snap can use to run daemons and services.", + "examples": ["{snap-daemon: shared}"], + "title": "System-Usernames" + }, + "environment": { + "anyOf": [ + { + "additionalProperties": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ] + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The snap's runtime environment variables.", + "examples": ["{PYTHONPATH: $SNAP/usr/lib/python3/dist-packages:$PYTHON_PATH, DISABLE_WAYLAND: 1}"], + "title": "Environment" + }, + "build-packages": { + "anyOf": [ + {}, + { + "type": "null" + } + ], + "default": null, + "description": "The list of packages to install when building a snap.", + "examples": ["[libssl-dev, libyaml-dev]"], + "title": "Build-Packages" + }, + "build-snaps": { + "anyOf": [ + {}, + { + "type": "null" + } + ], + "default": null, + "description": "The snaps to install when building a snap.", + "examples": ["[go/1.22/stable, yq]"], + "title": "Build-Snaps" + }, + "ua-services": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The Ubuntu Pro (formerly Ubuntu Advantage) services to enable when building the snap.", + "examples": ["[esm-apps]"], + "title": "Ua-Services" + }, + "provenance": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The primary-key header for snaps signed by third parties.", + "examples": ["test-provenance"], + "title": "Provenance" + }, + "components": { + "anyOf": [ + { + "additionalProperties": { + "$ref": "#/$defs/Component" + }, + "propertyNames": { + "maxLength": 40 + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Declares the components to build in conjunction with the snap.", + "examples": ["{foo-component: {type: standard}}"], + "title": "Components" + } + }, + "required": ["name", "base", "build-base", "parts", "confinement", "grade"], + "title": "DevelBaseProject", + "type": "object" + }, + "Hook": { + "additionalProperties": false, + "description": "Snapcraft project hook definition.", + "properties": { + "command-chain": { + "description": "The ordered list of commands to run before the hook runs.", + "examples": ["[bin/alsa-launch, bin/desktop-launch]"], + "items": { + "type": "string" + }, + "title": "Command-Chain", + "type": "array" + }, + "environment": { + "anyOf": [ + { + "additionalProperties": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ] + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The environment variables for the hook.", + "examples": ["{PYTHONPATH: /custom/path/:$PYTHON_PATH, DISABLE_WAYLAND: 1}"], + "title": "Environment" + }, + "plugs": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The list of interfaces that the hook can connect to.", + "examples": ["[home, removable-media]"], + "title": "Plugs" + }, + "passthrough": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The attributes to pass to the snap's metadata file for the hook.", + "examples": ["{daemon: complex}"], + "title": "Passthrough" + } + }, + "title": "Hook", + "type": "object" + }, + "Lint": { + "additionalProperties": false, + "description": "Linter configuration.\n\n:ivar ignore: A list describing which files should have issues ignored for given linters.\n The items in the list can be either:\n - a string, which must be the name of one of the known linters (see below). All issues\n from this linter will be ignored.\n - a dict containing exactly one key, which must be the name of one of the known linters.\n The value is then a list of strings corresponding to the filenames/patterns that\n should be ignored for that linter.\n The \"known\" linter names are the keys in :ref:`LINTERS`", + "properties": { + "ignore": { + "description": "Linters or files to skip when linting.", + "examples": ["{ignore: [classic, library: [usr/lib/**/libfoo.so*]]}"], + "items": { + "anyOf": [ + { + "type": "string" + }, + { + "additionalProperties": { + "items": { + "type": "string" + }, + "type": "array" + }, + "type": "object" + } + ] + }, + "title": "Ignore", + "type": "array" + } + }, + "required": ["ignore"], + "title": "Lint", + "type": "object" + }, + "Platform": { + "additionalProperties": false, + "description": "Snapcraft project platform definition.", + "properties": { + "build-on": { + "anyOf": [ + { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + } + ], + "minLength": 1 + }, + { + "type": "null" + } + ], + "description": "The architectures to build the snap on.", + "examples": ["arm64", "[amd64, riscv64]"], + "title": "Build-On" + }, + "build-for": { + "anyOf": [ + { + "items": {}, + "maxItems": 1, + "minItems": 1, + "type": "array" + }, + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The target architecture for the build.", + "examples": ["amd64", "[riscv64]"], + "title": "Build-For" + } + }, + "required": ["build-on"], + "title": "Platform", + "type": "object" + }, + "Socket": { + "additionalProperties": false, + "description": "Snapcraft app socket definition.", + "properties": { + "listen-stream": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "description": "The socket's abstract name or socket path.", + "examples": ["$SNAP_COMMON/lxd/unix.socket", "80"], + "title": "Listen-Stream" + }, + "socket-mode": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The mode or permissions of the socket in octal.", + "examples": ["0660"], + "title": "Socket-Mode" + } + }, + "required": ["listen-stream"], + "title": "Socket", + "type": "object" + }, + "_BaselessCore22Project": { + "additionalProperties": false, + "properties": { + "name": { + "description": "The identifying name of the snap.", + "examples": ["my-app", "powershell", "jupyterlab-desktop"], + "maxLength": 40, + "title": "Name", + "type": "string" + }, + "title": { + "anyOf": [ + { + "description": "A human-readable title.", + "examples": ["Ubuntu Linux", "Jupyter Lab Desktop", "LXD", "DigiKam", "Apache Kafka", "MySQL Router K8s charm"], + "maxLength": 40, + "minLength": 2, + "title": "Title", + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "title": "Title" + }, + "version": { + "anyOf": [ + { + "description": "The version of the project, enclosed in quotation marks.", + "examples": ["\"0.1\"", "\"1.0.0\"", "\"v1.0.0\"", "\"24.04\""], + "maxLength": 32, + "title": "version string", + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The version of the snap.", + "examples": ["1.2.3"], + "title": "Version" + }, + "summary": { + "anyOf": [ + { + "description": "A short description of the project. Maximum length 78 characters.", + "examples": ["Linux for Human Beings", "The cross-platform desktop application for JupyterLab", "Container and VM manager", "Photo Management Program", "Charm for routing MySQL databases in Kubernetes", "An open-source event streaming platform for high-performance data pipelines"], + "maxLength": 78, + "title": "Summary", + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "title": "Summary" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The full description of the project.", + "title": "Description" + }, + "build-base": { + "const": "core22", + "description": "The baseline system that the snap is built in.", + "title": "Build-Base", + "type": "string" + }, + "platforms": { + "anyOf": [ + { + "additionalProperties": { + "$ref": "#/$defs/Platform" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The architectures that the snap builds and runs on.", + "examples": ["{amd64: {build-on: [amd64], build-for: [amd64]}, arm64: {build-on: [amd64, arm64], build-for: [arm64]}}"], + "title": "Platforms" + }, + "contact": { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The snap author's contact links and email addresses.", + "examples": ["[contact@example.com, https://example.com/contact]"], + "title": "Contact" + }, + "issues": { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The links and email addresses for submitting issues, bugs, and feature requests.", + "examples": ["[issues@email.com, https://example.com/issues]"], + "title": "Issues" + }, + "source-code": { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The links to the source code of the snap or the original project.", + "examples": ["[https://example.com/source-code]"], + "title": "Source-Code" + }, + "license": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The project's license as an SPDX expression", + "examples": ["GPL-3.0+", "Apache-2.0"], + "title": "License" + }, + "adopt-info": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Selects a part to inherit metadata from and reuse for the snap's metadata.\n\nRequired if one of ``version``, ``summary``, or ``description`` isn't set.", + "examples": ["foo-part"], + "title": "Adopt-Info" + }, + "parts": { + "additionalProperties": { + "additionalProperties": true, + "type": "object" + }, + "description": "The self-contained software pieces needed to create the final artifact.", + "examples": ["{cloud-init: {plugin: python, source-type: git, source: https://git.launchpad.net/cloud-init}}"], + "title": "Parts", + "type": "object" + }, + "package-repositories": { + "anyOf": [ + { + "items": { + "additionalProperties": true, + "type": "object" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The package repositories to use for build and stage packages.", + "examples": ["[{type: apt, components: [main], suites: [xenial], key-id: 78E1918602959B9C59103100F1831DDAFC42E99D, url: http://ppa.launchpad.net/snappy-dev/snapcraft-daily/ubuntu}]"], + "title": "Package-Repositories" + }, + "compression": { + "default": "xz", + "description": "Specifies the algorithm that compresses the snap.", + "enum": ["lzo", "xz"], + "examples": ["xz", "lzo"], + "title": "Compression", + "type": "string" + }, + "donation": { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The snap's donation links.", + "examples": ["[donate@example.com, https://example.com/donate]"], + "title": "Donation" + }, + "website": { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The links to the original software's web pages.", + "examples": ["[https://example.com]"], + "title": "Website" + }, + "type": { + "enum": ["base", "kernel", "snapd"], + "title": "Type", + "type": "string" + }, + "icon": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The path to the snap's icon.", + "examples": ["snap/gui/icon.svg"], + "title": "Icon" + }, + "confinement": { + "description": "The amount of isolation the snap has from the host system.", + "enum": ["classic", "devmode", "strict"], + "examples": ["strict", "classic", "devmode"], + "title": "Confinement", + "type": "string" + }, + "layout": { + "anyOf": [ + { + "additionalProperties": { + "additionalProperties": { + "type": "string" + }, + "maxProperties": 1, + "minProperties": 1, + "propertyNames": { + "enum": ["symlink", "bind", "bind-file", "type"] + }, + "type": "object" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The file layouts in the execution environment.", + "examples": ["{/var/lib/foo: {bind: $SNAP_DATA/var/lib/foo}}"], + "title": "Layout" + }, + "grade": { + "anyOf": [ + { + "enum": ["stable", "devel"], + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The quality grade of the snap.", + "examples": ["stable", "devel"], + "title": "Grade" + }, + "architectures": { + "anyOf": [ + { + "items": { + "anyOf": [ + { + "type": "string" + }, + { + "$ref": "#/$defs/Architecture" + } + ] + }, + "type": "array" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The architectures that the snap builds and runs on.", + "examples": ["[amd64, riscv64]", "[{build-on: [amd64], build-for: [amd64]}]", "[{build-on: [amd64, riscv64], build-for: [riscv64]}]"], + "title": "Architectures" + }, + "assumes": { + "description": "The minimum version of snapd and its features that the snap requires from the host.", + "examples": ["[snapd2.66, common-data-dir]"], + "items": { + "type": "string" + }, + "title": "Assumes", + "type": "array", + "uniqueItems": true + }, + "hooks": { + "anyOf": [ + { + "additionalProperties": { + "$ref": "#/$defs/Hook" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Configures the snap's hooks.", + "examples": ["{configure: {plugs: [home]}}"], + "title": "Hooks" + }, + "passthrough": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The attributes to pass to the snap's metadata file.", + "examples": ["{daemon: complex}"], + "title": "Passthrough" + }, + "apps": { + "anyOf": [ + { + "additionalProperties": { + "$ref": "#/$defs/App" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The individual programs and services that the snap runs.", + "examples": ["{app-1: {command: bin/app-1}}"], + "title": "Apps" + }, + "plugs": { + "anyOf": [ + { + "additionalProperties": { + "anyOf": [ + { + "$ref": "#/$defs/ContentPlug" + }, + {} + ] + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Declares the snap's plugs.", + "examples": ["{dot-gitconfig: {interface: personal-files, read: [$HOME/.gitconfig]}}"], + "title": "Plugs" + }, + "slots": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Declares the snap's slots.", + "examples": ["{slot-1: {interface: content, content: my-binaries, source: {read: [$SNAP/bin]}}}"], + "title": "Slots" + }, + "lint": { + "anyOf": [ + { + "$ref": "#/$defs/Lint" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The linter configuration settings.", + "examples": ["{ignore: [classic, library: [usr/lib/**/libfoo.so*]]}"] + }, + "epoch": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The epoch associated with this version of the snap.", + "examples": ["1", "2*"], + "title": "Epoch" + }, + "system-usernames": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The system usernames the snap can use to run daemons and services.", + "examples": ["{snap-daemon: shared}"], + "title": "System-Usernames" + }, + "environment": { + "anyOf": [ + { + "additionalProperties": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ] + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The snap's runtime environment variables.", + "examples": ["{PYTHONPATH: $SNAP/usr/lib/python3/dist-packages:$PYTHON_PATH, DISABLE_WAYLAND: 1}"], + "title": "Environment" + }, + "build-packages": { + "anyOf": [ + {}, + { + "type": "null" + } + ], + "default": null, + "description": "The list of packages to install when building a snap.", + "examples": ["[libssl-dev, libyaml-dev]"], + "title": "Build-Packages" + }, + "build-snaps": { + "anyOf": [ + {}, + { + "type": "null" + } + ], + "default": null, + "description": "The snaps to install when building a snap.", + "examples": ["[go/1.22/stable, yq]"], + "title": "Build-Snaps" + }, + "ua-services": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The Ubuntu Pro (formerly Ubuntu Advantage) services to enable when building the snap.", + "examples": ["[esm-apps]"], + "title": "Ua-Services" + }, + "provenance": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The primary-key header for snaps signed by third parties.", + "examples": ["test-provenance"], + "title": "Provenance" + }, + "components": { + "anyOf": [ + { + "additionalProperties": { + "$ref": "#/$defs/Component" + }, + "propertyNames": { + "maxLength": 40 + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Declares the components to build in conjunction with the snap.", + "examples": ["{foo-component: {type: standard}}"], + "title": "Components" + } + }, + "required": ["name", "build-base", "parts", "type", "confinement"], + "title": "_BaselessCore22Project", + "type": "object" + }, + "_BaselessProject": { + "additionalProperties": false, + "description": "Project types that do not require a base.", + "properties": { + "name": { + "description": "The identifying name of the snap.", + "examples": ["my-app", "powershell", "jupyterlab-desktop"], + "maxLength": 40, + "title": "Name", + "type": "string" + }, + "title": { + "anyOf": [ + { + "description": "A human-readable title.", + "examples": ["Ubuntu Linux", "Jupyter Lab Desktop", "LXD", "DigiKam", "Apache Kafka", "MySQL Router K8s charm"], + "maxLength": 40, + "minLength": 2, + "title": "Title", + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "title": "Title" + }, + "version": { + "anyOf": [ + { + "description": "The version of the project, enclosed in quotation marks.", + "examples": ["\"0.1\"", "\"1.0.0\"", "\"v1.0.0\"", "\"24.04\""], + "maxLength": 32, + "title": "version string", + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The version of the snap.", + "examples": ["1.2.3"], + "title": "Version" + }, + "summary": { + "anyOf": [ + { + "description": "A short description of the project. Maximum length 78 characters.", + "examples": ["Linux for Human Beings", "The cross-platform desktop application for JupyterLab", "Container and VM manager", "Photo Management Program", "Charm for routing MySQL databases in Kubernetes", "An open-source event streaming platform for high-performance data pipelines"], + "maxLength": 78, + "title": "Summary", + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "title": "Summary" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The full description of the project.", + "title": "Description" + }, + "build-base": { + "description": "The baseline system that the snap is built in.", + "enum": ["core24", "core26", "devel"], + "title": "Build-Base", + "type": "string" + }, + "platforms": { + "anyOf": [ + { + "additionalProperties": { + "$ref": "#/$defs/Platform" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The architectures that the snap builds and runs on.", + "examples": ["{amd64: {build-on: [amd64], build-for: [amd64]}, arm64: {build-on: [amd64, arm64], build-for: [arm64]}}"], + "title": "Platforms" + }, + "contact": { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The snap author's contact links and email addresses.", + "examples": ["[contact@example.com, https://example.com/contact]"], + "title": "Contact" + }, + "issues": { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The links and email addresses for submitting issues, bugs, and feature requests.", + "examples": ["[issues@email.com, https://example.com/issues]"], + "title": "Issues" + }, + "source-code": { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The links to the source code of the snap or the original project.", + "examples": ["[https://example.com/source-code]"], + "title": "Source-Code" + }, + "license": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The project's license as an SPDX expression", + "examples": ["GPL-3.0+", "Apache-2.0"], + "title": "License" + }, + "adopt-info": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Selects a part to inherit metadata from and reuse for the snap's metadata.\n\nRequired if one of ``version``, ``summary``, or ``description`` isn't set.", + "examples": ["foo-part"], + "title": "Adopt-Info" + }, + "parts": { + "additionalProperties": { + "additionalProperties": true, + "type": "object" + }, + "description": "The self-contained software pieces needed to create the final artifact.", + "examples": ["{cloud-init: {plugin: python, source-type: git, source: https://git.launchpad.net/cloud-init}}"], + "title": "Parts", + "type": "object" + }, + "package-repositories": { + "anyOf": [ + { + "items": { + "additionalProperties": true, + "type": "object" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The package repositories to use for build and stage packages.", + "examples": ["[{type: apt, components: [main], suites: [xenial], key-id: 78E1918602959B9C59103100F1831DDAFC42E99D, url: http://ppa.launchpad.net/snappy-dev/snapcraft-daily/ubuntu}]"], + "title": "Package-Repositories" + }, + "compression": { + "default": "xz", + "description": "Specifies the algorithm that compresses the snap.", + "enum": ["lzo", "xz"], + "examples": ["xz", "lzo"], + "title": "Compression", + "type": "string" + }, + "donation": { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The snap's donation links.", + "examples": ["[donate@example.com, https://example.com/donate]"], + "title": "Donation" + }, + "website": { + "anyOf": [ + { + "type": "string" + }, + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true + }, + { + "type": "null" + } + ], + "default": null, + "description": "The links to the original software's web pages.", + "examples": ["[https://example.com]"], + "title": "Website" + }, + "type": { + "enum": ["base", "kernel", "snapd"], + "title": "Type", + "type": "string" + }, + "icon": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The path to the snap's icon.", + "examples": ["snap/gui/icon.svg"], + "title": "Icon" + }, + "confinement": { + "description": "The amount of isolation the snap has from the host system.", + "enum": ["classic", "devmode", "strict"], + "examples": ["strict", "classic", "devmode"], + "title": "Confinement", + "type": "string" + }, + "layout": { + "anyOf": [ + { + "additionalProperties": { + "additionalProperties": { + "type": "string" + }, + "maxProperties": 1, + "minProperties": 1, + "propertyNames": { + "enum": ["symlink", "bind", "bind-file", "type"] + }, + "type": "object" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The file layouts in the execution environment.", + "examples": ["{/var/lib/foo: {bind: $SNAP_DATA/var/lib/foo}}"], + "title": "Layout" + }, + "grade": { + "anyOf": [ + { + "enum": ["stable", "devel"], + "type": "string" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The quality grade of the snap.", + "examples": ["stable", "devel"], + "title": "Grade" + }, + "architectures": { + "anyOf": [ + { + "items": { + "anyOf": [ + { + "type": "string" + }, + { + "$ref": "#/$defs/Architecture" + } + ] + }, + "type": "array" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The architectures that the snap builds and runs on.", + "examples": ["[amd64, riscv64]", "[{build-on: [amd64], build-for: [amd64]}]", "[{build-on: [amd64, riscv64], build-for: [riscv64]}]"], + "title": "Architectures" + }, + "assumes": { + "description": "The minimum version of snapd and its features that the snap requires from the host.", + "examples": ["[snapd2.66, common-data-dir]"], + "items": { + "type": "string" + }, + "title": "Assumes", + "type": "array", + "uniqueItems": true + }, + "hooks": { + "anyOf": [ + { + "additionalProperties": { + "$ref": "#/$defs/Hook" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Configures the snap's hooks.", + "examples": ["{configure: {plugs: [home]}}"], + "title": "Hooks" + }, + "passthrough": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The attributes to pass to the snap's metadata file.", + "examples": ["{daemon: complex}"], + "title": "Passthrough" + }, + "apps": { + "anyOf": [ + { + "additionalProperties": { + "$ref": "#/$defs/App" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The individual programs and services that the snap runs.", + "examples": ["{app-1: {command: bin/app-1}}"], + "title": "Apps" + }, + "plugs": { + "anyOf": [ + { + "additionalProperties": { + "anyOf": [ + { + "$ref": "#/$defs/ContentPlug" + }, + {} + ] + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "Declares the snap's plugs.", + "examples": ["{dot-gitconfig: {interface: personal-files, read: [$HOME/.gitconfig]}}"], "title": "Plugs" }, - "passthrough": { + "slots": { "anyOf": [ { "additionalProperties": true, @@ -4821,138 +6595,194 @@ } ], "default": null, - "description": "The attributes to pass to the snap's metadata file for the hook.", - "examples": ["{daemon: complex}"], - "title": "Passthrough" - } - }, - "title": "Hook", - "type": "object" - }, - "Lint": { - "additionalProperties": false, - "description": "Linter configuration.\n\n:ivar ignore: A list describing which files should have issues ignored for given linters.\n The items in the list can be either:\n - a string, which must be the name of one of the known linters (see below). All issues\n from this linter will be ignored.\n - a dict containing exactly one key, which must be the name of one of the known linters.\n The value is then a list of strings corresponding to the filenames/patterns that\n should be ignored for that linter.\n The \"known\" linter names are the keys in :ref:`LINTERS`", - "properties": { - "ignore": { - "description": "Linters or files to skip when linting.", - "examples": ["{ignore: [classic, library: [usr/lib/**/libfoo.so*]]}"], - "items": { - "anyOf": [ - { - "type": "string" - }, - { - "additionalProperties": { - "items": { - "type": "string" - }, - "type": "array" - }, - "type": "object" - } - ] - }, - "title": "Ignore", - "type": "array" - } - }, - "required": ["ignore"], - "title": "Lint", - "type": "object" - }, - "Platform": { - "additionalProperties": false, - "description": "Snapcraft project platform definition.", - "properties": { - "build-on": { + "description": "Declares the snap's slots.", + "examples": ["{slot-1: {interface: content, content: my-binaries, source: {read: [$SNAP/bin]}}}"], + "title": "Slots" + }, + "lint": { "anyOf": [ { - "anyOf": [ - { - "type": "string" - }, - { - "items": { - "type": "string" - }, - "type": "array", - "uniqueItems": true - } - ], - "minLength": 1 + "$ref": "#/$defs/Lint" }, { "type": "null" } ], - "description": "The architectures on which the snap can be built.", - "examples": ["[amd64, riscv64]"], - "title": "Build-On" + "default": null, + "description": "The linter configuration settings.", + "examples": ["{ignore: [classic, library: [usr/lib/**/libfoo.so*]]}"] }, - "build-for": { + "epoch": { "anyOf": [ { - "items": {}, - "maxItems": 1, - "minItems": 1, - "type": "array" + "type": "string" }, { - "type": "string" + "type": "null" + } + ], + "default": null, + "description": "The epoch associated with this version of the snap.", + "examples": ["1", "2*"], + "title": "Epoch" + }, + "system-usernames": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" }, { "type": "null" } ], "default": null, - "description": "The single element list containing the architecture the snap is built for.", - "examples": ["[amd64]", "[riscv64]"], - "title": "Build-For" - } - }, - "required": ["build-on"], - "title": "Platform", - "type": "object" - }, - "Socket": { - "additionalProperties": false, - "description": "Snapcraft app socket definition.", - "properties": { - "listen-stream": { + "description": "The system usernames the snap can use to run daemons and services.", + "examples": ["{snap-daemon: shared}"], + "title": "System-Usernames" + }, + "environment": { "anyOf": [ { - "type": "integer" + "additionalProperties": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ] + }, + "type": "object" + }, + { + "type": "null" + } + ], + "default": null, + "description": "The snap's runtime environment variables.", + "examples": ["{PYTHONPATH: $SNAP/usr/lib/python3/dist-packages:$PYTHON_PATH, DISABLE_WAYLAND: 1}"], + "title": "Environment" + }, + "build-packages": { + "anyOf": [ + {}, + { + "type": "null" + } + ], + "default": null, + "description": "The list of packages to install when building a snap.", + "examples": ["[libssl-dev, libyaml-dev]"], + "title": "Build-Packages" + }, + "build-snaps": { + "anyOf": [ + {}, + { + "type": "null" + } + ], + "default": null, + "description": "The snaps to install when building a snap.", + "examples": ["[go/1.22/stable, yq]"], + "title": "Build-Snaps" + }, + "ua-services": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array", + "uniqueItems": true }, + { + "type": "null" + } + ], + "default": null, + "description": "The Ubuntu Pro (formerly Ubuntu Advantage) services to enable when building the snap.", + "examples": ["[esm-apps]"], + "title": "Ua-Services" + }, + "provenance": { + "anyOf": [ { "type": "string" + }, + { + "type": "null" } ], - "description": "The socket's abstract name or socket path.", - "examples": ["$SNAP_COMMON/lxd/unix.socket", "80"], - "title": "Listen-Stream" + "default": null, + "description": "The primary-key header for snaps signed by third parties.", + "examples": ["test-provenance"], + "title": "Provenance" }, - "socket-mode": { + "components": { "anyOf": [ { - "type": "integer" + "additionalProperties": { + "$ref": "#/$defs/Component" + }, + "propertyNames": { + "maxLength": 40 + }, + "type": "object" }, { "type": "null" } ], "default": null, - "description": "The mode or permissions of the socket in octal.", - "examples": ["0660"], - "title": "Socket-Mode" + "description": "Declares the components to build in conjunction with the snap.", + "examples": ["{foo-component: {type: standard}}"], + "title": "Components" } }, - "required": ["listen-stream"], - "title": "Socket", + "required": ["name", "build-base", "parts", "type", "confinement"], + "title": "_BaselessProject", "type": "object" } }, "oneOf": [ { + "discriminator": { + "mapping": { + "bare": { + "discriminator": { + "mapping": { + "core22": "#/$defs/BareCore22Project", + "core24": "#/$defs/BareCore24Project", + "core26": "#/$defs/BareCore26Project", + "devel": "#/$defs/BareDevelProject" + }, + "propertyName": "build-base" + }, + "oneOf": [ + { + "$ref": "#/$defs/BareCore22Project" + }, + { + "$ref": "#/$defs/BareCore24Project" + }, + { + "$ref": "#/$defs/BareCore26Project" + }, + { + "$ref": "#/$defs/BareDevelProject" + } + ] + }, + "core22": "#/$defs/Core22Project", + "core24": "#/$defs/Core24Project", + "core26": "#/$defs/Core26Project", + "devel": "#/$defs/DevelBaseProject" + }, + "propertyName": "base" + }, "oneOf": [ { "$ref": "#/$defs/Core22Project" @@ -4961,27 +6791,54 @@ "$ref": "#/$defs/Core24Project" }, { + "$ref": "#/$defs/Core26Project" + }, + { + "$ref": "#/$defs/DevelBaseProject" + }, + { + "discriminator": { + "mapping": { + "core22": "#/$defs/BareCore22Project", + "core24": "#/$defs/BareCore24Project", + "core26": "#/$defs/BareCore26Project", + "devel": "#/$defs/BareDevelProject" + }, + "propertyName": "build-base" + }, "oneOf": [ { "$ref": "#/$defs/BareCore22Project" }, { "$ref": "#/$defs/BareCore24Project" + }, + { + "$ref": "#/$defs/BareCore26Project" + }, + { + "$ref": "#/$defs/BareDevelProject" } ] } ] }, { + "discriminator": { + "mapping": { + "core22": "#/$defs/_BaselessCore22Project", + "core24": "#/$defs/_BaselessProject", + "core26": "#/$defs/_BaselessProject", + "devel": "#/$defs/_BaselessProject" + }, + "propertyName": "build-base" + }, "oneOf": [ { - "$ref": "#/$defs/BaseDevelProject" - }, - { - "$ref": "#/$defs/BaseCore22Project" + "$ref": "#/$defs/_BaselessCore22Project" }, { - "$ref": "#/$defs/BaseCore24Project" + "$ref": "#/$defs/_BaselessProject" } ] } diff --git a/src/craft_ls/types_.py b/src/craft_ls/types_.py index ce20fac..7a28ba9 100644 --- a/src/craft_ls/types_.py +++ b/src/craft_ls/types_.py @@ -88,10 +88,15 @@ def iter_errors( ) +MISSING_TYPE_MSG = "Missing or unsupported 'base' and/or 'build-base' key(s)." + + class MissingTypeSnapcraftValidator: """No op implementation. - Used if snapcraft.yaml is missing the 'base' or 'build-base' key. + Used if snapcraft.yaml is: + - missing the 'base' or 'build-base' key + - using an unsupported base """ def iter_errors( @@ -101,6 +106,6 @@ def iter_errors( yield ValidationError( validator="required", path=deque([]), - message="Filling 'base' and/or 'build-base' key(s) is mandatory.", + message=MISSING_TYPE_MSG, schema={}, ) diff --git a/tests/test_server.py b/tests/test_server.py index 7467124..efcab94 100644 --- a/tests/test_server.py +++ b/tests/test_server.py @@ -6,6 +6,8 @@ from lsprotocol import types from pytest_lsp import ClientServerConfig, LanguageClient +from craft_ls.types_ import MISSING_TYPE_MSG + @pytest_lsp.fixture( config=ClientServerConfig( @@ -52,4 +54,4 @@ async def test_diagnostic_on_open(client: LanguageClient): # Then assert (diagnostics := client.diagnostics.get(test_uri, [])) - assert any("is mandatory" in diagnostic.message for diagnostic in diagnostics) + assert any(MISSING_TYPE_MSG in diagnostic.message for diagnostic in diagnostics)