Skip to content

Commit 9b62f43

Browse files
committed
use build-tools pkg-prefix option correctly
1 parent 55cdc39 commit 9b62f43

File tree

2 files changed

+18
-2
lines changed

2 files changed

+18
-2
lines changed

.github/workflows/build.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,14 @@ jobs:
9393
tr '_' '-'
9494
)
9595
96+
- name: Translate Repo Name For Build Tools package_prefix
97+
id: pkg-name
98+
run: |
99+
echo ::set-output name=pkg-name::$(
100+
echo ${{ github.repository }} |
101+
awk -F '\/' '{ print tolower($2) }'
102+
)
103+
96104
- uses: actions/checkout@v3
97105

98106
- name: Set up Python 3.x
@@ -104,7 +112,7 @@ jobs:
104112
run: pip install circuitpython-build-tools
105113

106114
- name: Build assets
107-
run: circuitpython-build-bundles --filename_prefix ${{ steps.repo-name.outputs.repo-name }} --package_folder_prefix "" --library_location .
115+
run: circuitpython-build-bundles --filename_prefix ${{ steps.repo-name.outputs.repo-name }} --package_folder_prefix ${{ steps.pkg-name.outputs.pkg-name }} --library_location .
108116

109117
- name: Archive bundles
110118
uses: actions/upload-artifact@v3

.github/workflows/release.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,14 @@ jobs:
2323
tr '_' '-'
2424
)
2525
26+
- name: Translate Repo Name For Build Tools package_prefix
27+
id: pkg-name
28+
run: |
29+
echo ::set-output name=pkg-name::$(
30+
echo ${{ github.repository }} |
31+
awk -F '\/' '{ print tolower($2) }'
32+
)
33+
2634
- name: Set up Python 3.x
2735
uses: actions/setup-python@v2
2836
with:
@@ -45,7 +53,7 @@ jobs:
4553
source actions-ci/install.sh
4654
4755
- name: Build assets
48-
run: circuitpython-build-bundles --filename_prefix ${{ steps.repo-name.outputs.repo-name }} --package_folder_prefix "" --library_location .
56+
run: circuitpython-build-bundles --filename_prefix ${{ steps.repo-name.outputs.repo-name }} --package_folder_prefix ${{ steps.pkg-name.outputs.pkg-name }} --library_location .
4957

5058
- name: Upload Release Assets
5159
# the 'official' actions version does not yet support dynamically

0 commit comments

Comments
 (0)