Skip to content

Commit 44a164e

Browse files
Merge branch 'master'
2 parents f16ccd4 + 26bbdf1 commit 44a164e

File tree

1,040 files changed

+24058
-13952
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,040 files changed

+24058
-13952
lines changed

.devcontainer/Dockerfile

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# See here for image contents: https://github.com/microsoft/vscode-dev-containers/tree/v0.154.0/containers/javascript-node/.devcontainer/base.Dockerfile
2+
3+
# [Choice] Node.js version: 14, 12, 10
4+
ARG VARIANT="14-buster"
5+
FROM mcr.microsoft.com/vscode/devcontainers/javascript-node:0-${VARIANT}
6+
7+
RUN sudo -u node npm install -g gulp-cli

.devcontainer/devcontainer.json

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{
2+
"name": "Node.js",
3+
"build": {
4+
"dockerfile": "Dockerfile",
5+
"args": {
6+
"VARIANT": "14"
7+
}
8+
},
9+
"settings": {
10+
"terminal.integrated.shell.linux": "/bin/bash"
11+
},
12+
"extensions": [
13+
"dbaeumer.vscode-eslint"
14+
],
15+
"remoteUser": "node"
16+
}

.github/workflows/new-release-branch.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
sed -i -e 's/const versionMajorMinor = ".*"/const versionMajorMinor = "${{ github.event.client_payload.core_major_minor }}"/g' src/compiler/corePublic.ts
2323
sed -i -e 's/const versionMajorMinor = ".*"/const versionMajorMinor = "${{ github.event.client_payload.core_major_minor }}"/g' tests/baselines/reference/api/typescript.d.ts
2424
sed -i -e 's/const versionMajorMinor = ".*"/const versionMajorMinor = "${{ github.event.client_payload.core_major_minor }}"/g' tests/baselines/reference/api/tsserverlibrary.d.ts
25-
sed -i -e 's/const version = `${versionMajorMinor}.0-.*`/const version = `${versionMajorMinor}.0-${{ github.event.client_payload.core_tag || 'dev' }}`/g' src/compiler/corePublic.ts
25+
sed -i -e 's/const version\(: string\)\{0,1\} = `${versionMajorMinor}.0-.*`/const version = `${versionMajorMinor}.0-${{ github.event.client_payload.core_tag || 'dev' }}`/g' src/compiler/corePublic.ts
2626
npm ci
2727
gulp LKG
2828
npm test

.github/workflows/set-version.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
sed -i -e 's/const versionMajorMinor = ".*"/const versionMajorMinor = "${{ github.event.client_payload.core_major_minor }}"/g' src/compiler/corePublic.ts
2929
sed -i -e 's/const versionMajorMinor = ".*"/const versionMajorMinor = "${{ github.event.client_payload.core_major_minor }}"/g' tests/baselines/reference/api/typescript.d.ts
3030
sed -i -e 's/const versionMajorMinor = ".*"/const versionMajorMinor = "${{ github.event.client_payload.core_major_minor }}"/g' tests/baselines/reference/api/tsserverlibrary.d.ts
31-
sed -i -e 's/const version = .*;/const version = "${{ github.event.client_payload.package_version }}" as string;/g' src/compiler/corePublic.ts
31+
sed -i -e 's/const version\(: string\)\{0,1\} = .*;/const version = "${{ github.event.client_payload.package_version }}" as string;/g' src/compiler/corePublic.ts
3232
npm ci
3333
gulp LKG
3434
npm test

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@ tests/baselines/reference/dt
8585
.failed-tests
8686
TEST-results.xml
8787
package-lock.json
88+
tests/cases/user/npm/npm
8889
tests/cases/user/TypeScript-React-Starter/TypeScript-React-Starter
8990
tests/cases/user/TypeScript-Node-Starter/TypeScript-Node-Starter
9091
tests/cases/user/TypeScript-React-Native-Starter/TypeScript-React-Native-Starter

.npmignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ scripts
1010
src
1111
tests
1212
Jakefile.js
13+
.devcontainer
1314
.eslintrc
1415
.eslintignore
1516
.editorconfig

.travis.yml

Lines changed: 0 additions & 28 deletions
This file was deleted.

CONTRIBUTING.md

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,13 @@ In general, things we find useful when reviewing suggestions are:
7070

7171
## Tips
7272

73+
### Using a development container
74+
75+
This repository includes a [development container](https://code.visualstudio.com/docs/remote/containers) that you can use to quickly create an isolated development environment with all the tools you need to start working on TypeScript. To get started with a dev container and VS Code, either:
76+
77+
- Clone the TypeScript repository locally and use the `Open Folder in Container` command.
78+
- Use the `Clone Repository in Container Volume` command to clone the TypeScript repository into a new container.
79+
7380
### Faster clones
7481

7582
The TypeScript repository is relatively large. To save some time, you might want to clone it without the repo's full history using `git clone --depth=1`.
@@ -153,10 +160,10 @@ gulp runtests --tests=2dArrays
153160

154161
## Debugging the tests
155162

156-
You can debug with VS Code or Node instead with `gulp runtests --inspect`:
163+
You can debug with VS Code or Node instead with `gulp runtests -i`:
157164

158165
```Shell
159-
gulp runtests --tests=2dArrays --inspect
166+
gulp runtests --tests=2dArrays -i
160167
```
161168

162169
You can also use the [provided VS Code launch configuration](./.vscode/launch.template.json) to launch a debug session for an open test file. Rename the file 'launch.json', open the test file of interest, and launch the debugger from the debug panel (or press F5).

Gulpfile.js

Lines changed: 6 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ const log = require("fancy-log");
55
const newer = require("gulp-newer");
66
const sourcemaps = require("gulp-sourcemaps");
77
const del = require("del");
8-
const fold = require("travis-fold");
98
const rename = require("gulp-rename");
109
const concat = require("gulp-concat");
1110
const merge2 = require("merge2");
@@ -346,9 +345,6 @@ const runEslintRulesTests = () => runConsoleTests("scripts/eslint/built/tests",
346345
task("run-eslint-rules-tests", series(buildEslintRules, runEslintRulesTests));
347346
task("run-eslint-rules-tests").description = "Runs the eslint rule tests";
348347

349-
const lintFoldStart = async () => { if (fold.isTravis()) console.log(fold.start("lint")); };
350-
const lintFoldEnd = async () => { if (fold.isTravis()) console.log(fold.end("lint")); };
351-
352348
/** @type { (folder: string) => { (): Promise<any>; displayName?: string } } */
353349
const eslint = (folder) => async () => {
354350

@@ -374,20 +370,20 @@ const eslint = (folder) => async () => {
374370

375371
const lintScripts = eslint("scripts");
376372
lintScripts.displayName = "lint-scripts";
377-
task("lint-scripts", series([buildEslintRules, lintFoldStart, lintScripts, lintFoldEnd]));
373+
task("lint-scripts", series([buildEslintRules, lintScripts]));
378374
task("lint-scripts").description = "Runs eslint on the scripts sources.";
379375

380376
const lintCompiler = eslint("src");
381377
lintCompiler.displayName = "lint-compiler";
382-
task("lint-compiler", series([buildEslintRules, lintFoldStart, lintCompiler, lintFoldEnd]));
378+
task("lint-compiler", series([buildEslintRules, lintCompiler]));
383379
task("lint-compiler").description = "Runs eslint on the compiler sources.";
384380
task("lint-compiler").flags = {
385381
" --ci": "Runs eslint additional rules",
386382
};
387383

388-
const lint = series([buildEslintRules, lintFoldStart, lintScripts, lintCompiler, lintFoldEnd]);
384+
const lint = series([buildEslintRules, lintScripts, lintCompiler]);
389385
lint.displayName = "lint";
390-
task("lint", series([buildEslintRules, lintFoldStart, lint, lintFoldEnd]));
386+
task("lint", series([buildEslintRules, lint]));
391387
task("lint").description = "Runs eslint on the compiler and scripts sources.";
392388
task("lint").flags = {
393389
" --ci": "Runs eslint additional rules",
@@ -429,9 +425,7 @@ const buildOtherOutputs = parallel(buildCancellationToken, buildTypingsInstaller
429425
task("other-outputs", series(preBuild, buildOtherOutputs));
430426
task("other-outputs").description = "Builds miscelaneous scripts and documents distributed with the LKG";
431427

432-
const buildFoldStart = async () => { if (fold.isTravis()) console.log(fold.start("build")); };
433-
const buildFoldEnd = async () => { if (fold.isTravis()) console.log(fold.end("build")); };
434-
task("local", series(buildFoldStart, preBuild, parallel(localize, buildTsc, buildServer, buildServices, buildLssl, buildOtherOutputs), buildFoldEnd));
428+
task("local", series(preBuild, parallel(localize, buildTsc, buildServer, buildServices, buildLssl, buildOtherOutputs)));
435429
task("local").description = "Builds the full compiler and services";
436430
task("local").flags = {
437431
" --built": "Compile using the built version of the compiler."
@@ -459,8 +453,7 @@ task("runtests").flags = {
459453
"-t --tests=<regex>": "Pattern for tests to run.",
460454
" --failed": "Runs tests listed in '.failed-tests'.",
461455
"-r --reporter=<reporter>": "The mocha reporter to use.",
462-
"-d --debug": "Runs tests in debug mode (NodeJS 6 and earlier)",
463-
"-i --inspect": "Runs tests in inspector mode (NodeJS 8 and later)",
456+
"-i --break": "Runs tests in inspector mode (NodeJS 8 and later)",
464457
" --keepFailed": "Keep tests in .failed-tests even if they pass",
465458
" --light": "Run tests in light mode (fewer verifications, but tests run faster)",
466459
" --dirty": "Run tests without first cleaning test output directories",

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
# TypeScript
33

4-
[![Build Status](https://travis-ci.org/microsoft/TypeScript.svg?branch=master)](https://travis-ci.org/microsoft/TypeScript)
4+
[![GitHub Actions CI](https://github.com/microsoft/TypeScript/workflows/CI/badge.svg)](https://github.com/microsoft/TypeScript/actions?query=workflow%3ACI)
55
[![Devops Build Status](https://dev.azure.com/typescript/TypeScript/_apis/build/status/Typescript/node10)](https://dev.azure.com/typescript/TypeScript/_build?definitionId=7)
66
[![npm version](https://badge.fury.io/js/typescript.svg)](https://www.npmjs.com/package/typescript)
77
[![Downloads](https://img.shields.io/npm/dm/typescript.svg)](https://www.npmjs.com/package/typescript)

0 commit comments

Comments
 (0)