fix: gen_migrations committing, logging, gitmodule

This commit is contained in:
Orion Kindel 2023-07-20 11:03:19 -05:00
parent 26c2c9ca6a
commit b9d80dd04f
Signed by untrusted user who does not match committer: orion
GPG Key ID: 6D4165AE4C928719
3 changed files with 5 additions and 7 deletions

View File

@ -21,7 +21,7 @@ jobs:
run: |
set -ex
git submodule update --init --remote migrations;
if ! (git diff-index --quiet --cached HEAD --); then
if ! (git diff-index --quiet HEAD --ignore-submodules=none); then
git add -A
git commit -m 'chore: update migrations'
git push
@ -30,7 +30,7 @@ jobs:
run: |
./scripts/gen_migrations.sh
cd migrations
if ! (git diff-index --quiet --cached HEAD --); then
if ! (git diff-index --quiet HEAD --ignore-submodules=none); then
git add -A
git commit -m 'chore: babe wake up new migrations just dropped'
git push

4
.gitmodules vendored
View File

@ -1,6 +1,4 @@
[submodule "migrations"]
branch = migrations
path = migrations
url = git@git.orionkindel.com:dnim/db
branch = migrations
[submodule "migraionts"]
branch = migrations

View File

@ -41,5 +41,5 @@ cp .env.schema "./$base_or_head/.env.schema"
cd "./$base_or_head"
docker compose up --wait --wait-timeout 30 -d "$base_or_head"
initdb || (docker compose logs "$base_or_head" && exit 1)
ls ./schema/ | xargs -I{} bash -c "set -e; $(declare -f query_file); query_file \"$(db dnim)\" ./schema/{}" || (docker compose logs "$base_or_head" && exit 1)
initdb
ls ./schema/ | xargs -I{} bash -c "set -e; $(declare -f query_file); query_file \"$(db dnim)\" ./schema/{}"