Actions: Merge if branch exists
All checks were successful
Build and Save Artifact / build (push) Successful in 11s

This commit is contained in:
Cyanoure
2024-09-15 16:25:33 +02:00
parent bdd36603df
commit cbcdb66417

View File

@ -24,13 +24,13 @@ jobs:
with:
node-version: '22'
# Delete existing build branch
- name: Delete existing build branch
run: git branch -d ${GITHUB_REF_NAME}-build || echo "Build branch not found"
# Create and switch to build branch
- name: Create and switch to build branch
run: git branch ${GITHUB_REF_NAME}-build && git switch ${GITHUB_REF_NAME}-build
# Initialize build branch
- name: Initialize build branch
run: |
git branch ${GITHUB_REF_NAME}-build || echo "Build branch already exists"
git switch ${GITHUB_REF_NAME}-build
git merge ${GITHUB_REF_NAME}
rm -rf dist
# Install dependencies
- name: Install dependencies