From 924eda35a04954244677dc950b469e862ed35fe6 Mon Sep 17 00:00:00 2001 From: Vincent Fugnitto Date: Thu, 17 Feb 2022 10:59:37 -0500 Subject: [PATCH] repo: cleanup dependencies (#10717) The commit performs the following changes: - removes an unused dependencies from `@theia` extensions - adds any missing dependencies (declared but never added to the respective `package.json`) Signed-off-by: vince-fugnitto --- dev-packages/cli/package.json | 10 +----- packages/callhierarchy/package.json | 1 - packages/callhierarchy/tsconfig.json | 3 -- packages/debug/package.json | 2 -- packages/debug/tsconfig.json | 6 ---- packages/editor/package.json | 4 +-- packages/file-search/package.json | 1 - packages/file-search/src/common/monaco.d.ts | 18 ----------- packages/file-search/tsconfig.json | 3 -- packages/filesystem/package.json | 1 - packages/getting-started/package.json | 1 - packages/getting-started/tsconfig.json | 3 -- packages/git/package.json | 1 - packages/git/tsconfig.json | 3 -- packages/keymaps/package.json | 6 +--- packages/keymaps/tsconfig.json | 3 -- packages/monaco/package.json | 1 - packages/monaco/tsconfig.json | 3 -- packages/outline-view/package.json | 3 +- packages/plugin-dev/package.json | 1 - packages/plugin-dev/tsconfig.json | 3 -- packages/preferences/package.json | 1 + .../markdown/markdown-preview-handler.ts | 3 +- packages/task/package.json | 2 -- packages/task/tsconfig.json | 3 -- packages/terminal/package.json | 1 - packages/terminal/src/common/monaco.d.ts | 18 ----------- packages/terminal/tsconfig.json | 3 -- packages/vsx-registry/package.json | 5 ++- packages/workspace/package.json | 2 -- yarn.lock | 32 ------------------- 31 files changed, 8 insertions(+), 139 deletions(-) delete mode 100644 packages/file-search/src/common/monaco.d.ts delete mode 100644 packages/terminal/src/common/monaco.d.ts diff --git a/dev-packages/cli/package.json b/dev-packages/cli/package.json index b4c5ca9080842..6c4d2f2ee1556 100644 --- a/dev-packages/cli/package.json +++ b/dev-packages/cli/package.json @@ -36,12 +36,9 @@ "@theia/localization-manager": "1.22.1", "@theia/ovsx-client": "1.22.1", "@types/chai": "^4.2.7", - "@types/mkdirp": "^0.5.2", "@types/mocha": "^5.2.7", "@types/node-fetch": "^2.5.7", "@types/puppeteer": "^2.0.0", - "@types/requestretry": "^1.12.3", - "@types/tar": "^4.0.3", "chai": "^4.2.0", "chalk": "4.0.0", "decompress": "^4.2.1", @@ -52,18 +49,13 @@ "puppeteer": "^2.0.0", "puppeteer-to-istanbul": "^1.2.2", "temp": "^0.9.1", - "unzipper": "^0.9.11", "yargs": "^15.3.1" }, "devDependencies": { "@types/chai": "^4.2.7", - "@types/mkdirp": "^0.5.2", "@types/mocha": "^5.2.7", "@types/node-fetch": "^2.5.7", "@types/proxy-from-env": "^1.0.1", - "@types/puppeteer": "^2.0.0", - "@types/requestretry": "^1.12.3", - "@types/tar": "^4.0.3", - "@types/unzipper": "^0.9.2" + "@types/puppeteer": "^2.0.0" } } diff --git a/packages/callhierarchy/package.json b/packages/callhierarchy/package.json index 7941b81fd4b98..66eb519dea4d1 100644 --- a/packages/callhierarchy/package.json +++ b/packages/callhierarchy/package.json @@ -5,7 +5,6 @@ "dependencies": { "@theia/core": "1.22.1", "@theia/editor": "1.22.1", - "@theia/monaco": "1.22.1", "ts-md5": "^1.2.2" }, "publishConfig": { diff --git a/packages/callhierarchy/tsconfig.json b/packages/callhierarchy/tsconfig.json index 0092f6642b1db..c38a9348d8737 100644 --- a/packages/callhierarchy/tsconfig.json +++ b/packages/callhierarchy/tsconfig.json @@ -14,9 +14,6 @@ }, { "path": "../editor" - }, - { - "path": "../monaco" } ] } diff --git a/packages/debug/package.json b/packages/debug/package.json index bde340c7bea14..83df6e6a4ac31 100644 --- a/packages/debug/package.json +++ b/packages/debug/package.json @@ -10,11 +10,9 @@ "@theia/markers": "1.22.1", "@theia/monaco": "1.22.1", "@theia/output": "1.22.1", - "@theia/preferences": "1.22.1", "@theia/process": "1.22.1", "@theia/task": "1.22.1", "@theia/terminal": "1.22.1", - "@theia/userstorage": "1.22.1", "@theia/variable-resolver": "1.22.1", "@theia/workspace": "1.22.1", "jsonc-parser": "^2.2.0", diff --git a/packages/debug/tsconfig.json b/packages/debug/tsconfig.json index 2f705d1533161..aec95d2fcfb8e 100644 --- a/packages/debug/tsconfig.json +++ b/packages/debug/tsconfig.json @@ -30,9 +30,6 @@ { "path": "../output" }, - { - "path": "../preferences" - }, { "path": "../process" }, @@ -42,9 +39,6 @@ { "path": "../terminal" }, - { - "path": "../userstorage" - }, { "path": "../variable-resolver" }, diff --git a/packages/editor/package.json b/packages/editor/package.json index 9cde3aa3ad48a..489408260040b 100644 --- a/packages/editor/package.json +++ b/packages/editor/package.json @@ -4,9 +4,7 @@ "description": "Theia - Editor Extension", "dependencies": { "@theia/core": "1.22.1", - "@theia/variable-resolver": "1.22.1", - "@types/base64-arraybuffer": "0.1.0", - "base64-arraybuffer": "^0.1.5" + "@theia/variable-resolver": "1.22.1" }, "publishConfig": { "access": "public" diff --git a/packages/file-search/package.json b/packages/file-search/package.json index a3bc276622330..5aad32c5d70cf 100644 --- a/packages/file-search/package.json +++ b/packages/file-search/package.json @@ -6,7 +6,6 @@ "@theia/core": "1.22.1", "@theia/editor": "1.22.1", "@theia/filesystem": "1.22.1", - "@theia/monaco": "1.22.1", "@theia/process": "1.22.1", "@theia/workspace": "1.22.1", "vscode-ripgrep": "^1.2.4" diff --git a/packages/file-search/src/common/monaco.d.ts b/packages/file-search/src/common/monaco.d.ts deleted file mode 100644 index f11e85e573305..0000000000000 --- a/packages/file-search/src/common/monaco.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -/******************************************************************************** - * Copyright (c) 2021 SAP SE or an SAP affiliate company and others. - * - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v. 2.0 which is available at - * http://www.eclipse.org/legal/epl-2.0. - * - * This Source Code may also be made available under the following Secondary - * Licenses when the conditions for such availability set forth in the Eclipse - * Public License v. 2.0 are satisfied: GNU General Public License, version 2 - * with the GNU Classpath Exception which is available at - * https://www.gnu.org/software/classpath/license.html. - * - * SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 - ********************************************************************************/ - -// eslint-disable-next-line spaced-comment -/// diff --git a/packages/file-search/tsconfig.json b/packages/file-search/tsconfig.json index 1fdba749bb46d..3153a10e1d53d 100644 --- a/packages/file-search/tsconfig.json +++ b/packages/file-search/tsconfig.json @@ -18,9 +18,6 @@ { "path": "../filesystem" }, - { - "path": "../monaco" - }, { "path": "../process" }, diff --git a/packages/filesystem/package.json b/packages/filesystem/package.json index 4dd14ac28066f..c44cac7a072d1 100644 --- a/packages/filesystem/package.json +++ b/packages/filesystem/package.json @@ -14,7 +14,6 @@ "http-status-codes": "^1.3.0", "minimatch": "^3.0.4", "multer": "^1.4.2", - "perfect-scrollbar": "^1.3.0", "rimraf": "^2.6.2", "tar-fs": "^1.16.2", "trash": "^6.1.1", diff --git a/packages/getting-started/package.json b/packages/getting-started/package.json index 3505af106cd0e..ee9482a368be9 100644 --- a/packages/getting-started/package.json +++ b/packages/getting-started/package.json @@ -4,7 +4,6 @@ "description": "Theia - GettingStarted Extension", "dependencies": { "@theia/core": "1.22.1", - "@theia/filesystem": "1.22.1", "@theia/keymaps": "1.22.1", "@theia/workspace": "1.22.1" }, diff --git a/packages/getting-started/tsconfig.json b/packages/getting-started/tsconfig.json index 01419ce9bc938..ba31f57815a43 100644 --- a/packages/getting-started/tsconfig.json +++ b/packages/getting-started/tsconfig.json @@ -12,9 +12,6 @@ { "path": "../core" }, - { - "path": "../filesystem" - }, { "path": "../keymaps" }, diff --git a/packages/git/package.json b/packages/git/package.json index 720d4eb11a7fb..533f3f8623226 100644 --- a/packages/git/package.json +++ b/packages/git/package.json @@ -6,7 +6,6 @@ "@theia/core": "1.22.1", "@theia/editor": "1.22.1", "@theia/filesystem": "1.22.1", - "@theia/monaco": "1.22.1", "@theia/navigator": "1.22.1", "@theia/scm": "1.22.1", "@theia/scm-extra": "1.22.1", diff --git a/packages/git/tsconfig.json b/packages/git/tsconfig.json index 2b52c425d9067..7fac7b0037c1a 100644 --- a/packages/git/tsconfig.json +++ b/packages/git/tsconfig.json @@ -18,9 +18,6 @@ { "path": "../filesystem" }, - { - "path": "../monaco" - }, { "path": "../navigator" }, diff --git a/packages/keymaps/package.json b/packages/keymaps/package.json index 6e9166a1c1758..f8d41422195fb 100644 --- a/packages/keymaps/package.json +++ b/packages/keymaps/package.json @@ -6,14 +6,10 @@ "@theia/core": "1.22.1", "@theia/monaco": "1.22.1", "@theia/userstorage": "1.22.1", - "@theia/workspace": "1.22.1", - "@types/lodash.debounce": "4.0.3", "jsonc-parser": "^2.2.0" }, "devDependencies": { - "@theia/ext-scripts": "1.22.1", - "@types/temp": "^0.8.29", - "temp": "^0.8.3" + "@theia/ext-scripts": "1.22.1" }, "publishConfig": { "access": "public" diff --git a/packages/keymaps/tsconfig.json b/packages/keymaps/tsconfig.json index 8592cfea8ca09..e4bf339ed2b6a 100644 --- a/packages/keymaps/tsconfig.json +++ b/packages/keymaps/tsconfig.json @@ -17,9 +17,6 @@ }, { "path": "../userstorage" - }, - { - "path": "../workspace" } ] } diff --git a/packages/monaco/package.json b/packages/monaco/package.json index d42110e9ba5b6..77337273bd4f6 100644 --- a/packages/monaco/package.json +++ b/packages/monaco/package.json @@ -9,7 +9,6 @@ "@theia/markers": "1.22.1", "@theia/monaco-editor-core": "0.23.0", "@theia/outline-view": "1.22.1", - "@theia/workspace": "1.22.1", "fast-plist": "^0.1.2", "idb": "^4.0.5", "jsonc-parser": "^2.2.0", diff --git a/packages/monaco/tsconfig.json b/packages/monaco/tsconfig.json index 0123614ccd2c0..85d090101540c 100644 --- a/packages/monaco/tsconfig.json +++ b/packages/monaco/tsconfig.json @@ -23,9 +23,6 @@ }, { "path": "../outline-view" - }, - { - "path": "../workspace" } ] } diff --git a/packages/outline-view/package.json b/packages/outline-view/package.json index 2fc3f95c59d06..e1a71da5c460c 100644 --- a/packages/outline-view/package.json +++ b/packages/outline-view/package.json @@ -3,8 +3,7 @@ "version": "1.22.1", "description": "Theia - Outline View Extension", "dependencies": { - "@theia/core": "1.22.1", - "perfect-scrollbar": "^1.3.0" + "@theia/core": "1.22.1" }, "publishConfig": { "access": "public" diff --git a/packages/plugin-dev/package.json b/packages/plugin-dev/package.json index a332ab733903d..0395705f08e1b 100644 --- a/packages/plugin-dev/package.json +++ b/packages/plugin-dev/package.json @@ -10,7 +10,6 @@ "@theia/filesystem": "1.22.1", "@theia/output": "1.22.1", "@theia/plugin-ext": "1.22.1", - "@theia/preferences": "1.22.1", "@theia/workspace": "1.22.1", "@types/request": "^2.0.3", "ps-tree": "^1.2.0", diff --git a/packages/plugin-dev/tsconfig.json b/packages/plugin-dev/tsconfig.json index 799c3d4868789..dc9251a6802a3 100644 --- a/packages/plugin-dev/tsconfig.json +++ b/packages/plugin-dev/tsconfig.json @@ -28,9 +28,6 @@ { "path": "../plugin-ext" }, - { - "path": "../preferences" - }, { "path": "../workspace" } diff --git a/packages/preferences/package.json b/packages/preferences/package.json index ecfb63e896ccd..4ddd64314bbff 100644 --- a/packages/preferences/package.json +++ b/packages/preferences/package.json @@ -10,6 +10,7 @@ "@theia/userstorage": "1.22.1", "@theia/workspace": "1.22.1", "async-mutex": "^0.3.1", + "p-debounce": "^2.1.0", "jsonc-parser": "^2.2.0" }, "publishConfig": { diff --git a/packages/preview/src/browser/markdown/markdown-preview-handler.ts b/packages/preview/src/browser/markdown/markdown-preview-handler.ts index fdd81e58bae5c..b4e28f648e0b5 100644 --- a/packages/preview/src/browser/markdown/markdown-preview-handler.ts +++ b/packages/preview/src/browser/markdown/markdown-preview-handler.ts @@ -52,10 +52,9 @@ export class MarkdownPreviewHandler implements PreviewHandler { renderContent(params: RenderContentParams): HTMLElement { const content = params.content; const renderedContent = this.getEngine().render(content, params); - const sanitizedContent = DOMPurify.sanitize(renderedContent); const contentElement = document.createElement('div'); contentElement.classList.add(this.contentClass); - contentElement.innerHTML = sanitizedContent; + contentElement.innerHTML = DOMPurify.sanitize(renderedContent); this.addLinkClickedListener(contentElement, params); return contentElement; } diff --git a/packages/task/package.json b/packages/task/package.json index 67b90dd9f8f16..9c719a7de42f1 100644 --- a/packages/task/package.json +++ b/packages/task/package.json @@ -8,13 +8,11 @@ "@theia/filesystem": "1.22.1", "@theia/markers": "1.22.1", "@theia/monaco": "1.22.1", - "@theia/preferences": "1.22.1", "@theia/process": "1.22.1", "@theia/terminal": "1.22.1", "@theia/userstorage": "1.22.1", "@theia/variable-resolver": "1.22.1", "@theia/workspace": "1.22.1", - "ajv": "^6.5.3", "async-mutex": "^0.3.1", "jsonc-parser": "^2.2.0", "p-debounce": "^2.1.0" diff --git a/packages/task/tsconfig.json b/packages/task/tsconfig.json index ab99552ab0aaf..2fd121a16f5ac 100644 --- a/packages/task/tsconfig.json +++ b/packages/task/tsconfig.json @@ -24,9 +24,6 @@ { "path": "../monaco" }, - { - "path": "../preferences" - }, { "path": "../process" }, diff --git a/packages/terminal/package.json b/packages/terminal/package.json index 8d3776b35aa69..5228a49a701af 100644 --- a/packages/terminal/package.json +++ b/packages/terminal/package.json @@ -6,7 +6,6 @@ "@theia/core": "1.22.1", "@theia/editor": "1.22.1", "@theia/filesystem": "1.22.1", - "@theia/monaco": "1.22.1", "@theia/process": "1.22.1", "@theia/workspace": "1.22.1", "xterm": "^4.16.0", diff --git a/packages/terminal/src/common/monaco.d.ts b/packages/terminal/src/common/monaco.d.ts deleted file mode 100644 index e83d9aa19bf14..0000000000000 --- a/packages/terminal/src/common/monaco.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -/******************************************************************************** - * Copyright (C) 2018 TypeFox and others. - * - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v. 2.0 which is available at - * http://www.eclipse.org/legal/epl-2.0. - * - * This Source Code may also be made available under the following Secondary - * Licenses when the conditions for such availability set forth in the Eclipse - * Public License v. 2.0 are satisfied: GNU General Public License, version 2 - * with the GNU Classpath Exception which is available at - * https://www.gnu.org/software/classpath/license.html. - * - * SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 - ********************************************************************************/ - -// eslint-disable-next-line spaced-comment -/// diff --git a/packages/terminal/tsconfig.json b/packages/terminal/tsconfig.json index 1fdba749bb46d..3153a10e1d53d 100644 --- a/packages/terminal/tsconfig.json +++ b/packages/terminal/tsconfig.json @@ -18,9 +18,6 @@ { "path": "../filesystem" }, - { - "path": "../monaco" - }, { "path": "../process" }, diff --git a/packages/vsx-registry/package.json b/packages/vsx-registry/package.json index 8350d228e4b93..4a7cb3f65ff22 100644 --- a/packages/vsx-registry/package.json +++ b/packages/vsx-registry/package.json @@ -10,9 +10,7 @@ "@theia/plugin-ext-vscode": "1.22.1", "@theia/preferences": "1.22.1", "@theia/workspace": "1.22.1", - "@types/bent": "^7.0.1", "@types/showdown": "^1.7.1", - "bent": "^7.1.0", "p-debounce": "^2.1.0", "requestretry": "^3.1.0", "semver": "^5.4.1", @@ -53,7 +51,8 @@ "watch": "theiaext watch" }, "devDependencies": { - "@theia/ext-scripts": "1.22.1" + "@theia/ext-scripts": "1.22.1", + "@types/requestretry": "^1.12.3" }, "nyc": { "extends": "../../configs/nyc.json" diff --git a/packages/workspace/package.json b/packages/workspace/package.json index 78e308f4115cf..14da32e89265f 100644 --- a/packages/workspace/package.json +++ b/packages/workspace/package.json @@ -6,9 +6,7 @@ "@theia/core": "1.22.1", "@theia/filesystem": "1.22.1", "@theia/variable-resolver": "1.22.1", - "ajv": "^6.5.3", "jsonc-parser": "^2.2.0", - "moment": "2.24.0", "valid-filename": "^2.0.1" }, "publishConfig": { diff --git a/yarn.lock b/yarn.lock index 089cbbb14161f..7e0927f5cd9e7 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2162,11 +2162,6 @@ resolved "https://registry.yarnpkg.com/@tootallnate/once/-/once-1.1.2.tgz#ccb91445360179a04e7fe6aff78c00ffc1eeaf82" integrity sha512-RbzJvlNzmRq5c3O09UipeuXno4tA1FE6ikOjxZK0tuxVv3412l64l5t1W5pj4+rJq9vpkm/kwiR07aZXnsKPxw== -"@types/base64-arraybuffer@0.1.0": - version "0.1.0" - resolved "https://registry.yarnpkg.com/@types/base64-arraybuffer/-/base64-arraybuffer-0.1.0.tgz#739eea0a974d13ae831f96d97d882ceb0b187543" - integrity sha512-oyV0CGER7tX6OlfnLfGze0XbsA7tfRuTtsQ2JbP8K5KBUzc24yoYRD+0XjMRQgOejvZWeIbtkNaHlE8akzj4aQ== - "@types/bent@^7.0.1": version "7.3.2" resolved "https://registry.yarnpkg.com/@types/bent/-/bent-7.3.2.tgz#07b4f7bcec577be27cdb9e9034eb0de0242481a7" @@ -2466,20 +2461,6 @@ resolved "https://registry.yarnpkg.com/@types/minimist/-/minimist-1.2.2.tgz#ee771e2ba4b3dc5b372935d549fd9617bf345b8c" integrity sha512-jhuKLIRrhvCPLqwPcx6INqmKeiA5EWrsCOPhrlFSrbrmU4ZMPjj5Ul/oLCMDO98XRUIwVm78xICz4EPCektzeQ== -"@types/minipass@*": - version "3.1.2" - resolved "https://registry.yarnpkg.com/@types/minipass/-/minipass-3.1.2.tgz#e2d7f9df0698aff421dcf145b4fc05b8183b9030" - integrity sha512-foLGjgrJkUjLG/o2t2ymlZGEoBNBa/TfoUZ7oCTkOjP1T43UGBJspovJou/l3ZuHvye2ewR5cZNtp2zyWgILMA== - dependencies: - "@types/node" "*" - -"@types/mkdirp@^0.5.2": - version "0.5.2" - resolved "https://registry.yarnpkg.com/@types/mkdirp/-/mkdirp-0.5.2.tgz#503aacfe5cc2703d5484326b1b27efa67a339c1f" - integrity sha512-U5icWpv7YnZYGsN4/cmh3WD2onMY0aJIiTE6+51TwJCttdHvtCYmkBNOobHlXwrJRL0nkH9jH4kD+1FAdMN4Tg== - dependencies: - "@types/node" "*" - "@types/mocha@^5.2.7": version "5.2.7" resolved "https://registry.yarnpkg.com/@types/mocha/-/mocha-5.2.7.tgz#315d570ccb56c53452ff8638738df60726d5b6ea" @@ -2702,14 +2683,6 @@ dependencies: "@types/node" "*" -"@types/tar@^4.0.3": - version "4.0.5" - resolved "https://registry.yarnpkg.com/@types/tar/-/tar-4.0.5.tgz#5f953f183e36a15c6ce3f336568f6051b7b183f3" - integrity sha512-cgwPhNEabHaZcYIy5xeMtux2EmYBitfqEceBUi2t5+ETy4dW6kswt6WX4+HqLeiiKOo42EXbGiDmVJ2x+vi37Q== - dependencies: - "@types/minipass" "*" - "@types/node" "*" - "@types/temp@^0.8.29": version "0.8.34" resolved "https://registry.yarnpkg.com/@types/temp/-/temp-0.8.34.tgz#03e4b3cb67cbb48c425bbf54b12230fef85540ac" @@ -3566,11 +3539,6 @@ balanced-match@^1.0.0: resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== -base64-arraybuffer@^0.1.5: - version "0.1.5" - resolved "https://registry.yarnpkg.com/base64-arraybuffer/-/base64-arraybuffer-0.1.5.tgz#73926771923b5a19747ad666aa5cd4bf9c6e9ce8" - integrity sha1-c5JncZI7Whl0etZmqlzUv5xunOg= - base64-js@^1.3.1: version "1.5.1" resolved "https://registry.yarnpkg.com/base64-js/-/base64-js-1.5.1.tgz#1b1b440160a5bf7ad40b650f095963481903930a"