diff --git a/docker-compose.yml b/docker-compose.yml index 2433eb7..40ec85d 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -20,4 +20,10 @@ services: command: ["npm", "run", "melli-init"] volumes: - ./data/app.db:/app/prisma/dev.db - profiles: ["mellisearch_init"] + profiles: ["disabled"] + db_init: + build: . + command: ["npm", "run", "db-init"] + volumes: + - ./data/app.db:/app/prisma/dev.db + profiles: ["disabled"] diff --git a/dummy/layouts/_default/sitemap-web3news.xml b/dummy/layouts/_default/sitemap-web3news.xml new file mode 100644 index 0000000..4c6f028 --- /dev/null +++ b/dummy/layouts/_default/sitemap-web3news.xml @@ -0,0 +1,24 @@ +{{ printf "" | safeHTML }} + + {{ range .Data.Posts }} + {{- if .Permalink -}} + + {{ .Permalink }}{{ if not .Lastmod.IsZero }} + {{ safeHTML ( .Lastmod.Format "2006-01-02T15:04:05-07:00" ) }}{{ end }}{{ with .Sitemap.ChangeFreq }} + {{ . }}{{ end }}{{ if ge .Sitemap.Priority 0.0 }} + {{ .Sitemap.Priority }}{{ end }}{{ if .IsTranslated }}{{ range .Translations }} + {{ end }} + {{ end }} + + {{- end -}} + {{ end }} + diff --git a/package.json b/package.json index 9710ee3..5b5c900 100644 --- a/package.json +++ b/package.json @@ -18,6 +18,7 @@ "typecheck": "tsc", "bridge": "bun run scripts/bridge.mts", "melli-init": "bun run scripts/melli-init.mts", + "db-init": "prisma db push", "postinstall": "patch-package" }, "dependencies": {