A useful (I hope) toolkit for the PTA (Pintia) platform.
- Interactive CLI Management: Seamlessly navigate through current and historical problem sets using arrow keys.
- Dual-Mode Downloader: For ongoing problem-sets (Clean Mode), download the problems. For ended ones (Archive Mode), download more information like scores/answers/ranks etc.
- Terminal Report Cards: Direct command-line data grid showing the basic information of the chosen problem-set.
- Proactive Status Monitor: Persistent polling daemon capable of computing real-time status changes and emitting notifications via integrated DingTalk webhooks.
- Clone the Repository:
git clone https://github.com/Tsukimakura/PTA-tools.git
cd PTA-tools- Install Dependencies:
npm install- Environment Setup: Duplicate the example profile into a concrete local configurations map:
cp config.example.json config.jsonOpen config.json and insert your username and password (cookie is not necessary)
{
"username": "",
"password": "",
"cookie": "",
"dingdingWebhook": "https://oapi.dingtalk.com/robot/send?access_token=...",
"refreshInterval": 30000
}To start downloading assignments or inspecting reports via terminal, execute:
npm run cliThen I believe you can understand how to use it.
To spin up the continuous tracking subsystem that records state changes and pipes them straight to your communication channels, execute:
npm run monitorThe program will generate a local database layer tracking state-machine transformations (pta_status.json) and run silently in the background.
(In short, you can use it to avoid missing a test...)
I'm far from skilled temporarily. Issues and PRs (Contact me first) are welcome.
QQ: 2889908070 (recommended);
email: chenlingshi@zju.edu.cn