]> git.lizzy.rs Git - rust.git/blobdiff - .vscode/tasks.json
Rollup merge of #104211 - lnicola:rust-analyzer-2022-11-09, r=lnicola
[rust.git] / .vscode / tasks.json
index d64e28717f0d7eaed820ffbcb89d92fe6bf6fd8f..a25dff19e4155d6081665ae3636d609b6bc80863 100644 (file)
@@ -4,57 +4,64 @@
   "version": "2.0.0",
   "tasks": [
     {
+      "label": "Build Extension in Background",
+      "group": "build",
       "type": "npm",
-      "script": "compile",
+      "script": "watch",
+      "path": "editors/code/",
+      "problemMatcher": {
+        "base": "$tsc-watch",
+        "fileLocation": ["relative", "${workspaceFolder}/editors/code/"]
+      },
+      "isBackground": true,
+    },
+    {
       "label": "Build Extension",
+      "group": "build",
+      "type": "npm",
+      "script": "build",
+      "path": "editors/code/",
       "problemMatcher": {
-        "owner": "typescript",
-        "pattern": "$tsc",
-        "fileLocation": [
-          "relative",
-          "${workspaceRoot}/editors/code"
-        ]
+        "base": "$tsc",
+        "fileLocation": ["relative", "${workspaceFolder}/editors/code/"]
       },
-      "path": "editors/code/"
     },
     {
-      "label": "Build Lsp",
+      "label": "Build Server",
+      "group": "build",
       "type": "shell",
-      "command": "cargo check",
+      "command": "cargo build --package rust-analyzer",
       "problemMatcher": "$rustc"
     },
     {
-      "label": "Build All",
+      "label": "Build Server (Release)",
       "group": "build",
-      "dependsOn": [
-        "Build Extension",
-        "Build Lsp"
-      ],
-      "problemMatcher": []
+      "type": "shell",
+      "command": "cargo build --release --package rust-analyzer",
+      "problemMatcher": "$rustc"
     },
     {
-      "label": "cargo watch",
+      "label": "Pretest",
       "group": "build",
-      "isBackground": true,
-      "type": "shell",
-      "command": "cargo",
-      "args": [
-        "watch"
-      ],
-      "problemMatcher": "$rustc-watch"
+      "isBackground": false,
+      "type": "npm",
+      "script": "pretest",
+      "path": "editors/code/",
+      "problemMatcher": {
+        "base": "$tsc",
+        "fileLocation": ["relative", "${workspaceFolder}/editors/code/"]
+      }
     },
+
     {
-      "label": "cargo watch tests",
-      "group": "build",
-      "isBackground": true,
-      "type": "shell",
-      "command": "cargo",
-      "args": [
-        "watch",
-        "-x",
-        "check --tests"
-      ],
-      "problemMatcher": "$rustc-watch"
+      "label": "Build Server and Extension",
+      "dependsOn": ["Build Server", "Build Extension"],
+      "problemMatcher": "$rustc"
+    },
+    {
+      "label": "Build Server (Release) and Extension",
+      "dependsOn": ["Build Server (Release)", "Build Extension"],
+      "problemMatcher": "$rustc"
     }
   ]
-}
\ No newline at end of file
+}