UNPKG

5.21 kBJSONView Raw
1// Available variables which can be used inside of strings.
2// ${workspaceRoot}: the root folder of the team
3// ${file}: the current opened file
4// ${fileBasename}: the current opened file's basename
5// ${fileDirname}: the current opened file's dirname
6// ${fileExtname}: the current opened file's extension
7// ${cwd}: the current working directory of the spawned process
8// A task runner that calls the Typescript compiler (tsc) and
9// Compiles a HelloWorld.ts program
10{
11 "version": "0.1.0",
12 "command": "gulp",
13 "isShellCommand": true,
14 "tasks": [
15 {
16 "taskName": "test",
17 "args": []
18 },
19 {
20 "taskName": "build",
21 "isBuildCommand": true,
22 "problemMatcher": [
23 "$tsc"
24 ],
25 "args": []
26 }
27 ]
28}
29// A task runner that calls the Typescript compiler (tsc) and
30// compiles based on a tsconfig.json file that is present in
31// the root of the folder open in VSCode
32/*
33{
34 "version": "0.1.0",
35
36 // The command is tsc. Assumes that tsc has been installed using npm install -g typescript
37 "command": "tsc",
38
39 // The command is a shell script
40 "isShellCommand": true,
41
42 // Show the output window only if unrecognized errors occur.
43 "showOutput": "silent",
44
45 // Tell the tsc compiler to use the tsconfig.json from the open folder.
46 "args": ["-p", "."],
47
48 // use the standard tsc problem matcher to find compile problems
49 // in the output.
50 "problemMatcher": "$tsc"
51}
52*/
53// A task runner configuration for gulp. Gulp provides a less task
54// which compiles less to css.
55/*
56{
57 "version": "0.1.0",
58 "command": "gulp",
59 "isShellCommand": true,
60 "tasks": [
61 {
62 "taskName": "less",
63 // Make this the default build command.
64 "isBuildCommand": true,
65 // Show the output window only if unrecognized errors occur.
66 "showOutput": "silent",
67 // Use the standard less compilation problem matcher.
68 "problemMatcher": "$lessCompile"
69 }
70 ]
71}
72*/
73// Uncomment the following section to use jake to build a workspace
74// cloned from https://github.com/Microsoft/TypeScript.git
75/*
76{
77 "version": "0.1.0",
78 // Task runner is jake
79 "command": "jake",
80 // Need to be executed in shell / cmd
81 "isShellCommand": true,
82 "showOutput": "silent",
83 "tasks": [
84 {
85 // TS build command is local.
86 "taskName": "local",
87 // Make this the default build command.
88 "isBuildCommand": true,
89 // Show the output window only if unrecognized errors occur.
90 "showOutput": "silent",
91 // Use the redefined Typescript output problem matcher.
92 "problemMatcher": [
93 "$tsc"
94 ]
95 }
96 ]
97}
98*/
99// Uncomment the section below to use msbuild and generate problems
100// for csc, cpp, tsc and vb. The configuration assumes that msbuild
101// is available on the path and a solution file exists in the
102// workspace folder root.
103/*
104{
105 "version": "0.1.0",
106 "command": "msbuild",
107 "args": [
108 // Ask msbuild to generate full paths for file names.
109 "/property:GenerateFullPaths=true"
110 ],
111 "taskSelector": "/t:",
112 "showOutput": "silent",
113 "tasks": [
114 {
115 "taskName": "build",
116 // Show the output window only if unrecognized errors occur.
117 "showOutput": "silent",
118 // Use the standard MS compiler pattern to detect errors, warnings
119 // and infos in the output.
120 "problemMatcher": "$msCompile"
121 }
122 ]
123}
124*/
125// Uncomment the following section to use msbuild which compiles Typescript
126// and less files.
127/*
128{
129 "version": "0.1.0",
130 "command": "msbuild",
131 "args": [
132 // Ask msbuild to generate full paths for file names.
133 "/property:GenerateFullPaths=true"
134 ],
135 "taskSelector": "/t:",
136 "showOutput": "silent",
137 "tasks": [
138 {
139 "taskName": "build",
140 // Show the output window only if unrecognized errors occur.
141 "showOutput": "silent",
142 // Use the standard MS compiler pattern to detect errors, warnings
143 // and infos in the output.
144 "problemMatcher": [
145 "$msCompile",
146 "$lessCompile"
147 ]
148 }
149 ]
150}
151*/
152// A task runner example that defines a problemMatcher inline instead of using
153// a predefined one.
154/*
155{
156 "version": "0.1.0",
157 "command": "tsc",
158 "isShellCommand": true,
159 "args": ["HelloWorld.ts"],
160 "showOutput": "silent",
161 "problemMatcher": {
162 // The problem is owned by the typescript language service. Ensure that the problems
163 // are merged with problems produced by Visual Studio's language service.
164 "owner": "typescript",
165 // The file name for reported problems is relative to the current working directory.
166 "fileLocation": ["relative", "${cwd}"],
167 // The actual pattern to match problems in the output.
168 "pattern": {
169 // The regular expression. Matches HelloWorld.ts(2,10): error TS2339: Property 'logg' does not exist on type 'Console'.
170 "regexp": "^([^\\s].*)\\((\\d+|\\d+,\\d+|\\d+,\\d+,\\d+,\\d+)\\):\\s+(error|warning|info)\\s+(TS\\d+)\\s*:\\s*(.*)$",
171 // The match group that denotes the file containing the problem.
172 "file": 1,
173 // The match group that denotes the problem location.
174 "location": 2,
175 // The match group that denotes the problem's severity. Can be omitted.
176 "severity": 3,
177 // The match group that denotes the problem code. Can be omitted.
178 "code": 4,
179 // The match group that denotes the problem's message.
180 "message": 5
181 }
182 }
183}
184*/
\No newline at end of file