{
  "$comment": "https://www.jetbrains.com/help/qodana/qodana-yaml.html",
  "$id": "https://json.schemastore.org/qodana-1.0.json",
  "$schema": "http://json-schema.org/draft-07/schema#",
  "additionalProperties": true,
  "definitions": {
    "profile": {
      "description": "A profile is some template set of checks to run with Qodana analysis",
      "type": "object",
      "oneOf": [
        {
          "properties": {
            "name": {
              "description": "The profile name (embedded or located in the project)",
              "type": "string"
            }
          },
          "required": ["name"],
          "additionalProperties": false
        },
        {
          "properties": {
            "path": {
              "description": "The path to the profile file relative to the project root",
              "type": "string"
            }
          },
          "required": ["path"],
          "additionalProperties": false
        }
      ],
      "additionalProperties": true
    },
    "include": {
      "description": "The inspections to run in addition to those from the profile",
      "type": "object",
      "properties": {
        "name": {
          "description": "The ID of the inspection to be added",
          "type": "string"
        }
      },
      "required": ["name"],
      "additionalProperties": false
    },
    "exclude": {
      "description": "The inspections or paths to exclude from analysis",
      "type": "object",
      "properties": {
        "name": {
          "description": "The ID of the inspection to exclude, or 'All'",
          "type": "string"
        },
        "paths": {
          "description": "The path in which to disable the inspection, relative to the project root. Omitting the paths disables the inspection everywhere",
          "type": "array",
          "minItems": 0,
          "items": {
            "type": "string"
          }
        }
      },
      "required": ["name"],
      "additionalProperties": false
    },
    "script": {
      "description": "The default running scenario",
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "name": {
          "description": "The name of the script",
          "enum": ["default", "php-migration"]
        },
        "parameters": {
          "description": "The parameters to pass to the script",
          "type": "object",
          "additionalProperties": true
        }
      }
    },
    "licenseRule": {
      "description": "A license rule to apply for license compatibility checks in Qodana",
      "type": "object",
      "properties": {
        "keys": {
          "description": "The list of project license SPDX IDs",
          "type": "array",
          "minItems": 0,
          "items": {
            "type": "string"
          }
        },
        "allowed": {
          "description": "The list of allowed dependency licenses for the project",
          "type": "array",
          "minItems": 0,
          "items": {
            "type": "string"
          }
        },
        "prohibited": {
          "description": "The list of prohibited dependency licenses for the project",
          "type": "array",
          "minItems": 0,
          "items": {
            "type": "string"
          }
        }
      },
      "additionalProperties": false
    },
    "dependencyIgnore": {
      "description": "A dependency to ignore for license checks in Qodana",
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "name": {
          "description": "The name of a dependency to ignore",
          "type": "string"
        }
      }
    },
    "dependencyOverride": {
      "description": "A dependency metadata to override for license checks in Qodana",
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "name": {
          "description": "The dependency name",
          "type": "string"
        },
        "version": {
          "description": "The dependency version",
          "type": "string"
        },
        "url": {
          "description": "The dependency homepage",
          "type": "string"
        },
        "licenses": {
          "description": "The dependency licenses",
          "type": "array",
          "minItems": 0,
          "items": {
            "$ref": "#/definitions/license"
          }
        }
      },
      "required": ["name", "version", "licenses"]
    },
    "customDependency": {
      "description": "A dependency to add to license checks to Qodana",
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "name": {
          "description": "The dependency name",
          "type": "string"
        },
        "version": {
          "description": "The dependency version",
          "type": "string"
        },
        "url": {
          "description": "The dependency homepage",
          "type": "string"
        },
        "licenses": {
          "description": "The dependency licenses",
          "type": "array",
          "minItems": 0,
          "items": {
            "$ref": "#/definitions/license"
          }
        }
      },
      "required": ["name", "version", "licenses"]
    },
    "license": {
      "description": "A license to apply for license compatibility checks in Qodana",
      "type": "object",
      "properties": {
        "key": {
          "description": "The SPDX ID of the license",
          "type": "string"
        },
        "url": {
          "description": "The license homepage",
          "type": "string"
        }
      },
      "additionalProperties": false
    },
    "dotnet": {
      "description": "Configuration for .NET solutions and projects",
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "solution": {
              "description": "The name of a .NET solution inside the Qodana project",
              "type": "string",
              "minLength": 1
            }
          },
          "additionalProperties": false
        },
        {
          "type": "object",
          "properties": {
            "project": {
              "description": "The name of a .NET project inside the Qodana project",
              "type": "string",
              "minLength": 1
            }
          },
          "additionalProperties": false
        },
        {
          "type": "object",
          "properties": {
            "configuration": {
              "description": "The name of a configuration to be used for .NET solution or project",
              "type": "string",
              "minLength": 1
            }
          },
          "additionalProperties": false
        },
        {
          "type": "object",
          "properties": {
            "platform": {
              "description": "The name of a platform to be used for .NET solution or project",
              "type": "string",
              "minLength": 1
            }
          },
          "additionalProperties": false
        }
      ]
    },
    "dot-net": {
      "description": "Configuration for .NET solutions and projects",
      "deprecated": true,
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "solution": {
              "description": "The name of a .NET solution inside the Qodana project",
              "type": "string",
              "minLength": 1
            }
          },
          "additionalProperties": false
        },
        {
          "type": "object",
          "properties": {
            "project": {
              "description": "The name of a .NET project inside the Qodana project",
              "type": "string",
              "minLength": 1
            }
          },
          "additionalProperties": false
        }
      ]
    }
  },
  "description": "A configuration file for Qodana (https://jetbrains.com/qodana), named qodana.yaml or qodana.yml",
  "properties": {
    "version": {
      "description": "The version of the file format",
      "enum": ["1.0"]
    },
    "profile": {
      "description": "The profile configuration for Qodana analysis",
      "$ref": "#/definitions/profile"
    },
    "failThreshold": {
      "description": "The number of problems that causes Qodana to exit with code 255",
      "type": "integer",
      "minimum": 0
    },
    "script": {
      "description": "The run scenario. 'default' by default",
      "$ref": "#/definitions/script"
    },
    "exclude": {
      "description": "The inspections and paths that are excluded from analysis",
      "type": "array",
      "minItems": 0,
      "items": {
        "$ref": "#/definitions/exclude"
      }
    },
    "include": {
      "description": "The inspections and paths that are added to those from the profile",
      "type": "array",
      "minItems": 0,
      "items": {
        "$ref": "#/definitions/include"
      }
    },
    "linter": {
      "description": "The linter (Docker image) to run for Qodana CLI / any CI extensions",
      "type": "string"
    },
    "bootstrap": {
      "type": "string",
      "description": "The command to run inside Docker before the analysis starts"
    },
    "properties": {
      "type": "object",
      "description": "Set JVM properties to be used while running Qodana",
      "additionalProperties": {
        "type": "string"
      }
    },
    "licenseRules": {
      "description": "A list of license rules to apply for license checks",
      "type": "array",
      "minItems": 0,
      "items": {
        "$ref": "#/definitions/licenseRule"
      }
    },
    "dependencyIgnores": {
      "description": "",
      "type": "array",
      "minItems": 0,
      "items": {
        "$ref": "#/definitions/dependencyIgnore"
      }
    },
    "dependencyOverrides": {
      "description": "",
      "type": "array",
      "minItems": 0,
      "items": {
        "$ref": "#/definitions/dependencyOverride"
      }
    },
    "customDependencies": {
      "description": "",
      "type": "array",
      "minItems": 0,
      "items": {
        "$ref": "#/definitions/customDependency"
      }
    },
    "dot-net": {
      "description": "The configuration for .NET solutions and projects",
      "$ref": "#/definitions/dot-net"
    }
  },
  "required": ["version"],
  "title": "Qodana",
  "type": "object"
}