Skip to content
Merged
Show file tree
Hide file tree
Changes from all 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
6 changes: 5 additions & 1 deletion .github/actions/setup-go/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ inputs:
description: Path prefix for go.mod / go.sum files (used when the repo is checked out into a subdirectory)
required: false
default: "."
cache:
description: Whether to cache Go modules and build outputs
required: false
default: "true"
runs:
using: composite
steps:
Expand All @@ -14,5 +18,5 @@ runs:
cache-dependency-path: |
${{ inputs.working-directory }}/go.sum
${{ inputs.working-directory }}/caddy/go.sum
cache: ${{ !startsWith(github.ref, 'refs/tags/') }}
cache: ${{ inputs.cache == 'true' && !startsWith(github.ref, 'refs/tags/') }}
check-latest: true
2 changes: 2 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,8 @@ jobs:
fi
- if: steps.state.outputs.resume != 'true'
uses: ./.github/actions/setup-go
with:
cache: "false"
- if: steps.state.outputs.resume != 'true'
uses: ./.github/actions/setup-php
- if: steps.state.outputs.resume != 'true'
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/static.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -447,6 +447,8 @@ jobs:
ref: ${{ needs.prepare.outputs.ref }}
persist-credentials: false
- uses: ./.github/actions/setup-go
with:
cache: ${{ !(needs.prepare.outputs.ref || github.ref_type == 'tag') }}
- id: version
uses: ./.github/actions/version
with:
Expand Down
14 changes: 14 additions & 0 deletions .github/workflows/windows.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,20 @@ jobs:
uses: ./frankenphp/.github/actions/setup-go
with:
working-directory: frankenphp
cache: ${{ !env.REF }}

- name: Determine runner image
id: image
run: '"version=$env:ImageVersion" >> $env:GITHUB_OUTPUT'

# SourceForge sometimes serves runners a non-archive body for pthreads sources; release runs skip the cache
- name: Cache Vcpkg Packages # zizmor: ignore[cache-poisoning]
if: ${{ !env.REF }}
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: ~\AppData\Local\vcpkg\archives
key: vcpkg-${{ runner.os }}-${{ steps.image.outputs.version }}-${{ hashFiles('frankenphp/vcpkg.json') }}
restore-keys: vcpkg-${{ runner.os }}-

- name: Install Vcpkg Libraries
working-directory: frankenphp
Expand Down
Loading