Skip to content

Validate added migration file #12

Validate added migration file

Validate added migration file #12

name: Check task migrations
"on":
pull_request:
branches: [main]
jobs:
check:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v45
- name: show files
env:
ADDED_FILES: ${{ steps.changed-files.outputs.added_files }}
ALL_CHANGED_FILES: ${{ steps.changed-files.outputs.all_changed_files }}
run: |
set -x
echo "added files:"
echo ${ADDED_FILES}
echo
echo "changed files:"
echo ${ALL_CHANGED_FILES}
echo
DEFAULT_BRANCH=$(git remote show origin | awk '/HEAD branch/ {print $NF}')
echo "default branch: $DEFAULT_BRANCH"
git --version
git branch
/usr/bin/git log $DEFAULT_BRANCH
git log $DEFAULT_BRANCH
- name: Create k8s Kind Cluster
uses: helm/kind-action@v1
- name: Run check
run: |
export IN_CLUSTER=1
bash -x ./hack/validate-migration.sh