Explorar o código

feat: 数据抓取工作流

modood %!s(int64=7) %!d(string=hai) anos
pai
achega
b5773a68ca
Modificáronse 1 ficheiros con 12 adicións e 0 borrados
  1. 12 0
      lib/fetch.js

+ 12 - 0
lib/fetch.js

@@ -0,0 +1,12 @@
+const sqlite = require('./sqlite')
+const worker = require('./worker')
+
+async function main () {
+  await sqlite.init()
+  await worker.fetchVillages()
+  await worker.patch()
+
+  console.log('[100%] 数据抓取完成!')
+}
+
+main()