{
  // See https://go.microsoft.com/fwlink/?LinkId=733558
  // for the documentation about the tasks.json format
  "version": "2.0.0",
  "tasks": [
    {
      "type": "shell",
      "command": "pnpm tsx ./dev-tools/dev-server/index.ts",
      "group": "build",
      "problemMatcher": [],
      "label": "启动开发服务 dev-server"
    },
    {
      "type": "shell",
      "command": "pnpm webpack --config ./webpack/webpack.dev.ts --progress",
      "group": "build",
      "problemMatcher": [],
      "label": "本体:编译开发版本 dev:build-core"
    },
    {
      "type": "shell",
      "command": "pnpm webpack --watch --config ./webpack/webpack.dev.ts --progress",
      "group": "build",
      "problemMatcher": [],
      "label": "本体:监视开发版本 dev:watch-core"
    },
    {
      "type": "shell",
      "command": "pnpm serve dist -p ${input:serverPort}",
      "group": "build",
      "problemMatcher": [],
      "label": "本体:启动服务器 dev:serve-core"
    },
    {
      "type": "shell",
      "command": "pnpm tsc -p tsconfig.type-check.json --noEmit",
      "group": "build",
      "problemMatcher": [],
      "label": "生产:类型检查 prod:type"
    },
    {
      "type": "shell",
      "command": "pnpm --silent webpack --config ./webpack/webpack.prod.ts --profile --json > dist/profile.json && pnpm webpack-bundle-analyzer dist/profile.json",
      "group": "build",
      "problemMatcher": [],
      "label": "本体:打包分析 prod:analyze"
    },
    {
      "type": "shell",
      "command": "pnpm eslint . --cache --cache-location node_modules/.cache/eslint/ --ext .ts,.vue",
      "group": "build",
      "problemMatcher": [],
      "label": "生产:代码检查 prod:lint"
    },
    {
      "type": "shell",
      "command": "pnpm eslint . --cache --cache-location node_modules/.cache/eslint/ --fix --ext .ts,.vue",
      "group": "build",
      "problemMatcher": [],
      "label": "生产:代码修复 prod:lint-fix"
    },
    {
      "type": "shell",
      "command": "pnpm webpack --config ./webpack/webpack.prod.ts --progress",
      "group": "build",
      "problemMatcher": [],
      "label": "本体:编译生产版本 prod:build-core"
    },
    {
      "type": "shell",
      "command": "pnpm webpack --config ./registry/webpack/components.ts --progress",
      "group": "build",
      "problemMatcher": [],
      "label": "功能:编译组件 prod:build-components"
    },
    {
      "type": "shell",
      "command": "pnpm webpack --config ./registry/webpack/plugins.ts --progress",
      "group": "build",
      "problemMatcher": [],
      "label": "功能:编译插件 prod:build-plugins"
    },
    {
      "type": "shell",
      "command": "pnpm webpack --config ./registry/webpack/all.ts",
      "group": "build",
      "problemMatcher": [],
      "label": "功能:编译所有 prod:build-features"
    },
    {
      "type": "shell",
      "command": "pnpm run build-docs",
      "group": "build",
      "problemMatcher": [],
      "label": "功能:编译功能文档 prod:build-docs"
    },
    {
      "type": "shell",
      "command": "rm -r ./node_modules/.cache/webpack/",
      "label": "缓存:清除 webpack cache:clean-webpack",
      "problemMatcher": []
    },
    {
      "type": "shell",
      "command": "rm -r ./node_modules/.cache/babel-loader/",
      "label": "缓存:清除 babel cache:clean-babel",
      "problemMatcher": []
    },
    {
      "type": "shell",
      "command": "rm -r ./node_modules/.cache/",
      "label": "缓存:清除全部 cache:clear-all",
      "problemMatcher": []
    }
  ],
  "inputs": [
    {
      "id": "serverPort",
      "type": "promptString",
      "description": "监听端口",
      "default": "5000"
    }
  ]
}
