Skip to content

Commit

Permalink
build: capturing new migrations.
Browse files Browse the repository at this point in the history
  • Loading branch information
awais786 committed Oct 31, 2023
1 parent b8d90a7 commit 9c37433
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/capture_new_migrations.yml
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ jobs:
- name: Verify executed migrations on master.
id: capture1
run: |
query_result=$(mysql -h 127.0.0.1 -uedxapp001 -ppassword -e "select count(*) from django_migrations;" edxapp;)
query_result=$(mysql -h 127.0.0.1 -uedxapp001 -ppassword -e "select 1;" edxapp;)
echo "Query Result: $query_result"
echo "query_result=${query_result}" >> $GITHUB_ENV
echo "echo ${{env.query_result}}"
Expand Down Expand Up @@ -157,7 +157,7 @@ jobs:
- name: Verify executed migrations on branch.
id: capture2
run: |
query_result1=$(mysql -h 127.0.0.1 -uedxapp001 -ppassword -e "select count(*) from django_migrations;" edxapp;)
query_result1=$(mysql -h 127.0.0.1 -uedxapp001 -ppassword -e "select 1;" edxapp;)
echo "Query Result: query_result1"
echo "query_result1=${query_result1}" >> $GITHUB_ENV
shell: bash
Expand All @@ -170,7 +170,7 @@ jobs:
number2=${{ env.query_result1 }}
# Perform subtraction
diff=$((number1 - number2))
result=$(mysql -h 127.0.0.1 -uedxapp001 -ppassword -e "select * from django_migrations ORDER by -id limit $diff ;" edxapp;)
result=$(mysql -h 127.0.0.1 -uedxapp001 -ppassword -e "select 1 ;" edxapp;)
echo "Query Result: $result"
echo "$result"
shell: bash
Expand Down

0 comments on commit 9c37433

Please sign in to comment.