chore(deps-dev): bump typescript from 5.6.2 to 5.7.2 (#867) #360
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Push new version to dist branch | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
deploy: | |
name: Push | |
runs-on: ubuntu-latest | |
env: | |
TARGET_BRANCH: dist | |
permissions: | |
contents: write | |
steps: | |
- name: Check out the code | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Install pnpm | |
uses: pnpm/action-setup@v2 | |
with: | |
run_install: false | |
- name: Install Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version-file: .nvmrc | |
cache: pnpm | |
cache-dependency-path: pnpm-lock.yaml | |
- name: Configure Git | |
run: | | |
git config --global user.name "Github Actions" | |
git config --global user.email "github-actions[bot]@users.noreply.github.com" | |
git pull origin HEAD | |
git worktree add -B $TARGET_BRANCH dist origin/$TARGET_BRANCH | |
- name: Install Dependencies and Build | |
run: | | |
pnpm install --frozen-lockfile | |
pnpm build:prod | |
- name: Push New Version | |
run: | | |
export SHORT_SHA=$(git rev-parse --short HEAD) | |
cd dist | |
git add . | |
git diff-index --quiet HEAD || git commit -am "Update to output generated at $SHORT_SHA" | |
git push origin $TARGET_BRANCH |