1
0
mirror of https://github.com/tcgdex/cards-database.git synced 2025-06-12 15:59:18 +00:00

Add regulation mark (#17)

* Added to interface

* Added Regulation mark to all current cards

* Ready for merge
This commit is contained in:
2021-05-28 11:21:10 +02:00
committed by GitHub
parent c47ce5ebbb
commit ec1b6a06b0
1272 changed files with 4465 additions and 5154 deletions

5
codeshift/README.md Normal file
View File

@ -0,0 +1,5 @@
to use it launch
```
yarn jscodeshift -t ./codeshift/index.ts --extensions=ts --parser=ts ./data/Serie/Set --print --dry
```

View File

@ -92,13 +92,9 @@ const transformer: Transform = (file, api) => {
if (index !== 0) return
let simplified = simplify(path.node)
// Run sodechanges
// set(j, simplified.item, j.objectExpression([
// j.property('init', j.identifier('normal'), j.booleanLiteral(true)),
// j.property('init', j.identifier('reverse'), j.booleanLiteral(true)),
// j.property('init', j.identifier('holo'), j.booleanLiteral(false)),
// j.property('init', j.identifier('firstEdition'), j.booleanLiteral(false)),
// ]), 'variants')
// Example Set/Add regulationMArk to cards
set(j, simplified.item, j.literal('D'), 'regulationMark')
})
.toSource({useTabs: true, lineTerminator: '\n'}).replace(/ /g, ' ')
}