Skip to content

chore(deps): update dependency turbo to v2.7.0 #890

chore(deps): update dependency turbo to v2.7.0

chore(deps): update dependency turbo to v2.7.0 #890

Workflow file for this run

name: publish
on:
push:
branches:
- "**"
- "!gh-pages"
tags:
- "**"
permissions:
contents: write
pages: write
id-token: write
concurrency:
group: global-workflow-queue
cancel-in-progress: false
jobs:
call-build:
uses: ./.github/workflows/build.yml
deploy:
runs-on: ubuntu-latest
needs: call-build
concurrency:
group: deploy-gh-pages
cancel-in-progress: false
steps:
- name: Download artifact
uses: actions/download-artifact@v7
with:
name: build-out
path: out
- name: Set up Git config
run: |
git config --global user.name "${{ github.actor }}"
git config --global user.email "${{ github.actor }}@users.noreply.github.com"
- name: Deploy to gh-pages
run: |
if [[ "${GITHUB_REF}" == refs/heads/* ]]; then
TARGET_PATH="branches/${GITHUB_REF#refs/heads/}"
elif [[ "${GITHUB_REF}" == refs/tags/* ]]; then
TARGET_PATH="tags/${GITHUB_REF#refs/tags/}"
else
echo "Not a branch or tag, skipping"
exit 1
fi
git clone --depth 1 --branch gh-pages "https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git" gh-pages
rm -rf "gh-pages/${TARGET_PATH}"
mkdir -p "gh-pages/${TARGET_PATH}"
cp -r out/* "gh-pages/${TARGET_PATH}/"
cd gh-pages
git add .
if ! git diff --cached --quiet; then
git commit -m "Deploy ${TARGET_PATH} from ${GITHUB_SHA}"
git push
else
echo "No changes to deploy."
fi