Skip to content

Commit 7628258

Browse files
committed
Fix building bundles for build CI
1 parent 271a321 commit 7628258

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

build/action.yml

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,12 @@ inputs:
99
description: 'The version of Python to use in the CI'
1010
required: true
1111
default: '3.x'
12+
package-prefix:
13+
description: |
14+
The prefix (or name) of your pacakge (if applicable) to use
15+
for GitHub releases
16+
required: true
17+
default: ""
1218
runs:
1319
using: "composite"
1420
steps:
@@ -64,9 +70,18 @@ runs:
6470
pip install ".[optional]"
6571
pytest
6672
fi
73+
- name: Add the given package filename_prefix
74+
id: package-prefix-arg
75+
shell: bash
76+
run: |
77+
if [ "${{ inputs.package-prefix }}" == "" ]; then
78+
echo prefix-arg="" >> $GITHUB_OUTPUT
79+
else
80+
echo prefix-arg="--package_folder_prefix ${{ inputs.package-prefix }}" >> $GITHUB_OUTPUT
81+
fi
6782
- name: Build assets
6883
shell: bash
69-
run: circuitpython-build-bundles --filename_prefix ${{ steps.repo-name.outputs.repo-name }} --library_location .
84+
run: circuitpython-build-bundles --filename_prefix ${{ steps.repo-name.outputs.repo-name }} --library_location . ${{ steps.package-prefix-arg.outputs.prefix-arg }}
7085
- name: Archive bundles
7186
uses: actions/upload-artifact@v3
7287
with:

0 commit comments

Comments
 (0)