Skip to content
Open
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 3 additions & 31 deletions .github/workflows/deploy-develop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -94,35 +94,7 @@ jobs:
- name: Save develop build
run: mv dist develop-dist

# Second: Build main branch content for the root
- name: Checkout and build main branch with test site link
run: |
# Save current develop state
git stash push -m "Save develop changes" || echo "No changes to stash"

# Checkout main branch with full history and ensure tags are available
git checkout main
git pull origin main || echo "No changes to pull"

# Ensure all tags are fetched for version calculation
git fetch --tags || echo "Tags already available"

# Build main branch content with proper main branch GitVersion
npm run build

# Save main build
mv dist main-dist

# Return to develop branch and restore state
git checkout develop
if git stash list | grep -q "Save develop changes"; then
git stash pop
fi
env:
# Pass test site info for footer link
TEST_SITE_PATH: ${{ steps.pr-info.outputs.deploy_path }}

# Get GitVersion for main branch after checking it out
# Get GitVersion for main branch
- name: Get main branch GitVersion
id: gitversion-main
run: |
Expand Down Expand Up @@ -153,8 +125,8 @@ jobs:
git stash pop
fi

# Rebuild main with proper GitVersion values
- name: Rebuild main branch with correct GitVersion
# Build main branch with proper GitVersion values
- name: Build main branch with correct GitVersion
run: |
# Save current develop state
git stash push -m "Save develop changes" || echo "No changes to stash"
Expand Down
4 changes: 2 additions & 2 deletions gitversion.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ commit-message-incrementing: Enabled
branches:
main:
regex: ^main$
mode: ContinuousDelivery
mode: ContinuousDeployment
label: ''
increment: Patch
develop:
regex: ^develop$
mode: ContinuousDeployment
label: alpha
increment: None
increment: Patch
release:
regex: ^releases?[/-]
mode: ContinuousDelivery
Expand Down