forked from eclipse-theia/theia
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Anton Kosiakov <anton.kosyakov@typefox.io>
- Loading branch information
Showing
26 changed files
with
330 additions
and
391 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
/* | ||
* Copyright (C) 2017 TypeFox and others. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 | ||
*/ | ||
|
||
// @ts-check | ||
require('reflect-metadata'); | ||
const path = require('path'); | ||
const express = require('express'); | ||
const { Container, injectable } = require('inversify'); | ||
|
||
const { BackendApplication, backendApplicationModule, loggerBackendModule } = require('theia-core/lib/application/node'); | ||
const { messagingBackendModule } = require("theia-core/lib/messaging/node"); | ||
|
||
const fileSystemBackendModule = require("theia-core/lib/filesystem/node/filesystem-backend-module").default; | ||
const workspaceBackendModule = require("theia-core/lib/workspace/node/workspace-backend-module").default; | ||
const terminalBackendModule = require('theia-core/lib/terminal/node/terminal-backend-module').default; | ||
const languagesBackendModule = require('theia-core/lib/languages/node/languages-backend-module').default; | ||
const javaBackendModule = require('theia-core/lib/java/node/java-backend-module').default; | ||
const pythonBackendModule = require('theia-core/lib/python/node/python-backend-module').default; | ||
const cppBackendModule = require('theia-core/lib/cpp/node/cpp-backend-module').default; | ||
|
||
const container = new Container(); | ||
container.load(backendApplicationModule); | ||
container.load(messagingBackendModule); | ||
container.load(loggerBackendModule); | ||
|
||
container.load(fileSystemBackendModule); | ||
container.load(workspaceBackendModule); | ||
container.load(languagesBackendModule); | ||
container.load(terminalBackendModule); | ||
container.load(javaBackendModule); | ||
container.load(pythonBackendModule); | ||
container.load(cppBackendModule); | ||
|
||
const application = container.get(BackendApplication); | ||
application.use(express.static(path.join(__dirname, '../../lib'), { | ||
index: 'index.html' | ||
})); | ||
application.start(); |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
/* | ||
* Copyright (C) 2017 TypeFox and others. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 | ||
*/ | ||
|
||
// @ts-check | ||
import { Container } from 'inversify'; | ||
import { FrontendApplication, frontendApplicationModule } from 'theia-core/lib/application/browser'; | ||
import { messagingFrontendModule } from 'theia-core/lib/messaging/browser'; | ||
import { loggerFrontendModule } from 'theia-core/lib/application/browser'; | ||
|
||
const container = new Container(); | ||
container.load(frontendApplicationModule); | ||
container.load(messagingFrontendModule); | ||
container.load(loggerFrontendModule); | ||
|
||
function load(raw) { | ||
return Promise.resolve(raw.default).then(module => | ||
container.load(module) | ||
) | ||
} | ||
|
||
function start() { | ||
const application = container.get(FrontendApplication); | ||
application.start(); | ||
} | ||
|
||
import('theia-core/lib/application/browser/menu/browser-menu-module').then(load) | ||
.then(function () { return import('theia-core/lib/application/browser/clipboard/browser-clipboard-module').then(load) }) | ||
.then(function () { return import('theia-core/lib/filesystem/browser/filesystem-frontend-module').then(load) }) | ||
.then(function () { return import('theia-core/lib/workspace/browser/workspace-frontend-module').then(load) }) | ||
.then(function () { return import('theia-core/lib/navigator/browser/navigator-frontend-module').then(load) }) | ||
.then(function () { return import('theia-core/lib/terminal/browser/terminal-frontend-module').then(load) }) | ||
.then(function () { return import('theia-core/lib/editor/browser/editor-frontend-module').then(load) }) | ||
.then(function () { return import('theia-core/lib/monaco/browser/monaco-browser-module').then(load) }) | ||
.then(function () { return import('theia-core/lib/languages/browser/languages-frontend-module').then(load) }) | ||
.then(function () { return import('theia-core/lib/java/browser/java-frontend-module').then(load) }) | ||
.then(function () { return import('theia-core/lib/python/browser/python-frontend-module').then(load) }) | ||
.then(function () { return import('theia-core/lib/cpp/browser/cpp-frontend-module').then(load) }) | ||
.then(start); |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.