Rename script
This commit is contained in:
parent
3a165c1978
commit
5c3f3ceb20
1 changed files with 4 additions and 4 deletions
|
@ -4,7 +4,7 @@ import sade from "sade"
|
||||||
import type { JorfTexteVersion } from "$lib"
|
import type { JorfTexteVersion } from "$lib"
|
||||||
import { db } from "$lib/server/database"
|
import { db } from "$lib/server/database"
|
||||||
|
|
||||||
async function linkDecretsToLois(): Promise<void> {
|
async function associateDecretsToLois(): Promise<void> {
|
||||||
for (const texteVersion of (
|
for (const texteVersion of (
|
||||||
await db<{ data: JorfTexteVersion }[]>`
|
await db<{ data: JorfTexteVersion }[]>`
|
||||||
SELECT data
|
SELECT data
|
||||||
|
@ -30,10 +30,10 @@ async function linkDecretsToLois(): Promise<void> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
sade("link_decrets_and_lois", true)
|
sade("associate_decrets_and_lois", true)
|
||||||
.describe("Link decrets to lois in database")
|
.describe("Associate décrets with lois in database")
|
||||||
.action(async () => {
|
.action(async () => {
|
||||||
await linkDecretsToLois()
|
await associateDecretsToLois()
|
||||||
process.exit(0)
|
process.exit(0)
|
||||||
})
|
})
|
||||||
.parse(process.argv)
|
.parse(process.argv)
|
Loading…
Reference in a new issue