mirror of
https://github.com/tiennm99/thptqg.git
synced 2026-10-04 20:13:37 +00:00
Sites: /thptqg2017/ → data/ 861,068 students (baotintuc.vn .xls) /thptqg2017/old/ → data-old/ 847,348 students (original xlsx) /thptqg2017/old2/ → data-old2/ 679,764 students (update/ overrides) Build pipeline: - scripts/build-lib.js: shared schema, score regex, toAscii, insert builder — keeps the 3 DBs drop-in compatible for the same frontend - scripts/build-database.js: multi-sheet walk for baotintuc .xls (HN/HCM overflow past the 65k-per-sheet .xls cap) - scripts/build-database-old.js: single-sheet xlsx + strict numeric SBD guard (rejects the header-row leak present in data-old) - scripts/build-database-old2.js: multi-sheet + blank-row pre-filter for the 54 update files (HCM overflow present, HN not in this subset) - Each build prints a source-vs-DB audit; verified 0 parse errors and exact row-count match across all 3 datasets Frontend plumbing: - vite.config.js: VARIANT env selects base path, publicDir, outDir - package.json: build:db:*, build:db:all, build:old, build:old2, build:all - .github/workflows/deploy.yml: CI builds all 3 DBs + sites - .gitignore: cover public-old/ and public-old2/ outputs - eslint.config.js: add Node globals for config/script files
44 lines
1.5 KiB
JSON
44 lines
1.5 KiB
JSON
{
|
|
"name": "thptqg2017",
|
|
"private": true,
|
|
"version": "1.0.0",
|
|
"type": "module",
|
|
"description": "Tra cứu điểm thi THPT QG 2017",
|
|
"scripts": {
|
|
"build:db": "node scripts/build-database.js",
|
|
"build:db:old": "node scripts/build-database-old.js",
|
|
"build:db:old2": "node scripts/build-database-old2.js",
|
|
"build:db:all": "npm run build:db && npm run build:db:old && npm run build:db:old2",
|
|
"dev": "vite",
|
|
"build": "vite build",
|
|
"build:old": "node -e \"process.env.VARIANT='old';require('child_process').spawnSync('npx',['vite','build'],{stdio:'inherit',shell:true,env:process.env})\"",
|
|
"build:old2": "node -e \"process.env.VARIANT='old2';require('child_process').spawnSync('npx',['vite','build'],{stdio:'inherit',shell:true,env:process.env})\"",
|
|
"build:all": "npm run build && npm run build:old && npm run build:old2",
|
|
"preview": "vite preview",
|
|
"lint": "eslint ."
|
|
},
|
|
"repository": {
|
|
"type": "git",
|
|
"url": "git+https://github.com/tiennm99/thptqg2017.git"
|
|
},
|
|
"license": "ISC",
|
|
"dependencies": {
|
|
"react": "^19.2.4",
|
|
"react-dom": "^19.2.4",
|
|
"sql.js": "^1.14.1"
|
|
},
|
|
"devDependencies": {
|
|
"@eslint/js": "^9.39.4",
|
|
"@types/react": "^19.2.14",
|
|
"@types/react-dom": "^19.2.3",
|
|
"@vitejs/plugin-react": "^6.0.1",
|
|
"better-sqlite3": "^12.8.0",
|
|
"eslint": "^9.39.4",
|
|
"eslint-plugin-react-hooks": "^7.0.1",
|
|
"eslint-plugin-react-refresh": "^0.5.2",
|
|
"globals": "^17.4.0",
|
|
"vite": "^8.0.4",
|
|
"xlsx": "^0.18.5"
|
|
}
|
|
}
|