Many WFC related improvements (WIP)

* Update systeminformation to 5.x
* More work on WFC display of basic stats -- nearly complete
* Disable idle timeout when on WFC
This commit is contained in:
Bryan Ashby 2022-05-01 12:41:20 -06:00
parent 193c203a05
commit dd7d24f22e
No known key found for this signature in database
GPG Key ID: C2C1B501E4EFD994
9 changed files with 39 additions and 18 deletions

View File

@ -2,11 +2,16 @@
This document attempts to track **major** changes and additions in ENiGMA½. For details, see GitHub.
## 0.0.13-beta
* Removed terminal `cursor position reports` from most locations in the code. This should greatly increase the number of terminal programs that work with Enigma 1/2. For more information, see [Issue #222](https://github.com/NuSkooler/enigma-bbs/issues/222). This may also resolve other issues, such as [Issue #365](https://github.com/NuSkooler/enigma-bbs/issues/365), and [Issue #320](https://github.com/NuSkooler/enigma-bbs/issues/320). Anyone that previously had terminal incompatibilities please re-check and let us know!
* Removed terminal `cursor position reports` from most locations in the code. This should greatly increase the number of terminal programs that work with ENiGMA½. For more information, see [Issue #222](https://github.com/NuSkooler/enigma-bbs/issues/222). This may also resolve other issues, such as [Issue #365](https://github.com/NuSkooler/enigma-bbs/issues/365), and [Issue #320](https://github.com/NuSkooler/enigma-bbs/issues/320). Anyone that previously had terminal incompatibilities please re-check and let us know!
* Bumped up the minimum [Node.js](https://nodejs.org/en/) version to V14. This will allow more expressive Javascript programming syntax with ECMAScript 2020 to improve the development experience.
* Added new configuration options for `term.checkUtf8Encoding`, `term.checkAnsiHomePostion`, `term.cp437TermList`, and `term.utf8TermList`. More information on these options is available in `UPGRADE.md`
* New Waiting For Caller (WFC) support via the `wfc.js` module.
* Many new system statistics available via the StatLog such as current and average load, memory, etc.
* Many new MCI codes: `MB`, `MF`, `LA`, `CL`, `UU`, `FT`, `DD`, `FB`, `DB`, `LC`, `LT`, `LD`, and more. See [MCI](./docs/art/mci.md).
* SyncTERM style font support detection.
* Many additional backward-compatible bug fixes since the first release of 0.0.12-beta. See the [project repository](https://github.com/NuSkooler/enigma-bbs) for more information.
## 0.0.12-beta
* The `master` branch has become mainline. What this means to users is `git pull` will always give you the latest and greatest. Make sure to read [Updating](./docs/admin/updating.md) and keep an eye on `WHATSNEW.md` (this file) and [UPGRADE](UPGRADE.md)! See also [ticket #276](https://github.com/NuSkooler/enigma-bbs/issues/276).
* Development now occurs against [Node.js 14 LTS](https://github.com/nodejs/node/blob/master/doc/changelogs/CHANGELOG_V14.md).

View File

@ -249,13 +249,21 @@
mainMenuWaitingForCaller: {
config: {
nowDateTimeFormat: "|00|11dddd|08, |11MMMM Do YYYY |08/ |11h|08:|11mm|08:|11ss|03a"
lastLoginDateTimeFormat: "|00|11ddd h|08:|11mm|03a"
lastLoginDateTimeFormat: "|00|10ddd hh|08:|10mm|02a"
mainInfoFormat10: "|00|11{now} {currentUserName} |08- |03mail|08: "
mainInfoFormat11: "|00|10{callsToday:>5}"
mainInfoFormat12: "|00|10{postsToday:>5}"
mainInfoFormat19: "|00|10{lastLoginUserName:<19} |02{lastLogin}"
mainInfoFormat18: "|00|10{lastLoginUserName:<27} |02{lastLogin}"
mainInfoFormat19: "|00|10{freeMemoryBytes!sizeWithoutAbbr} |02{freeMemoryBytes!sizeAbbr} free |08/ |10{totalMemoryBytes!sizeWithoutAbbr} |02{totalMemoryBytes!sizeAbbr}"
mainInfoFormat20: "|00|10{systemCurrentLoad} |02% |08/ |10{systemAvgLoad} |02load avg|08."
mainInfoFormat21: "|00|10{processUptimeSeconds!durationSeconds}"
mainInfoFormat23: "|00|10{totalCalls:>5}"
mainInfoFormat24: "|00|10{totalPosts:>5}"
mainInfoFormat22: "|00|10{totalFiles} |08/ |10{totalFileBytes!sizeWithoutAbbr} |02{totalFileBytes!sizeAbbr}"
quickLogLevel: info
quickLogLevelIndicators: {
@ -269,15 +277,17 @@
}
0: {
mci: {
TL19: { width: 23 }
TL20: { width: 23 }
VM1: {
height: 5
widht: 37
itemFormat: "|00|11{node:<3.2} |10{userName:>13} |08> |04{action:<14.13} |14{serverName}"
itemFormat: "|00|11{node:<3.2} |10{userName:>13} |08> |02{action:<14.13} |14{serverName}"
}
VM2: {
height: 5
width: 73
itemFormat: "{levelIndicator} |15{timestamp} |07{message}"
itemFormat: "{levelIndicator} |15{timestamp} |07{message:<51.50}"
}
}
}

View File

@ -366,7 +366,7 @@ class StatLog {
const basicSysInfo = {
mem : 'total, free',
currentLoad : 'avgload, currentLoad',
currentLoad : 'avgLoad, currentLoad',
};
SysInfo.get(basicSysInfo)
@ -380,8 +380,8 @@ class StatLog {
const loadStats = {
// Not avail on BSD, yet.
average : _.get(sysInfo, 'currentLoad.avgload', 0),
current : _.get(sysInfo, 'currentLoad.currentLoad', 0),
average : _.get(sysInfo, 'currentLoad.avgLoad', 0).toFixed(2),
current : _.get(sysInfo, 'currentLoad.currentLoad', 0).toFixed(2),
};
this.setNonPersistentSystemStat(SysProps.SystemLoadStats, loadStats);

View File

@ -120,7 +120,7 @@ View.prototype.setPosition = function(pos) {
//
// Allow the following forms: [row, col], { row : r, col : c }, or (row, col)
//
if(util.isArray(pos)) {
if(Array.isArray(pos)) {
this.position.row = pos[0];
this.position.col = pos[1];
} else if(_.isNumber(pos.row) && _.isNumber(pos.col)) {
@ -259,7 +259,7 @@ View.prototype.setFocusProperty = function(focused) {
};
View.prototype.setFocus = function(focused) {
// Call separate method to differentiate between a value set as a
// Call separate method to differentiate between a value set as a
// property vs focus programmatically called.
this.setFocusProperty(focused);
this.restoreCursor();

View File

@ -99,12 +99,18 @@ exports.getModule = class WaitingForCallerModule extends MenuModule {
});
}
enter() {
this.client.stopIdleMonitor();
super.enter();
}
leave() {
_.remove(Log.log.streams, stream => {
return stream.name === 'wfc-ringbuffer';
});
this._stopRefreshing();
this.client.startIdleMonitor();
super.leave();
}

View File

@ -97,8 +97,8 @@ There are many predefined MCI codes that can be used anywhere on the system (pla
| `DB` | Total download amount *today* (formatted to appropriate bytes/megs/etc. ) |
| `MB` | System memory |
| `MF` | System _free_ memory |
| `LA` | System load average (e.g. 0.25)<br>(Not available for all platforms) |
| `CL` | System current load percentage<br>(Not available for all platforms) |
| `LA` | System load average (e.g. 0.25)<br>(May not be available on some platforms) |
| `CL` | System current load percentage<br>(May not be available on some platforms) |
| `UU` | System uptime in friendly format |
| `LC` | Last caller to the system (username) |
| `LT` | Time of last caller |
@ -135,7 +135,7 @@ a Vertical Menu (`%VM`): Old-school BBSers may recognize this as a lightbar menu
| `BT` | Button | A button | ...it's a button. See [Button](views/button_view.md) |
| `VM` | Vertical Menu | A vertical menu | AKA a vertical lightbar; Useful for lists. See [Vertical Menu](views/vertical_menu_view.md) |
| `HM` | Horizontal Menu | A horizontal menu | AKA a horizontal lightbar. See [Horizontal Menu](views/horizontal_menu_view.md) |
| `FM` | Full Menu | A menu that can go both vertical and horizontal. | See [Full Menu](views/full_menu_view.md) |
| `FM` | Full Menu | A menu that can go both vertical and horizontal. | See [Full Menu](views/full_menu_view.md) |
| `SM` | Spinner Menu | A spinner input control | Select *one* from multiple options. See [Spinner Menu](views/spinner_menu_view.md) |
| `TM` | Toggle Menu | A toggle menu | Commonly used for Yes/No style input. See [Toggle Menu](views/toggle_menu_view.md)|
| `PL` | Predefined Label | Show environment information | See [Predefined Label](views/predefined_label_view.md)|

View File

@ -59,7 +59,7 @@
"uuid-parse": "1.1.0",
"ws": "7.4.3",
"yazl": "^2.5.1",
"systeminformation" : "^4.27.5"
"systeminformation" : "^5.11.14"
},
"devDependencies": {
"eslint": "^8.13.0"

View File

@ -1821,10 +1821,10 @@ supports-color@^7.1.0:
dependencies:
has-flag "^4.0.0"
systeminformation@^4.27.5:
version "4.34.23"
resolved "https://registry.yarnpkg.com/systeminformation/-/systeminformation-4.34.23.tgz#54c54ced5adc49c27cda953b73c0819ed56edd45"
integrity sha512-33+lQwlLxXoxy0o9WLOgw8OjbXeS3Jv+pSl+nxKc2AOClBI28HsdRPpH0u9Xa9OVjHLT9vonnOMw1ug7YXI0dA==
systeminformation@^5.11.14:
version "5.11.14"
resolved "https://registry.yarnpkg.com/systeminformation/-/systeminformation-5.11.14.tgz#21fcb6f05d33e17d69c236b9c1b3d9c53d1d2b3a"
integrity sha512-m8CJx3fIhKohanB0ExTk5q53uI1J0g5B09p77kU+KxnxRVpADVqTAwCg1PFelqKsj4LHd+qmVnumb511Hg4xow==
tar@^4:
version "4.4.19"