{
  "$schema": "http://json-schema.org/schema",
  "id": "@nx-dotnet/core:app",
  "title": "NxDotnet Application Generator",
  "description": "Generate a dotnet project under the application directory.",
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "The name assigned to the app",
      "$default": {
        "$source": "argv",
        "index": 0
      },
      "x-prompt": "What name would you like to use?"
    },
    "namespaceName": {
      "type": "string",
      "description": "The namespace for the project. If not provided, will be generated based on project name and directory."
    },
    "tags": {
      "type": "string",
      "description": "Add tags to the project (used for linting)",
      "alias": "t"
    },
    "directory": {
      "type": "string",
      "description": "A directory where the project is placed",
      "alias": "d"
    },
    "template": {
      "type": "string",
      "description": "The template to instantiate when the command is invoked. Each template might have specific options you can pass."
    },
    "language": {
      "type": "string",
      "description": "Which language should the project use?",
      "x-prompt": {
        "message": "Which language should the project use?",
        "type": "list",
        "items": ["C#", "F#", "VB"]
      }
    },
    "testTemplate": {
      "type": "string",
      "description": "Which template should be used for creating the tests project?",
      "default": "nunit",
      "enum": ["nunit", "xunit", "mstest", "none"],
      "aliases": ["testRunner"],
      "x-prompt": {
        "message": "Which template should be used for creating the tests project",
        "type": "list",
        "items": [
          {
            "value": "nunit",
            "label": "NUnit 3 Test Project"
          },
          {
            "value": "xunit",
            "label": "xUnit Test Project"
          },
          {
            "value": "mstest",
            "label": "Unit Test Project"
          },
          {
            "value": "none",
            "label": "No Unit Test Project"
          }
        ]
      }
    },
    "solutionFile": {
      "description": "Determines if the project should be added to a solution file.",
      "oneOf": [
        {
          "type": "string",
          "description": "The name of the solution file to add the project to"
        },
        {
          "type": "boolean",
          "description": "Should the project be added to the default solution file?"
        }
      ],
      "aliases": ["solution", "s"]
    },
    "skipSwaggerLib": {
      "type": "boolean",
      "description": "By default, if using webapi template, an additional library is scaffolded for swagger files. This skips that setup."
    },
    "pathScheme": {
      "description": "Determines if the project should follow NX or dotnet path naming conventions",
      "type": "string",
      "default": "nx",
      "enum": ["nx", "dotnet"],
      "x-prompt": {
        "message": "Which path naming conventions should the project use?",
        "type": "list",
        "items": [
          {
            "value": "nx",
            "label": "NX naming conventions"
          },
          {
            "value": "dotnet",
            "label": "Dotnet naming conventions"
          }
        ]
      }
    },
    "useOpenApiGenerator": {
      "type": "boolean",
      "description": "If using a codegen project, use openapi-generator",
      "default": true,
      "aliases": ["useNxPluginOpenAPI"]
    },
    "args": {
      "type": "array",
      "description": "Additional arguments to pass to the dotnet command. For example: \"nx g @nx-dotnet/core:app myapp --args='--no-restore'\" Arguments can also be appended to the end of the command using '--'. For example, 'nx g @nx-dotnet/core:app myapp -- --no-restore'.",
      "items": {
        "type": "string"
      },
      "default": []
    },
    "__unparsed__": {
      "hidden": true,
      "type": "array",
      "items": {
        "type": "string"
      },
      "$default": {
        "$source": "unparsed"
      },
      "x-priority": "internal"
    }
  },
  "additionalProperties": true,
  "required": ["name", "language"]
}
