mirror of
https://github.com/microsoft/vscode.git
synced 2026-05-08 09:08:48 +01:00
leave upload path as /dist/
This commit is contained in:
@@ -60,7 +60,7 @@ function fromLocal(extensionPath, sourceMappingURLBase) {
|
|||||||
if (sourceMappingURLBase) {
|
if (sourceMappingURLBase) {
|
||||||
var contents = data.contents.toString('utf8');
|
var contents = data.contents.toString('utf8');
|
||||||
data.contents = Buffer.from(contents.replace(/\n\/\/# sourceMappingURL=(.*)$/gm, function (_m, g1) {
|
data.contents = Buffer.from(contents.replace(/\n\/\/# sourceMappingURL=(.*)$/gm, function (_m, g1) {
|
||||||
return "\n//# sourceMappingURL=" + sourceMappingURLBase + "/extensions/" + path.basename(extensionPath) + "/out/" + g1;
|
return "\n//# sourceMappingURL=" + sourceMappingURLBase + "/extensions/" + path.basename(extensionPath) + "/dist/" + g1;
|
||||||
}), 'utf8');
|
}), 'utf8');
|
||||||
if (/\.js\.map$/.test(data.path)) {
|
if (/\.js\.map$/.test(data.path)) {
|
||||||
if (!fs.existsSync(path.dirname(data.path))) {
|
if (!fs.existsSync(path.dirname(data.path))) {
|
||||||
|
|||||||
@@ -66,7 +66,7 @@ export function fromLocal(extensionPath: string, sourceMappingURLBase?: string):
|
|||||||
if (sourceMappingURLBase) {
|
if (sourceMappingURLBase) {
|
||||||
const contents = (<Buffer>data.contents).toString('utf8');
|
const contents = (<Buffer>data.contents).toString('utf8');
|
||||||
data.contents = Buffer.from(contents.replace(/\n\/\/# sourceMappingURL=(.*)$/gm, function (_m, g1) {
|
data.contents = Buffer.from(contents.replace(/\n\/\/# sourceMappingURL=(.*)$/gm, function (_m, g1) {
|
||||||
return `\n//# sourceMappingURL=${sourceMappingURLBase}/extensions/${path.basename(extensionPath)}/out/${g1}`;
|
return `\n//# sourceMappingURL=${sourceMappingURLBase}/extensions/${path.basename(extensionPath)}/dist/${g1}`;
|
||||||
}), 'utf8');
|
}), 'utf8');
|
||||||
|
|
||||||
if (/\.js\.map$/.test(data.path)) {
|
if (/\.js\.map$/.test(data.path)) {
|
||||||
@@ -75,7 +75,6 @@ export function fromLocal(extensionPath: string, sourceMappingURLBase?: string):
|
|||||||
}
|
}
|
||||||
fs.writeFileSync(data.path, data.contents);
|
fs.writeFileSync(data.path, data.contents);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
this.emit('data', data);
|
this.emit('data', data);
|
||||||
}))
|
}))
|
||||||
|
|||||||
Reference in New Issue
Block a user