mirror of
https://github.com/microsoft/monaco-editor.git
synced 2025-12-22 16:15:41 +01:00
Fixes Microsoft/monaco-editor#204: Do what monaco-html does to resolve vscode-uri
This commit is contained in:
parent
737e0f1650
commit
59d79a9a2b
2 changed files with 22 additions and 1 deletions
3
.vscode/settings.json
vendored
3
.vscode/settings.json
vendored
|
|
@ -5,5 +5,6 @@
|
|||
"**/node_modules": true,
|
||||
"**/release": true,
|
||||
"**/out": true
|
||||
}
|
||||
},
|
||||
"typescript.tsdk": "./node_modules/typescript/lib"
|
||||
}
|
||||
20
gulpfile.js
20
gulpfile.js
|
|
@ -41,6 +41,22 @@ gulp.task('release', ['clean-release','compile'], function() {
|
|||
jsoncLocation = oldJsconcLocation;
|
||||
}
|
||||
|
||||
function getDependencyLocation(name, libLocation, container) {
|
||||
var location = __dirname + '/node_modules/' + name + '/' + libLocation;
|
||||
if (!fs.existsSync(location)) {
|
||||
var oldLocation = __dirname + '/node_modules/' + container + '/node_modules/' + name + '/' + libLocation;
|
||||
if (!fs.existsSync(oldLocation)) {
|
||||
console.error('Unable to find ' + name + ' node module at ' + location + ' or ' + oldLocation);
|
||||
return;
|
||||
}
|
||||
return oldLocation;
|
||||
}
|
||||
return location;
|
||||
}
|
||||
|
||||
var uriLocation = getDependencyLocation('vscode-uri', 'lib', 'vscode-html-languageservice');
|
||||
|
||||
|
||||
function bundleOne(moduleId, exclude) {
|
||||
|
||||
|
||||
|
|
@ -64,6 +80,10 @@ gulp.task('release', ['clean-release','compile'], function() {
|
|||
name: 'jsonc-parser',
|
||||
location: jsoncLocation,
|
||||
main: 'main'
|
||||
}, {
|
||||
name: 'vscode-uri',
|
||||
location: uriLocation,
|
||||
main: 'index'
|
||||
}, {
|
||||
name: 'vscode-nls',
|
||||
location: __dirname + '/out/fillers',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue