Skip to content

Commit dac4cfe

Browse files
committed
Export ESPUP_EXPORT_FILE
This is primarily useful for hands-off environments where the paths are not exported by default (otherwise, downstream actions would need to hard-code this action's choice of export file), and conveniently allows eliding the parameter during installation (because the variable is used by espup).
1 parent b989c80 commit dac4cfe

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

action.yaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,14 +55,15 @@ runs:
5555
curl -LO https://github.com/esp-rs/espup/releases/latest/download/espup-${{ env.HOST_TARGET }}.zip
5656
unzip -o espup-${{ env.HOST_TARGET }}.zip -d "$HOME/.cargo/bin"
5757
chmod +x "$HOME/.cargo/bin/espup"*
58+
echo "ESPUP_EXPORT_FILE=$HOME/exports" >> $GITHUB_ENV
5859
5960
- name: Install Xtensa toolchain (Linux, macOS)
6061
if: env.HOST_TARGET != 'x86_64-pc-windows-msvc'
6162
shell: bash
6263
run: |
6364
source "$HOME/.cargo/env"
6465
[[ "${{ inputs.version }}" != latest ]] && version="--toolchain-version ${{ inputs.version }}" || version=""
65-
"$HOME/.cargo/bin/espup" install -l debug --export-file $HOME/exports --targets ${{ inputs.buildtargets }} $version
66+
"$HOME/.cargo/bin/espup" install -l debug --targets ${{ inputs.buildtargets }} $version
6667
source "$HOME/exports"
6768
echo "$PATH" >> "$GITHUB_PATH"
6869
echo "LIBCLANG_PATH=${LIBCLANG_PATH}" >> "$GITHUB_ENV"
@@ -72,7 +73,7 @@ runs:
7273
shell: bash
7374
run: |
7475
[[ "${{ inputs.version }}" != latest ]] && version="--toolchain-version ${{ inputs.version }}" || version=""
75-
"$HOME/.cargo/bin/espup.exe" install -l debug --export-file $HOME/exports --targets ${{ inputs.buildtargets }} $version
76+
"$HOME/.cargo/bin/espup.exe" install -l debug --targets ${{ inputs.buildtargets }} $version
7677
7778
- name: Set default and override
7879
shell: bash

0 commit comments

Comments
 (0)