{
  "$defs": {
    "Digest": {
      "description": "SHA-256 digest of the plugin content, as the OCI manifest digest or the hash of the extracted tree.",
      "pattern": "^sha256:[0-9a-f]{64}(?![\\s\\S])",
      "type": "string"
    },
    "Locked": {
      "additionalProperties": false,
      "description": "One locked plugin.",
      "patternProperties": {
        "^x-": true
      },
      "properties": {
        "digest": {
          "$ref": "#/$defs/Digest"
        },
        "id": {
          "$ref": "common.schema.json#/$defs/PluginId"
        },
        "kind": {
          "description": "`data` for a data plugin, `code` for a code plugin. The same values as the manifest kind.",
          "enum": [
            "data",
            "code"
          ]
        },
        "requires": {
          "description": "Ids of locked plugins this entry needs. At most 256.",
          "items": {
            "$ref": "common.schema.json#/$defs/PackId"
          },
          "maxItems": 256,
          "type": "array",
          "uniqueItems": true
        },
        "signature": {
          "additionalProperties": false,
          "description": "Present when the host verified a minisign signature.",
          "patternProperties": {
            "^x-": true
          },
          "properties": {
            "key_id": {
              "description": "Minisign key id, 16 hex digits.",
              "pattern": "^[0-9A-F]{16}(?![\\s\\S])",
              "type": "string"
            },
            "not_before": {
              "description": "The notBefore time of the signed statement, in UTC (RFC 3339, `Z` suffix). The pattern rejects an impossible month, day, hour, minute or second, and 30 or 31 February. 29 February of a non-leap year passes the schema and fails when the host parses the time. `plugins update` refuses an older value than the lockfile holds unless the user passes the downgrade flag.",
              "format": "date-time",
              "pattern": "^[0-9]{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12][0-9]|3[01])|(?:0[469]|11)-(?:0[1-9]|[12][0-9]|30)|02-(?:0[1-9]|1[0-9]|2[0-9]))T(?:[01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]Z(?![\\s\\S])",
              "type": "string"
            }
          },
          "required": [
            "key_id",
            "not_before"
          ],
          "type": "object"
        },
        "slopvac_api": {
          "$ref": "common.schema.json#/$defs/ApiVersion"
        },
        "source": {
          "description": "An oci:// reference, an https:// release archive URL, a git+https:// URL pinned to a full commit hash after @, or a path relative to the project root. A URL carries no user-info. A path has no colon, no backslash, no `..` segment and no line break, and it starts with a character that is neither white space nor a slash. http:// is rejected. The reader also refuses control characters and other unsafe characters anywhere in the value, and a value over 4096 bytes. The schema counts characters, so it caps the value at 4096 of them.",
          "maxLength": 4096,
          "pattern": "^((oci|https)://(?=[^\\x09-\\x0D\\x1C-\\x20\\x85\\xA0\\u1680\\u2000-\\u200A\\u2028\\u2029\\u202F\\u205F\\u3000\\uFEFF\\x00-\\x1F\\x7F-\\x9F\\xAD\\u034F\\u0600-\\u0605\\u061C\\u06DD\\u070F\\u0890-\\u0891\\u08E2\\u115F-\\u1160\\u17B4-\\u17B5\\u180B-\\u180F\\u200B-\\u200F\\u2028-\\u202E\\u2060-\\u206F\\u3164\\uE000-\\uF8FF\\uFDD0-\\uFDEF\\uFE00-\\uFE0F\\uFEFF\\uFFA0\\uFFF0-\\uFFFB\\uFFFE-\\uFFFF𑂽𑃍𓐰-𓐿𛲠-𛲣𝅳-𝅺🿾-🿿𯿾-𯿿𿿾-𿿿񏿾-񏿿񟿾-񟿿񯿾-񯿿񿿾-񿿿򏿾-򏿿򟿾-򟿿򯿾-򯿿򿿾-򿿿󏿾-󏿿󟿾-󠿿󯿾-􏿿@])[^\\x09-\\x0D\\x1C-\\x20\\x85\\xA0\\u1680\\u2000-\\u200A\\u2028\\u2029\\u202F\\u205F\\u3000\\uFEFF\\x00-\\x1F\\x7F-\\x9F\\xAD\\u034F\\u0600-\\u0605\\u061C\\u06DD\\u070F\\u0890-\\u0891\\u08E2\\u115F-\\u1160\\u17B4-\\u17B5\\u180B-\\u180F\\u200B-\\u200F\\u2028-\\u202E\\u2060-\\u206F\\u3164\\uE000-\\uF8FF\\uFDD0-\\uFDEF\\uFE00-\\uFE0F\\uFEFF\\uFFA0\\uFFF0-\\uFFFB\\uFFFE-\\uFFFF𑂽𑃍𓐰-𓐿𛲠-𛲣𝅳-𝅺🿾-🿿𯿾-𯿿𿿾-𿿿񏿾-񏿿񟿾-񟿿񯿾-񯿿񿿾-񿿿򏿾-򏿿򟿾-򟿿򯿾-򯿿򿿾-򿿿󏿾-󏿿󟿾-󠿿󯿾-􏿿/?#@]*([/?#][^\\x09-\\x0D\\x1C-\\x20\\x85\\xA0\\u1680\\u2000-\\u200A\\u2028\\u2029\\u202F\\u205F\\u3000\\uFEFF\\x00-\\x1F\\x7F-\\x9F\\xAD\\u034F\\u0600-\\u0605\\u061C\\u06DD\\u070F\\u0890-\\u0891\\u08E2\\u115F-\\u1160\\u17B4-\\u17B5\\u180B-\\u180F\\u200B-\\u200F\\u2028-\\u202E\\u2060-\\u206F\\u3164\\uE000-\\uF8FF\\uFDD0-\\uFDEF\\uFE00-\\uFE0F\\uFEFF\\uFFA0\\uFFF0-\\uFFFB\\uFFFE-\\uFFFF𑂽𑃍𓐰-𓐿𛲠-𛲣𝅳-𝅺🿾-🿿𯿾-𯿿𿿾-𿿿񏿾-񏿿񟿾-񟿿񯿾-񯿿񿿾-񿿿򏿾-򏿿򟿾-򟿿򯿾-򯿿򿿾-򿿿󏿾-󏿿󟿾-󠿿󯿾-􏿿]*)?|git\\+https://(?=[^\\x09-\\x0D\\x1C-\\x20\\x85\\xA0\\u1680\\u2000-\\u200A\\u2028\\u2029\\u202F\\u205F\\u3000\\uFEFF\\x00-\\x1F\\x7F-\\x9F\\xAD\\u034F\\u0600-\\u0605\\u061C\\u06DD\\u070F\\u0890-\\u0891\\u08E2\\u115F-\\u1160\\u17B4-\\u17B5\\u180B-\\u180F\\u200B-\\u200F\\u2028-\\u202E\\u2060-\\u206F\\u3164\\uE000-\\uF8FF\\uFDD0-\\uFDEF\\uFE00-\\uFE0F\\uFEFF\\uFFA0\\uFFF0-\\uFFFB\\uFFFE-\\uFFFF𑂽𑃍𓐰-𓐿𛲠-𛲣𝅳-𝅺🿾-🿿𯿾-𯿿𿿾-𿿿񏿾-񏿿񟿾-񟿿񯿾-񯿿񿿾-񿿿򏿾-򏿿򟿾-򟿿򯿾-򯿿򿿾-򿿿󏿾-󏿿󟿾-󠿿󯿾-􏿿@])[^\\x09-\\x0D\\x1C-\\x20\\x85\\xA0\\u1680\\u2000-\\u200A\\u2028\\u2029\\u202F\\u205F\\u3000\\uFEFF\\x00-\\x1F\\x7F-\\x9F\\xAD\\u034F\\u0600-\\u0605\\u061C\\u06DD\\u070F\\u0890-\\u0891\\u08E2\\u115F-\\u1160\\u17B4-\\u17B5\\u180B-\\u180F\\u200B-\\u200F\\u2028-\\u202E\\u2060-\\u206F\\u3164\\uE000-\\uF8FF\\uFDD0-\\uFDEF\\uFE00-\\uFE0F\\uFEFF\\uFFA0\\uFFF0-\\uFFFB\\uFFFE-\\uFFFF𑂽𑃍𓐰-𓐿𛲠-𛲣𝅳-𝅺🿾-🿿𯿾-𯿿𿿾-𿿿񏿾-񏿿񟿾-񟿿񯿾-񯿿񿿾-񿿿򏿾-򏿿򟿾-򟿿򯿾-򯿿򿿾-򿿿󏿾-󏿿󟿾-󠿿󯿾-􏿿/?#@]*([/?#][^\\x09-\\x0D\\x1C-\\x20\\x85\\xA0\\u1680\\u2000-\\u200A\\u2028\\u2029\\u202F\\u205F\\u3000\\uFEFF\\x00-\\x1F\\x7F-\\x9F\\xAD\\u034F\\u0600-\\u0605\\u061C\\u06DD\\u070F\\u0890-\\u0891\\u08E2\\u115F-\\u1160\\u17B4-\\u17B5\\u180B-\\u180F\\u200B-\\u200F\\u2028-\\u202E\\u2060-\\u206F\\u3164\\uE000-\\uF8FF\\uFDD0-\\uFDEF\\uFE00-\\uFE0F\\uFEFF\\uFFA0\\uFFF0-\\uFFFB\\uFFFE-\\uFFFF𑂽𑃍𓐰-𓐿𛲠-𛲣𝅳-𝅺🿾-🿿𯿾-𯿿𿿾-𿿿񏿾-񏿿񟿾-񟿿񯿾-񯿿񿿾-񿿿򏿾-򏿿򟿾-򟿿򯿾-򯿿򿿾-򿿿󏿾-󏿿󟿾-󠿿󯿾-􏿿]*)?@[0-9a-f]{40}|(?=[^\\x09-\\x0D\\x1C-\\x20\\x85\\xA0\\u1680\\u2000-\\u200A\\u2028\\u2029\\u202F\\u205F\\u3000\\uFEFF/\\\\:])(?!([^/]*/)*\\.\\.(/|(?![\\s\\S])))[^\\\\:\\x00-\\x1F\\x7F-\\x9F\\xAD\\u034F\\u0600-\\u0605\\u061C\\u06DD\\u070F\\u0890-\\u0891\\u08E2\\u115F-\\u1160\\u17B4-\\u17B5\\u180B-\\u180F\\u200B-\\u200F\\u2028-\\u202E\\u2060-\\u206F\\u3164\\uE000-\\uF8FF\\uFDD0-\\uFDEF\\uFE00-\\uFE0F\\uFEFF\\uFFA0\\uFFF0-\\uFFFB\\uFFFE-\\uFFFF𑂽𑃍𓐰-𓐿𛲠-𛲣𝅳-𝅺🿾-🿿𯿾-𯿿𿿾-𿿿񏿾-񏿿񟿾-񟿿񯿾-񯿿񿿾-񿿿򏿾-򏿿򟿾-򟿿򯿾-򯿿򿿾-򿿿󏿾-󏿿󟿾-󠿿󯿾-􏿿]*)(?![\\s\\S])",
          "type": "string"
        },
        "version": {
          "$ref": "common.schema.json#/$defs/Semver"
        }
      },
      "required": [
        "id",
        "kind",
        "version",
        "slopvac_api",
        "source",
        "digest"
      ],
      "type": "object"
    }
  },
  "$id": "https://slopvac.github.io/slopvac/schemas/v3/plugins-lock.schema.json",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "additionalProperties": false,
  "description": "The .slopvac/plugins.lock file. `slopvac plugins sync` writes it and a run reads it. It pins each data plugin and code plugin to a version, a source and a content digest, so a run on another machine loads the same bytes. A digest mismatch makes the run fail with exit 2. The lockfile records no trust: trust is a separate per-user record. The built-in core plugin is compiled into the binary and never appears here. Semantics are specified in docs/contract/plugins.md. The reader also refuses a file over 1 MiB, and an id, a dependency id or a version over 4096 bytes.",
  "patternProperties": {
    "^x-": true
  },
  "properties": {
    "plugins": {
      "description": "Locked entries, sorted by id, so diffs stay small. At most 1000 entries.",
      "items": {
        "$ref": "#/$defs/Locked"
      },
      "maxItems": 1000,
      "type": "array"
    },
    "schema_version": {
      "$ref": "common.schema.json#/$defs/SchemaVersion"
    }
  },
  "required": [
    "schema_version",
    "plugins"
  ],
  "title": "slopvac v3 plugins lockfile",
  "type": "object"
}
