Commit Graph

20 Commits

Author SHA1 Message Date
Mia
b11177d530
Migrate to esbuild for compilation (#9203) 2022-12-22 15:19:29 -06:00
Annika
055a01ab89 Modlog: Minor fixes from smogtours conversion 2021-09-06 17:54:30 -04:00
Mia
7811795344
Handle new TypeScript version (#8449)
Co-authored-by: Guangcong Luo <guangcongluo@gmail.com>
2021-08-30 20:11:44 -07:00
Annika
633e061067 Modlog: Remove text logging code 2021-08-09 14:06:14 -07:00
Annika
bcbe100c41
Modlog: Use SQLite for searches (#8004) 2021-07-23 13:47:49 -07:00
Annika
74295cf506 Modlog Converter: Improve modernization
This now reaches 99.9% success rate on logs from January 2018-May 2021, and 94.6% success on logs from November 2014-May 2021. (Assuming one defines "success" as "modernizing the modlog entry without just spitting out an OLD MODLOG: entry".)
2021-07-18 21:07:29 -07:00
Annika
7bd70f8266 Modlog Converter: Fix issues with ts-node 2021-07-18 18:16:41 -07:00
Annika
33145f3fc8 Modlog Converter: Default to 0 if no time is found
This makes it clearer that no time was found, since PS didn't exist in 1970.
2021-07-17 21:21:32 -07:00
Annika
a4c1be6496 Modlog Converter: Fix bugs
The modlog converter now mostly works properly. There are some discrepancies (for example, Lobby gets 11,000 more modlog entries in SQLite than in text); I'm not sure if this is because of glitches in the previous system or a bug in my code. This script will need to be run after #8004 is merged.
2021-07-17 21:14:24 -07:00
Annika
31605c36b3 Modlog: FIx converter bug in action-taker regex 2021-02-06 11:42:07 -08:00
Mia
76c10841ea
Lib: Add an index file for all exports (#7972) 2021-01-31 18:00:19 -08:00
Annika
66c043086e Modlog converter: Fix crash without SQLite library 2020-11-07 13:40:07 -08:00
Annika
ec0a92469a Modlog: Make tests work without SQLite 2020-11-05 22:40:53 -08:00
Annika
aa069ce8fd
Support disabling modlogs (#7619)
Co-authored-by: Christopher Monsanto <chris@monsan.to>
2020-11-02 22:59:31 -05:00
Annika
7f2dec0797
Modlog: Avoid optional properties in ModlogEntry (#7613)
* Modlog: Avoid optional properties in ModlogEntry

* Use a type

* Make IP nullable

* Add NOT NULL constrains

* Fix typo
2020-11-01 14:07:01 -08:00
Annika
2f130e8762
Modlog: Support logging to a SQLite database (#7513)
* Modlog: Support logging to a SQLite database

Co-authored-by: Christopher Monsanto <chris@monsan.to>
2020-10-30 19:27:25 -04:00
Annika
099346ee1e Tools: Modernize modlog entries for blacklists 2020-10-25 16:13:46 -07:00
Guangcong Luo
9d87616176
Add more style linting rules (#7537)
* Lint arrow-body-style

* Lint prefer-object-spread

Object spread is faster _and_ more readable.

This also fixes a few unnecessary object clones.

* Enable no-parameter-properties

This isn't currently used, but this makes clear that it shouldn't be.

* Refactor more Promises to async/await

* Remove unnecessary code from getDataMoveHTML etc

* Lint prefer-string-starts-ends-with

* Stop using no-undef

According to the typescript-eslint FAQ, this is redundant with
TypeScript, and they're not wrong. This will save us from needing to
specify globals in two different places which will be nice.
2020-10-19 02:42:28 -07:00
Annika
0877f0ae1e
Modlog: Fix entries with an IP address and no user (#7446) 2020-09-30 17:55:41 -07:00
Annika
f1b4e3d43a
Modlog: Refactor to use ModlogEntry objects (#7403) 2020-09-28 11:06:30 -07:00