Some small changes and fixes

This commit is contained in:
WolverinDEV 2018-10-09 13:40:38 +02:00
parent 55b3f2f934
commit 26606605fb
5 changed files with 22 additions and 9 deletions

View file

@ -6,6 +6,7 @@
"directories": {},
"scripts": {
"compile-sass": "sass --update .:.",
"build-worker": "tsc -p shared/js/workers/tsconfig_worker_codec.json",
"build-web-app": "tsc -p tsconfig/tsconfig_web_app.json",
"build-web-app-release": "tsc -p tsconfig/tsconfig_web_app_packaged.json",
"build-web-preload": "tsc -p tsconfig/tsconfig_web_preload.json"

View file

@ -54,7 +54,7 @@ echo "PATH=\"$PATH:`pwd`\"" >> ~/.bashrc
```
# Build TeaWeb
## Close and initialize project
## Clone and initialize project
```bash
git clone https://github.com/TeaSpeak/TeaWeb
git submodule update --init --recursive --remote --checkout
@ -62,10 +62,16 @@ git submodule update --init --recursive --remote --checkout
## Build native libraries
### Opus
#### Native loader
```bash
cd asm
./make_opus.sh
```
#### Javascript loader
```bash
npm run build-worker
```
### Tommath
```bash
@ -90,7 +96,7 @@ emcmake cmake ..
emmake make -j 4
```
# Now generate project structure
## Now generate project structure
```bash
npm install --only=dev
./scripts/build_web_release.sh

View file

@ -331,15 +331,23 @@ class HandshakeHandler {
}
private handshake_finished() {
this.connection.sendCommand("clientinit", {
let data = {
//TODO variables!
client_nickname: this.name ? this.name : this.identity.name(),
client_platform: navigator.platform,
client_version: navigator.userAgent,
client_server_password: this.server_password
//client_browser_engine: navigator.product
}).catch(error => {
client_server_password: this.server_password,
client_browser_engine: navigator.product
};
if(window.require) {
const os = require('os');
data.client_version = "TeaClient"; //FIXME get version
data.client_platform = os.platform() + " (" + os.arch() + ")";
}
this.connection.sendCommand("clientinit", data).catch(error => {
this.connection.disconnect();
if(error instanceof CommandResult) {
if(error.id == 1028) {

View file

@ -244,7 +244,7 @@ function loadSide() {
if(window.require !== undefined) {
console.log("Loading node specific things");
const remote = require('electron').remote;
module.paths.push(remote.app.getAppPath());
module.paths.push(remote.app.getAppPath() + "/app");
module.paths.push(remote.getGlobal("browser-root") + "js/");
window.$ = require("assets/jquery.min.js");
require("native/loader_adapter.js");

View file

@ -1,2 +0,0 @@
#!/usr/bin/env bash
/usr/local/bin/tsc -p tsconfig_worker_codec.json