2019-05-25 11:36:19 +00:00
|
|
|
import path from 'path'
|
|
|
|
import fse from 'fs-extra'
|
2019-06-01 06:37:20 +00:00
|
|
|
import { loadBadgeMeta } from '../libs/badge-list'
|
2019-05-25 11:36:19 +00:00
|
|
|
|
|
|
|
const rel = (...args) => path.resolve(__dirname, ...args)
|
|
|
|
|
|
|
|
async function main () {
|
2019-06-01 06:37:20 +00:00
|
|
|
const badgeMeta = await loadBadgeMeta()
|
2019-07-05 09:29:07 +00:00
|
|
|
await fse.outputJson(rel('../static/.meta/badges.json'), badgeMeta)
|
2019-05-25 11:36:19 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
main()
|
|
|
|
|
|
|
|
process.on('unhandledRejection', console.error)
|