fix: specify pub cache path (#280)

This commit is contained in:
Richard Shiue
2024-03-20 12:20:53 +08:00
committed by GitHub
parent 62f096cacd
commit 1c5eb12d81
2 changed files with 27 additions and 6 deletions

View File

@@ -29,6 +29,10 @@ inputs:
description: 'Flutter SDK cache path'
required: false
default: '${{ runner.tool_cache }}/flutter/:channel:-:version:-:arch:'
pub-cache-path:
description: 'Flutter pub cache path'
required: false
default: 'default'
architecture:
description: 'The architecture of Flutter SDK executable (x64 or arm64)'
required: false
@@ -54,7 +58,7 @@ runs:
- run: chmod +x $GITHUB_ACTION_PATH/setup.sh
shell: bash
- id: flutter-action
run: $GITHUB_ACTION_PATH/setup.sh -p -c '${{ inputs.cache-path }}' -k '${{ inputs.cache-key }}' -d '${{ inputs.pub-cache-key }}' -n '${{ inputs.flutter-version }}' -a '${{ inputs.architecture }}' ${{ inputs.channel }}
run: $GITHUB_ACTION_PATH/setup.sh -p -c '${{ inputs.cache-path }}' -k '${{ inputs.cache-key }}' -d '${{ inputs.pub-cache-path }}' -l '${{ inputs.pub-cache-key }}' -n '${{ inputs.flutter-version }}' -a '${{ inputs.architecture }}' ${{ inputs.channel }}
shell: bash
- if: ${{ inputs.cache == 'true' }}
uses: actions/cache@v4