Compare commits
No commits in common. "5c5430314ab08fd33f262fa930ddfd26a0c14963" and "5821dd31f95b8f8e08f53f03c4c6a73caf90b297" have entirely different histories.
5c5430314a
...
5821dd31f9
10
README.md
10
README.md
|
@ -21,14 +21,20 @@ In addition, it sets up the mongo deamon to start up automatically with the syst
|
|||
|
||||
#### Setup for Production
|
||||
|
||||
**NOTE:** It his highly recommended **not** to run the following steps as _root_ user!
|
||||
**NOTE:** It his highly recommended not to run the following steps as _root_ user!
|
||||
|
||||
Before triggering the environment execution run
|
||||
|
||||
npm install
|
||||
|
||||
inside the main folder, to process all needed npm package installations for the program execution.
|
||||
|
||||
For production setup run the script, described in _Setup for development_, adding the parameter `prod`
|
||||
|
||||
./docs/opt-cc-environment/3rd-party-install.sh prod
|
||||
|
||||
This adds the [`pm2` process manager](http://pm2.keymetrics.io/) to be installed and start the _opt-cc_ server as `pm2` process.
|
||||
Run the `sudo` command printed as last output to configure the `pm2` process for automatic start on the system.
|
||||
Run the `sudo` command printed as last output to configure the `pm2` process for automatic start on the system, as the current user.
|
||||
|
||||
## Development
|
||||
|
||||
|
|
|
@ -64,15 +64,13 @@ const parseWarLog = (lineArray, war) => {
|
|||
const budg = line.split(WHITESPACE);
|
||||
if (line.includes('Startbudget')) {
|
||||
stats.war['budgetBlufor'] = transformMoneyString(budg[9]);
|
||||
stats.war['budgetOpfor'] = transformMoneyString(budg[12].slice(0, -1));
|
||||
|
||||
stats.war['budgetOpfor'] = transformMoneyString(budg[12].slice(0,-1));
|
||||
// this date needs to be assigned in first place !important
|
||||
const dateString = budg[0].slice(0, -1).split('/').map(s => parseInt(s));
|
||||
stats.war.date = new Date(dateString[0], dateString[1] - 1, dateString[2]);
|
||||
|
||||
const dateString = budg[0].slice(0,-1).split('/');
|
||||
stats.war.date = new Date(dateString[0], dateString[1], dateString[2])
|
||||
} else if (line.includes('Endbudget')) {
|
||||
stats.war['endBudgetBlufor'] = transformMoneyString(budg[9].substr(1));
|
||||
stats.war['endBudgetOpfor'] = transformMoneyString(budg[12].slice(0, -1));
|
||||
stats.war['endBudgetOpfor'] = transformMoneyString(budg[12].slice(0,-1));
|
||||
stats.war.endDate = getFullTimeDate(war.date, budg[5]);
|
||||
} else {
|
||||
stats.budget.push(getBudgetEntry(budg, war._id, war.date));
|
||||
|
@ -119,7 +117,7 @@ const parseWarLog = (lineArray, war) => {
|
|||
*/
|
||||
else if (line.includes('(Respawn)')) {
|
||||
const resp = line.split(WHITESPACE);
|
||||
const playerName = line.substring(line.lastIndexOf('Spieler:') + 9, line.lastIndexOf('- Kosten') - 1);
|
||||
const playerName = line.substring(line.lastIndexOf('Spieler:') + 9, line.lastIndexOf('- Kosten') -1);
|
||||
stats.respawn.push(getRespawnEntry(resp, playerName, war._id, war.date));
|
||||
}
|
||||
|
||||
|
|
|
@ -30,6 +30,9 @@ export class AppComponent {
|
|||
}
|
||||
if (event instanceof NavigationEnd) {
|
||||
this.loading = false;
|
||||
if (router.url.includes(RouteConfig.overviewPath)) {
|
||||
window.scrollTo({left: 0, top: 0, behavior: 'smooth'});
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue