{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "additionalProperties": {
    "anyOf": [
      {
        "$ref": "#/definitions/fileFormat"
      },
      {
        "$ref": "#/definitions/dynamic"
      }
    ]
  },
  "definitions": {
    "dynamic": {
      "type": "object",
      "required": ["src"],
      "properties": {
        "expand": {
          "description": "Must be set to true to use properties other than 'src' and 'dest'",
          "type": "boolean",
          "default": false
        },
        "cwd": {
          "description": "All 'src' matches are relative to (but don't include) this path",
          "type": "string"
        },
        "dest": {
          "description": "Destination path prefix.",
          "type": "string"
        },
        "ext": {
          "description": "Replace any existing extension with this value in generated 'dest' paths.",
          "type": "string"
        },
        "extDot": {
          "description": "Used to indicate where the period indicating the extension is located.",
          "enum": ["first", "last"],
          "default": "first"
        },
        "filter": {
          "description": "The 'filter' property can help you target files with a greater level of detail",
          "enum": [
            "isFile",
            "isDirectory",
            "isBlockDevice",
            "isCharacterDevice",
            "isSymbolicLink",
            "isFIFO",
            "isSocket"
          ]
        },
        "flatten": {
          "description": "Remove all path parts from generated 'dest' paths",
          "type": "boolean",
          "default": false
        },
        "matchBase": {
          "description": "If set, patterns without slashes will be matched against the basename of the path if it contains slashes. For example, 'a?b' would match the path '/xyz/123/acb', but not '/xyz/acb/123'.",
          "type": "boolean",
          "default": false
        },
        "nonull": {
          "description": "If set to 'true' then the operation will include non-matching patterns. Combined with grunt's '--verbose' flag, this option can help debug file path issues.",
          "type": "boolean",
          "default": false
        },
        "rename": {
          "description": "This function is called for each matched 'src' file, (after extension renaming and flattening). ",
          "type": "string"
        },
        "src": {
          "description": "Pattern(s) to match, relative to the 'cwd'.",
          "type": "array",
          "minItems": 1,
          "uniqueItems": true,
          "items": {
            "type": "string"
          }
        }
      }
    },
    "fileFormat": {
      "properties": {
        "files": {
          "oneOf": [
            {
              "type": "object",
              "additionalProperties": {
                "type": ["array", "string"],
                "uniqueItems": true,
                "minItems": 1,
                "items": {
                  "type": "string"
                }
              }
            },
            {
              "type": "array",
              "items": {
                "$ref": "#/definitions/dynamic"
              }
            }
          ]
        }
      }
    }
  },
  "id": "https://json.schemastore.org/grunt-task",
  "properties": {
    "options": {
      "type": "object"
    }
  },
  "title": "JSON schema for any Grunt task",
  "type": "object"
}
