Update more npm packages, TypeScript and commit package-lock.json

This commit is contained in:
Alexander Köplinger 2020-10-07 13:03:51 +02:00
Родитель 2c3497f748
Коммит c5d03e62f7
8 изменённых файлов: 3223 добавлений и 39 удалений

13
.eslintrc.yml Normal file
Просмотреть файл

@ -0,0 +1,13 @@
env:
browser: true
es2021: true
extends:
- 'eslint:recommended'
- 'plugin:@typescript-eslint/recommended'
parser: '@typescript-eslint/parser'
parserOptions:
ecmaVersion: 12
sourceType: module
plugins:
- '@typescript-eslint'
rules: {}

1
.gitignore поставляемый
Просмотреть файл

@ -13,3 +13,4 @@
mono-debug.userprefs
npm-debug.log
.vs/
/.DS_Store

Просмотреть файл

@ -11,8 +11,8 @@ git:
before_install:
- git clone https://github.com/creationix/nvm.git ./.nvm
- source ./.nvm/nvm.sh
- nvm install 6.5
- nvm use 6.5
- nvm install 14
- nvm use 14
install:
- nuget restore mono-debug.sln

3166
package-lock.json сгенерированный Normal file

Разница между файлами не показана из-за своего большого размера Загрузить разницу

Просмотреть файл

@ -1,7 +1,7 @@
{
"name": "mono-debug",
"displayName": "Mono Debug",
"version": "0.16.0",
"version": "0.16.1",
"publisher": "ms-vscode",
"description": "Visual Studio Code debugger extension for Mono",
"icon": "images/mono-debug-icon.png",
@ -14,20 +14,20 @@
"license": "MIT",
"private": true,
"scripts": {
"prepublish": "make build",
"vscode:prepublish": "make build",
"prepare": "make build",
"vscode:prepublishOnly": "make build",
"compile": "make build",
"lint": "eslint . --ext .ts,.tsx",
"watch": "tsc -w -p ./src/typescript",
"test": "make tests; mocha --timeout 10000 -u tdd ./out/tests",
"postinstall": "node ./node_modules/vscode/bin/install"
"test": "make tests; mocha --timeout 10000 -u tdd ./out/tests"
},
"engines": {
"vscode": "^1.8.0",
"node": "^6.3.0"
"vscode": "^1.32.0",
"node": "^14.0.0"
},
"dependencies": {
"vscode-debugprotocol": "^1.20.0",
"vscode-nls": "^2.0.2"
"vscode-debugprotocol": "^1.42.0",
"vscode-nls": "^5.0.0"
},
"repository": {
"type": "git",
@ -39,12 +39,16 @@
"devDependencies": {
"@types/mocha": "^8.0.3",
"@types/node": "^14.11.5",
"mocha": "^2.4.5",
"@types/vscode": "^1.32.0",
"@typescript-eslint/eslint-plugin": "^4.4.0",
"@typescript-eslint/parser": "^4.4.0",
"eslint": "^7.1.0",
"mocha": "^8.1.3",
"typescript": "^4.0.3",
"vsce": "^1.81.1",
"vscode": "^1.0.3",
"vscode-debugadapter-testsupport": "^1.20.0",
"vscode-nls-dev": "^2.0.1"
"vscode-debugadapter-testsupport": "^1.42.0",
"vscode-nls-dev": "^3.3.2",
"vscode-test": "^1.4.0"
},
"main": "./out/extension",
"activationEvents": [

Просмотреть файл

@ -24,9 +24,9 @@
"mono.launch.env.description": "Environment variables passed to the program.",
"mono.launch.externalConsole.deprecationMessage": "Attribute 'externalConsole' is deprecated, use 'console' instead.",
"mono.launch.console.description": "Where to launch the debug target.",
"mono.launch.console.internalConsole.description": "VS Code Debug Console (which doesn't support to read input from a program)",
"mono.launch.console.integratedTerminal.description": "VS Code's integrated terminal",
"mono.launch.console.externalTerminal.description": "external terminal that can be configured via user settings",
"mono.launch.console.internalConsole.description": "VS Code Debug Console (which doesn't support to read input from a program)",
"mono.launch.console.integratedTerminal.description": "VS Code's integrated terminal",
"mono.launch.console.externalTerminal.description": "external terminal that can be configured via user settings",
"mono.attach.port.description": "Debug port to attach to.",
"mono.attach.address.description": "TCP/IP address. Default is \"localhost\"."

Просмотреть файл

@ -8,7 +8,7 @@ import * as vscode from 'vscode';
import * as nls from 'vscode-nls';
import { DebugProtocol } from 'vscode-debugprotocol';
const localize = nls.config(process.env.VSCODE_NLS_CONFIG)();
const localize = nls.config()();
const configuration = vscode.workspace.getConfiguration('mono-debug');
@ -18,6 +18,7 @@ export function activate(context: vscode.ExtensionContext) {
}
export function deactivate() {
// do nothing.
}
//----- configureExceptions ---------------------------------------------------------------------------------------------------
@ -42,24 +43,25 @@ const DEFAULT_EXCEPTIONS : ExceptionConfigurations = {
};
class BreakOptionItem implements vscode.QuickPickItem {
label: string;
description: string;
breakMode: DebugProtocol.ExceptionBreakMode
label!: string;
description!: string;
breakMode!: DebugProtocol.ExceptionBreakMode;
}
// the possible exception options converted into QuickPickItem
const OPTIONS = [ 'never', 'always', 'unhandled' ].map<BreakOptionItem>((bm: DebugProtocol.ExceptionBreakMode) => {
const OPTIONS = [ 'never', 'always', 'unhandled' ].map<BreakOptionItem>((bm: string) : BreakOptionItem => {
const breakMode = <DebugProtocol.ExceptionBreakMode>bm;
return {
label: translate(bm),
label: translate(breakMode),
description: '',
breakMode: bm
breakMode: breakMode
}
});
class ExceptionItem implements vscode.QuickPickItem {
label: string;
description: string;
model: DebugProtocol.ExceptionOptions
label!: string;
description!: string;
model!: DebugProtocol.ExceptionOptions;
}
function translate(mode: DebugProtocol.ExceptionBreakMode): string {
@ -97,7 +99,7 @@ function configureExceptions() : void {
const exceptionItems: vscode.QuickPickItem[] = [];
const model = getModel();
for (var exception in model) {
for (const exception in model) {
exceptionItems.push({
label: exception,
description: model[exception] !== 'never' ? `${translate(model[exception])}` : ''
@ -127,7 +129,7 @@ function configureExceptions() : void {
});
}
function setExceptionBreakpoints(model: ExceptionConfigurations) : Thenable<DebugProtocol.SetExceptionBreakpointsResponse> {
function setExceptionBreakpoints(model: ExceptionConfigurations) : Thenable<DebugProtocol.SetExceptionBreakpointsResponse | undefined> {
const args: DebugProtocol.SetExceptionBreakpointsArguments = {
filters: [],
@ -140,7 +142,7 @@ function setExceptionBreakpoints(model: ExceptionConfigurations) : Thenable<Debu
function convertToExceptionOptions(model: ExceptionConfigurations) : DebugProtocol.ExceptionOptions[] {
const exceptionItems: DebugProtocol.ExceptionOptions[] = [];
for (var exception in model) {
for (const exception in model) {
exceptionItems.push({
path: [ { names: [ exception ] } ],
breakMode: model[exception]
@ -155,9 +157,9 @@ function convertToExceptionOptions(model: ExceptionConfigurations) : DebugProtoc
* The result type of the startSession command.
*/
class StartSessionResult {
status: 'ok' | 'initialConfiguration' | 'saveConfiguration';
status!: 'ok' | 'initialConfiguration' | 'saveConfiguration';
content?: string; // launch.json content for 'save'
};
}
function startSession(config: any) : StartSessionResult {

Просмотреть файл

@ -1,12 +1,10 @@
{
"compilerOptions": {
"module": "commonjs",
"moduleResolution": "node",
"noImplicitAny": false,
"removeComments": false,
"preserveConstEnums": true,
"target": "es5",
"target": "es2019",
"lib": ["ES2019"],
"outDir": "../../out",
"sourceMap": true
"sourceMap": true,
"strict": true
}
}