commit cc906558099d07bae600bd7cf5228e3668f366d1
parent ba9b17964ac7c30dea319c7b0cac5fff1fa37c0f
Author: Jacob R. Edwards <jacob@jacobedwards.org>
Date: Tue, 13 Aug 2024 16:00:20 -0700
Fix make updatedb target
When using the -f option, psql doesn't allow comments, yet there
are comments in the migration files.
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/cmd/api/Makefile b/cmd/api/Makefile
@@ -46,7 +46,7 @@ createdb:
# (${dbname})
updatedb: backupdb
for f in $$(./scripts/dbupdates ${dbsql}); do \
- psql -f "${dbsql}/$$f" ${dburl} ${dbuser} || { \
+ psql ${dburl} ${dbuser} < "${dbsql}/$$f" || { \
echo "FAILED TO APPLY $$f" ; \
exit 1 ; \
} ; \