Add patch for custom extensions gallery
Extend product.ts to accept environment variables for custom extensions gallery URLs
This commit is contained in:
parent
5ffd1aa4b0
commit
dad2a98413
1 changed files with 28 additions and 0 deletions
28
patches/custom-extensions-gallery.patch
Normal file
28
patches/custom-extensions-gallery.patch
Normal file
|
@ -0,0 +1,28 @@
|
|||
diff --git a/src/vs/platform/product/common/product.ts b/src/vs/platform/product/common/product.ts
|
||||
index 2bea85740c..d0e9da036c 100644
|
||||
--- a/src/vs/platform/product/common/product.ts
|
||||
+++ b/src/vs/platform/product/common/product.ts
|
||||
@@ -57,6 +57,23 @@ else {
|
||||
});
|
||||
}
|
||||
|
||||
+ // Set user-defined extension gallery
|
||||
+ if (
|
||||
+ env['VSCODIUM_EXTENSIONS_GALLERY_SERVICE_URL']
|
||||
+ || env['VSCODIUM_EXTENSIONS_GALLERY_ITEM_URL']
|
||||
+ || env['VSCODIUM_EXTENSIONS_GALLERY_CONTROL_URL']
|
||||
+ || env['VSCODIUM_EXTENSIONS_GALLERY_RECOMMENDATIONS_URL']
|
||||
+ ) {
|
||||
+ Object.assign(product, {
|
||||
+ extensionsGallery: {
|
||||
+ serviceUrl: env['VSCODIUM_EXTENSIONS_GALLERY_SERVICE_URL'],
|
||||
+ itemUrl: env['VSCODIUM_EXTENSIONS_GALLERY_ITEM_URL'],
|
||||
+ controlUrl: env['VSCODIUM_EXTENSIONS_GALLERY_CONTROL_URL'],
|
||||
+ recommendationsUrl: env['VSCODIUM_EXTENSIONS_GALLERY_RECOMMENDATIONS_URL']
|
||||
+ }
|
||||
+ })
|
||||
+ }
|
||||
+
|
||||
Object.assign(product, {
|
||||
version: pkg.version
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue