mirror of
https://github.com/tcgdex/compiler.git
synced 2025-08-10 20:51:58 +00:00
Updated Compiler to be quicker
Signed-off-by: Avior <florian.bouillon@delta-wings.net>
This commit is contained in:
@@ -8,7 +8,8 @@ const lang = process.env.CARDLANG as Langs || "en"
|
||||
const endpoint = getBaseFolder(lang, "hp")
|
||||
|
||||
|
||||
const btsp = async () => {
|
||||
export default async () => {
|
||||
console.log(endpoint)
|
||||
const cards = getAllCards()
|
||||
|
||||
const hps: Array<number> = []
|
||||
@@ -29,6 +30,5 @@ const btsp = async () => {
|
||||
await fs.mkdir(endpoint, {recursive: true})
|
||||
await fs.writeFile(`${endpoint}/index.json`, JSON.stringify(hpList))
|
||||
|
||||
console.log('ended ' + endpoint)
|
||||
}
|
||||
|
||||
btsp()
|
||||
|
@@ -12,7 +12,8 @@ interface t {
|
||||
const lang = process.env.CARDLANG as Langs || "en"
|
||||
const endpoint = getBaseFolder(lang, "hp")
|
||||
|
||||
const btsp = async () => {
|
||||
export default async () => {
|
||||
console.log(endpoint)
|
||||
const files = getAllCards()
|
||||
const pools: t = {}
|
||||
for (const file of files) {
|
||||
@@ -37,6 +38,5 @@ const btsp = async () => {
|
||||
await fs.writeFile(`${endpoint}/${toSave.hp}/index.json`, JSON.stringify(toSave))
|
||||
}
|
||||
}
|
||||
console.log('ended ' + endpoint)
|
||||
}
|
||||
|
||||
btsp()
|
||||
|
Reference in New Issue
Block a user