diff --git a/package.json b/package.json index d5bc007..f79ba2a 100644 --- a/package.json +++ b/package.json @@ -9679,7 +9679,7 @@ "build:extension": "webpack --mode development --config-name extension", "build:webviews": "webpack --mode development --config-name webviews", "bundle": "webpack --mode production", - "clean": "git clean -Xdf -e !node_modules -e !node_modules/**/*", + "clean": "npx rimraf .eslintcache* tsconfig*.tsbuildinfo", "lint": "eslint src/**/*.ts --fix", "pack": "vsce package --yarn", "pack-insiders": "yarn run patch-insiders && yarn run pack", @@ -9708,38 +9708,38 @@ }, "devDependencies": { "@types/chroma-js": "2.1.3", - "@types/lodash-es": "4.17.4", + "@types/lodash-es": "4.17.5", "@types/node": "14.17.4", "@types/sortablejs": "1.10.6", "@types/vscode": "1.57.0", - "@typescript-eslint/eslint-plugin": "4.28.3", - "@typescript-eslint/parser": "4.28.3", + "@typescript-eslint/eslint-plugin": "4.32.0", + "@typescript-eslint/parser": "4.32.0", "circular-dependency-plugin": "5.2.2", - "clean-webpack-plugin": "3.0.0", + "clean-webpack-plugin": "4.0.0", "copy-webpack-plugin": "9.0.1", "cross-env": "7.0.3", "csp-html-webpack-plugin": "5.1.0", - "css-loader": "5.2.6", - "esbuild": "0.12.15", - "esbuild-loader": "2.13.1", - "eslint": "7.30.0", + "css-loader": "6.3.0", + "esbuild": "0.13.3", + "esbuild-loader": "2.15.1", + "eslint": "7.32.0", "eslint-cli": "1.1.1", "eslint-config-prettier": "8.3.0", - "eslint-plugin-import": "2.23.4", - "fork-ts-checker-webpack-plugin": "6.2.12", + "eslint-plugin-import": "2.24.2", + "fork-ts-checker-webpack-plugin": "6.3.3", "html-loader": "2.1.2", "html-webpack-plugin": "5.3.2", "image-minimizer-webpack-plugin": "2.2.0", "imagemin-webp": "6.0.0", - "mini-css-extract-plugin": "2.1.0", - "prettier": "2.3.2", - "sass": "1.35.2", + "mini-css-extract-plugin": "2.3.0", + "prettier": "2.4.1", + "sass": "1.42.1", "sass-loader": "12.1.0", - "terser-webpack-plugin": "5.1.4", - "ts-loader": "9.2.3", - "typescript": "4.4.0-beta", - "vsce": "1.95.1", - "webpack": "5.44.0", + "terser-webpack-plugin": "5.2.4", + "ts-loader": "9.2.6", + "typescript": "4.4.3", + "vsce": "1.100.1", + "webpack": "5.56.0", "webpack-bundle-analyzer": "4.4.2", "webpack-cli": "4.2.0" }, diff --git a/src/container.ts b/src/container.ts index cf28463..0b66723 100644 --- a/src/container.ts +++ b/src/container.ts @@ -49,8 +49,7 @@ export class Container { private static _terminalLinks: GitTerminalLinkProvider | undefined; - static initialize(extensionId: string, context: ExtensionContext, config: Config) { - this._extensionId = extensionId; + static initialize(context: ExtensionContext, config: Config) { this._context = context; this._config = Container.applyMode(config); @@ -190,11 +189,6 @@ export class Container { return this._contributorsView; } - private static _extensionId: string; - static get extensionId() { - return this._extensionId; - } - private static _fileAnnotationController: FileAnnotationController; static get fileAnnotations() { return this._fileAnnotationController; @@ -234,7 +228,7 @@ export class Container { @memoize() static get insiders() { - return this._extensionId.endsWith('-insiders'); + return this._context.extension.id.endsWith('-insiders'); } private static _keyboard: Keyboard; diff --git a/src/extension.ts b/src/extension.ts index 8db74d1..537cff0 100644 --- a/src/extension.ts +++ b/src/extension.ts @@ -1,5 +1,4 @@ 'use strict'; -import * as paths from 'path'; import { commands, ExtensionContext, extensions, window, workspace } from 'vscode'; import { CreatePullRequestActionContext, GitLensApi, OpenPullRequestActionContext } from '../src/api/gitlens'; import { Api } from './api/api'; @@ -25,16 +24,14 @@ export async function activate(context: ExtensionContext): Promise void Messages.showInsidersErrorMessage(), 0); return undefined; } @@ -70,8 +67,7 @@ export async function activate(context: ExtensionContext): Promise(SyncedState.Version); const localVersion = @@ -154,7 +150,7 @@ export async function activate(context: ExtensionContext): Promise=3.0.0 <4.0.0" +sax@>=0.6.0: + version "1.2.4" + resolved "https://registry.yarnpkg.com/sax/-/sax-1.2.4.tgz#2816234e2378bddc4e5354fab5caa895df7100d9" + integrity sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw== + schema-utils@2.7.0: version "2.7.0" resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-2.7.0.tgz#17151f76d8eae67fbbf77960c33c676ad9f4efc7" @@ -3868,6 +3983,15 @@ schema-utils@^3.0.0: ajv "^6.12.5" ajv-keywords "^3.5.2" +schema-utils@^3.1.0, schema-utils@^3.1.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-3.1.1.tgz#bc74c4b6b6995c1d88f76a8b77bea7219e0c8281" + integrity sha512-Y5PQxS4ITlC+EahLuXaY86TXfR7Dc5lw294alXOq86JAHCihAIZfqv8nNCWvaEJvaC51uN9hbLGeV0cFBdH+Fw== + dependencies: + "@types/json-schema" "^7.0.8" + ajv "^6.12.5" + ajv-keywords "^3.5.2" + seek-bzip@^1.0.5: version "1.0.6" resolved "https://registry.yarnpkg.com/seek-bzip/-/seek-bzip-1.0.6.tgz#35c4171f55a680916b52a07859ecf3b5857f21c4" @@ -4023,12 +4147,20 @@ source-map-support@~0.5.12, source-map-support@~0.5.19: buffer-from "^1.0.0" source-map "^0.6.0" +source-map-support@~0.5.20: + version "0.5.20" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.20.tgz#12166089f8f5e5e8c56926b377633392dd2cb6c9" + integrity sha512-n1lZZ8Ve4ksRqizaBQgxXDgKwttHDhyfQjA6YZZn8+AroHbsIz+JjwxQDxbp+7y5OYCI8t1Yk7etjD9CRd2hIw== + dependencies: + buffer-from "^1.0.0" + source-map "^0.6.0" + source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.0, source-map@~0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== -source-map@^0.7.3, source-map@~0.7.2: +source-map@~0.7.2: version "0.7.3" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.7.3.tgz#5302f8169031735226544092e64981f751750383" integrity sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ== @@ -4256,7 +4388,19 @@ tempfile@^2.0.0: temp-dir "^1.0.0" uuid "^3.0.1" -terser-webpack-plugin@5.1.4, terser-webpack-plugin@^5.1.3: +terser-webpack-plugin@5.2.4: + version "5.2.4" + resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-5.2.4.tgz#ad1be7639b1cbe3ea49fab995cbe7224b31747a1" + integrity sha512-E2CkNMN+1cho04YpdANyRrn8CyN4yMy+WdFKZIySFZrGXZxJwJP6PMNGGc/Mcr6qygQHUUqRxnAPmi0M9f00XA== + dependencies: + jest-worker "^27.0.6" + p-limit "^3.1.0" + schema-utils "^3.1.1" + serialize-javascript "^6.0.0" + source-map "^0.6.1" + terser "^5.7.2" + +terser-webpack-plugin@^5.1.3: version "5.1.4" resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-5.1.4.tgz#c369cf8a47aa9922bd0d8a94fe3d3da11a7678a1" integrity sha512-C2WkFwstHDhVEmsmlCxrXUtVklS+Ir1A7twrYzrDrQQOIMOaVAYykaoo/Aq1K0QRkMoY2hhvDQY1cm4jnIMFwA== @@ -4286,6 +4430,15 @@ terser@^5.7.0: source-map "~0.7.2" source-map-support "~0.5.19" +terser@^5.7.2: + version "5.9.0" + resolved "https://registry.yarnpkg.com/terser/-/terser-5.9.0.tgz#47d6e629a522963240f2b55fcaa3c99083d2c351" + integrity sha512-h5hxa23sCdpzcye/7b8YqbE5OwKca/ni0RQz1uRX3tGh8haaGHqcuSqbGRybuAKNdntZ0mDgFNXPJ48xQ2RXKQ== + dependencies: + commander "^2.20.0" + source-map "~0.7.2" + source-map-support "~0.5.20" + text-table@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" @@ -4337,22 +4490,23 @@ trim-repeated@^1.0.0: dependencies: escape-string-regexp "^1.0.2" -ts-loader@9.2.3: - version "9.2.3" - resolved "https://registry.yarnpkg.com/ts-loader/-/ts-loader-9.2.3.tgz#dc3b6362a4d4382493cd4f138d345f419656de68" - integrity sha512-sEyWiU3JMHBL55CIeC4iqJQadI0U70A5af0kvgbNLHVNz2ACztQg0j/9x10bjjIht8WfFYLKfn4L6tkZ+pu+8Q== +ts-loader@9.2.6: + version "9.2.6" + resolved "https://registry.yarnpkg.com/ts-loader/-/ts-loader-9.2.6.tgz#9937c4dd0a1e3dbbb5e433f8102a6601c6615d74" + integrity sha512-QMTC4UFzHmu9wU2VHZEmWWE9cUajjfcdcws+Gh7FhiO+Dy0RnR1bNz0YCHqhI0yRowCE9arVnNxYHqELOy9Hjw== dependencies: chalk "^4.1.0" enhanced-resolve "^5.0.0" micromatch "^4.0.0" semver "^7.3.4" -tsconfig-paths@^3.9.0: - version "3.10.1" - resolved "https://registry.yarnpkg.com/tsconfig-paths/-/tsconfig-paths-3.10.1.tgz#79ae67a68c15289fdf5c51cb74f397522d795ed7" - integrity sha512-rETidPDgCpltxF7MjBZlAFPUHv5aHH2MymyPvh+vEyWAED4Eb/WeMbsnD/JDr4OKPOA1TssDHgIcpTN5Kh0p6Q== +tsconfig-paths@^3.11.0: + version "3.11.0" + resolved "https://registry.yarnpkg.com/tsconfig-paths/-/tsconfig-paths-3.11.0.tgz#954c1fe973da6339c78e06b03ce2e48810b65f36" + integrity sha512-7ecdYDnIdmv639mmDwslG6KQg1Z9STTz1j7Gcz0xa+nshh/gKDAHcPxRbWOsA3SPp0tXP2leTcY9Kw+NAkfZzA== dependencies: - json5 "^2.2.0" + "@types/json5" "^0.0.29" + json5 "^1.0.1" minimist "^1.2.0" strip-bom "^3.0.0" @@ -4397,10 +4551,10 @@ type-fest@^0.20.2: resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.20.2.tgz#1bf207f4b28f91583666cb5fbd327887301cd5f4" integrity sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ== -type-fest@^1.0.1: - version "1.2.2" - resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-1.2.2.tgz#1930bc36b2064f7ab4aa307a6d1b65965199c698" - integrity sha512-pfkPYCcuV0TJoo/jlsUeWNV8rk7uMU6ocnYNvca1Vu+pyKi8Rl8Zo2scPt9O72gCsXIm+dMxOOWuA3VFDSdzWA== +type-fest@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-1.4.0.tgz#e9fb813fe3bf1744ec359d55d1affefa76f14be1" + integrity sha512-yGSza74xk0UG8k+pLh5oeoYirvIiWo5t0/o3zHHAO2tRDiZcxWP7fywNlXhqb6/r6sWvwi+RsyQMWhVLe4BVuA== typed-rest-client@^1.8.4: version "1.8.4" @@ -4411,10 +4565,10 @@ typed-rest-client@^1.8.4: tunnel "0.0.6" underscore "^1.12.1" -typescript@4.4.0-beta: - version "4.4.0-beta" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.4.0-beta.tgz#a5b8a3a0d260fa5ce84daa3ab58f7102ad19a655" - integrity sha512-qMxA8NzN3igwX8Mii7MXGNW+YeFAkUKyKg+x4F1CCFsO36LqISf1EXXSOLDuRIdGjdVvV53grRxfHjOW65YfMA== +typescript@4.4.3: + version "4.4.3" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.4.3.tgz#bdc5407caa2b109efd4f82fe130656f977a29324" + integrity sha512-4xfscpisVgqqDfPaJo5vkd+Qd/ItkoagnHpufr+i2QCHBsNYp+G7UAoyFl8aPtx879u38wPV65rZ8qbGZijalA== typical@^5.2.0: version "5.2.0" @@ -4518,10 +4672,10 @@ validate-npm-package-license@^3.0.1: spdx-correct "^3.0.0" spdx-expression-parse "^3.0.0" -vsce@1.95.1: - version "1.95.1" - resolved "https://registry.yarnpkg.com/vsce/-/vsce-1.95.1.tgz#95b465c3188508eabc8af72f3e20b632dd71c0da" - integrity sha512-2v8g3ZtZkaOTscRjjCAtM3Au6YYWJtg9UNt1iyyWko7ZHejbt5raClcNzQ7/WYVLYhYHc+otHQifV0gCBREgNg== +vsce@1.100.1: + version "1.100.1" + resolved "https://registry.yarnpkg.com/vsce/-/vsce-1.100.1.tgz#6ea04464abe3ccf3a5a8a05de25692f1780b1104" + integrity sha512-1VjLyse5g6e2eQ6jUpslu7IDq44velwF8Jy8s7ePdwGNuG8EzfmaOfVyig3ZSMJ0l8DiJmZllx5bRAB4RMdnHg== dependencies: azure-devops-node-api "^11.0.1" chalk "^2.4.2" @@ -4529,6 +4683,7 @@ vsce@1.95.1: commander "^6.1.0" denodeify "^1.2.1" glob "^7.0.6" + hosted-git-info "^4.0.2" leven "^3.1.0" lodash "^4.17.15" markdown-it "^10.0.0" @@ -4541,6 +4696,7 @@ vsce@1.95.1: tmp "^0.2.1" typed-rest-client "^1.8.4" url-join "^1.1.0" + xml2js "^0.4.23" yauzl "^2.3.1" yazl "^2.2.2" @@ -4598,7 +4754,7 @@ webpack-merge@^4.2.2: dependencies: lodash "^4.17.15" -webpack-sources@^2.2.0, webpack-sources@^2.3.0: +webpack-sources@^2.2.0: version "2.3.0" resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-2.3.0.tgz#9ed2de69b25143a4c18847586ad9eccb19278cfa" integrity sha512-WyOdtwSvOML1kbgtXbTDnEW0jkJ7hZr/bDByIwszhWd/4XX1A3XMkrbFMsuH4+/MfLlZCUzlAdg4r7jaGKEIgQ== @@ -4606,10 +4762,15 @@ webpack-sources@^2.2.0, webpack-sources@^2.3.0: source-list-map "^2.0.1" source-map "^0.6.1" -webpack@5.44.0: - version "5.44.0" - resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.44.0.tgz#97b13a02bd79fb71ac6301ce697920660fa214a1" - integrity sha512-I1S1w4QLoKmH19pX6YhYN0NiSXaWY8Ou00oA+aMcr9IUGeF5azns+IKBkfoAAG9Bu5zOIzZt/mN35OffBya8AQ== +webpack-sources@^3.2.0: + version "3.2.1" + resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-3.2.1.tgz#251a7d9720d75ada1469ca07dbb62f3641a05b6d" + integrity sha512-t6BMVLQ0AkjBOoRTZgqrWm7xbXMBzD+XDq2EZ96+vMfn3qKgsvdXZhbPZ4ElUOpdv4u+iiGe+w3+J75iy/bYGA== + +webpack@5.56.0: + version "5.56.0" + resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.56.0.tgz#91a04de09c85765002818678538c319b6e461324" + integrity sha512-pJ7esw2AGkpZL0jqsEAKnDEfRZdrc9NVjAWA+d1mFkwj68ng9VQ6+Wnrl+kS5dlDHvrat5ASK5vd7wp6I7f53Q== dependencies: "@types/eslint-scope" "^3.7.0" "@types/estree" "^0.0.50" @@ -4617,10 +4778,11 @@ webpack@5.44.0: "@webassemblyjs/wasm-edit" "1.11.1" "@webassemblyjs/wasm-parser" "1.11.1" acorn "^8.4.1" + acorn-import-assertions "^1.7.6" browserslist "^4.14.5" chrome-trace-event "^1.0.2" - enhanced-resolve "^5.8.0" - es-module-lexer "^0.7.1" + enhanced-resolve "^5.8.3" + es-module-lexer "^0.9.0" eslint-scope "5.1.1" events "^3.2.0" glob-to-regexp "^0.4.1" @@ -4629,11 +4791,11 @@ webpack@5.44.0: loader-runner "^4.2.0" mime-types "^2.1.27" neo-async "^2.6.2" - schema-utils "^3.0.0" + schema-utils "^3.1.0" tapable "^2.1.1" terser-webpack-plugin "^5.1.3" watchpack "^2.2.0" - webpack-sources "^2.3.0" + webpack-sources "^3.2.0" which-boxed-primitive@^1.0.2: version "1.0.2" @@ -4683,6 +4845,19 @@ ws@^7.3.1: resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.3.tgz#160835b63c7d97bfab418fc1b8a9fced2ac01a74" integrity sha512-kQ/dHIzuLrS6Je9+uv81ueZomEwH0qVYstcAQ4/Z93K8zeko9gtAbttJWzoC5ukqXY1PpoouV3+VSOqEAFt5wg== +xml2js@^0.4.23: + version "0.4.23" + resolved "https://registry.yarnpkg.com/xml2js/-/xml2js-0.4.23.tgz#a0c69516752421eb2ac758ee4d4ccf58843eac66" + integrity sha512-ySPiMjM0+pLDftHgXY4By0uswI3SPKLDw/i3UXbnO8M/p28zqexCUoPmQFrYD+/1BzhGJSs2i1ERWKJAtiLrug== + dependencies: + sax ">=0.6.0" + xmlbuilder "~11.0.0" + +xmlbuilder@~11.0.0: + version "11.0.1" + resolved "https://registry.yarnpkg.com/xmlbuilder/-/xmlbuilder-11.0.1.tgz#be9bae1c8a046e76b31127726347d0ad7002beb3" + integrity sha512-fDlsI/kFEx7gLvbecc0/ohLG50fugQp8ryHzMTuW9vSa1GJ0XYWKnhsUx7oie3G98+r56aTQIUB4kht42R3JvA== + xtend@^4.0.0: version "4.0.2" resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54"