Skip to content

fix: zh meta info (#537) #129

fix: zh meta info (#537)

fix: zh meta info (#537) #129

Workflow file for this run

name: Build Preview
on:
push:
branches: ["master"]
paths-ignore:
- ".github/**"
workflow_dispatch:
concurrency: ci-prev
jobs:
build:
runs-on: ubuntu-latest
name: Automatically update submodule
steps:
- uses: actions/checkout@v3
with:
ref: "preview"
- name: Init git info
run: |
git status
git config user.name github-actions
git config user.email [email protected]
- name: Git reset to master branch
run: |
git fetch
git reset --hard origin/master
- name: Update submodule
id: submodule
run: |
git submodule init
echo "submodule_sha_origin=$(git submodule status | awk '{print $1}' | sed -r 's/[+-]+//g')" >> $GITHUB_OUTPUT
git submodule update --remote
echo "submodule_sha=$(git submodule status | awk '{print $1}' | sed -r 's/[+-]+//g')" >> $GITHUB_OUTPUT
echo "git_sha=$(git rev-parse HEAD)" >> $GITHUB_OUTPUT
echo "build_date=$(date)" >> $GITHUB_OUTPUT
- name: Git commit and push submodules update
run: |
git add .
if [[ -z $(git status -s) ]]
then
git status
else
git commit -m "update submodules"
fi
git push -f