Skip to content

Commit 823e0c0

Browse files
committed
feat(hdu): init
1 parent 38b936d commit 823e0c0

File tree

4 files changed

+20
-3
lines changed

4 files changed

+20
-3
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "CPAssistant.js",
3-
"version": "1.1.0",
3+
"version": "1.1.1",
44
"description": "",
55
"main": "index.js",
66
"license": "GPL-3.0-only",

src/app.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
import { Dict } from './utils/type';
22
import Module from './types/module';
33
import Feature from './types/feature';
4-
import ModuleVjudge from './modules/vjudge/main';
5-
import ModuleQOJ from './modules/qoj/main';
64
import ModuleCodeforces from './modules/codeforces/main';
5+
import ModuleHDU from './modules/hdu/main';
6+
import ModuleQOJ from './modules/qoj/main';
7+
import ModuleVjudge from './modules/vjudge/main';
78

89
export default class App {
910
modules: Dict<Module>;
@@ -44,3 +45,4 @@ export const app = new App();
4445
app.register(new ModuleVjudge(app));
4546
app.register(new ModuleCodeforces(app));
4647
app.register(new ModuleQOJ(app));
48+
app.register(new ModuleHDU(app));

src/config.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ const config: Dict<any> = {
66
'codeforces.com',
77
'codeforc.es',
88
],
9+
hdu: [
10+
'acm.hdu.edu.cn',
11+
],
912
qoj: [
1013
'qoj.ac',
1114
'pjudge.ac',

src/modules/hdu/main.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
import config from '../../config'
2+
import App from '../../app'
3+
import Module from "../../types/module"
4+
5+
export default class ModuleHDU extends Module {
6+
run() {
7+
}
8+
9+
constructor(app: App) {
10+
super(app, 'hdu', config.match.hdu)
11+
}
12+
}

0 commit comments

Comments
 (0)