mirror of
https://github.com/fromchat-messenger/app.git
synced 2026-09-22 19:15:05 +03:00
Split Gradle build cache into restore/save steps so hits still refresh.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -1,25 +1,20 @@
|
||||
name: Cache Gradle build directories
|
||||
description: Restore or save module build/ trees for faster CI Gradle jobs
|
||||
|
||||
inputs:
|
||||
save:
|
||||
description: Save cache at job end. Use false on parallel jobs that share the same cache key.
|
||||
required: false
|
||||
default: "true"
|
||||
name: Restore Gradle build directories
|
||||
description: Restore module build/ trees for faster CI Gradle jobs
|
||||
|
||||
outputs:
|
||||
cache-hit:
|
||||
description: Whether build directories were restored from cache
|
||||
description: Whether an exact cache key match was restored
|
||||
value: ${{ steps.cache.outputs.cache-hit }}
|
||||
cache-primary-key:
|
||||
description: Primary cache key to pass to the save action after the build
|
||||
value: ${{ steps.cache.outputs.cache-primary-key }}
|
||||
|
||||
runs:
|
||||
using: composite
|
||||
steps:
|
||||
- uses: actions/cache@v5
|
||||
- uses: actions/cache/restore@v5
|
||||
id: cache
|
||||
with:
|
||||
lookup-only: ${{ inputs.save != 'true' }}
|
||||
save-always: ${{ inputs.save == 'true' }}
|
||||
path: |
|
||||
app/desktop/build
|
||||
app/shared/build
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
name: Save Gradle build directories
|
||||
description: Save module build/ trees after a Gradle build (always runs, even on cache hit)
|
||||
|
||||
inputs:
|
||||
primary-key:
|
||||
description: cache-primary-key from cache-gradle-build restore step
|
||||
required: true
|
||||
|
||||
runs:
|
||||
using: composite
|
||||
steps:
|
||||
- uses: actions/cache/save@v5
|
||||
with:
|
||||
key: ${{ inputs.primary-key }}
|
||||
path: |
|
||||
app/desktop/build
|
||||
app/shared/build
|
||||
app/android/build
|
||||
utils/shared/build
|
||||
utils/android/build
|
||||
Reference in New Issue
Block a user