Skip to content

fix: rework ci/cd

fix: rework ci/cd #823

Workflow file for this run

name: Config
on:
push:
branches:
- main
- develop
env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}
jobs:
config:
name: Config Sync
runs-on: ubuntu-latest
steps:
- name: Wait for other CI
uses: lewagon/[email protected]
with:
ref: ${{ github.ref }}
check-name: 'Lint Check'
repo-token: ${{ secrets.GITHUB_TOKEN }}
wait-interval: 10
- name: Checkout code
id: checkout-code
uses: actions/checkout@v3
with:
fetch-depth: 2
- name: Run script
run: |
yarn config:check
- name: Generate latest env vars
run: |
yarn config:env
- name: Configure git
run: |
git config --global user.name "turtlesocks-bot"
git config --global user.email "[email protected]"
- name: Check for changes
run: |
if git diff --quiet; then
echo "changes_exist=false" >> $GITHUB_ENV
else
echo "changes_exist=true" >> $GITHUB_ENV
fi
- name: Commit and push changes
if: ${{ env.changes_exist == 'true' }}
run: |
git add --all
git commit --message "chore: Sync CI/CD Config Items"
git push