|
| 1 | +Make sourcemaps self-hosted |
| 2 | + |
| 3 | +Normally source maps get removed as part of the build process so prevent that |
| 4 | +from happening. Also avoid using the windows.net host since obviously we can |
| 5 | +not host our source maps there and want them to be self-hosted even if we could. |
| 6 | + |
| 7 | +To test try debugging/browsing the source of a build in a browser. |
| 8 | + |
| 9 | +Index: code-server/lib/vscode/build/gulpfile.reh.js |
| 10 | +=================================================================== |
| 11 | +--- code-server.orig/lib/vscode/build/gulpfile.reh.js |
| 12 | ++++ code-server/lib/vscode/build/gulpfile.reh.js |
| 13 | +@@ -195,8 +195,7 @@ function packageTask(type, platform, arc |
| 14 | + |
| 15 | + const src = gulp.src(sourceFolderName + '/**', { base: '.' }) |
| 16 | + .pipe(rename(function (path) { path.dirname = path.dirname.replace(new RegExp('^' + sourceFolderName), 'out'); })) |
| 17 | +- .pipe(util.setExecutableBit(['**/*.sh'])) |
| 18 | +- .pipe(filter(['**', '!**/*.js.map'])); |
| 19 | ++ .pipe(util.setExecutableBit(['**/*.sh'])); |
| 20 | + |
| 21 | + const workspaceExtensionPoints = ['debuggers', 'jsonValidation']; |
| 22 | + const isUIExtension = (manifest) => { |
| 23 | +@@ -363,7 +362,7 @@ function packageTask(type, platform, arc |
| 24 | + const minifyTask = task.define(`minify-vscode-${type}`, task.series( |
| 25 | + optimizeTask, |
| 26 | + util.rimraf(`out-vscode-${type}-min`), |
| 27 | +- common.minifyTask(`out-vscode-${type}`, `https://ticino.blob.core.windows.net/sourcemaps/${commit}/core`) |
| 28 | ++ common.minifyTask(`out-vscode-${type}`, '') |
| 29 | + )); |
| 30 | + gulp.task(minifyTask); |
| 31 | + |
0 commit comments