Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
loki077 committed Dec 30, 2024
1 parent 874d662 commit d813af0
Showing 1 changed file with 26 additions and 4 deletions.
30 changes: 26 additions & 4 deletions .github/workflows/carbonix_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -459,15 +459,37 @@ jobs:
build-upload-zip:
runs-on: ubuntu-22.04
if: ${{ !contains(github.event.pull_request.labels.*.name, 'SKIP_BUILD') }}
needs: [build-periph, build-sitl, collect-aircraft-config-files, setup-s3-path]
needs: [process-ac, build-sitl, s3-path]
steps:
- name: Create folder from s3_path
run: mkdir -p ${{ needs.setup-s3-path.outputs.s3_path }}

- name: Download build artifacts
- name: List available artifacts
id: list-artifacts
uses: actions/github-script@v6
with:
script: |
const artifacts = await github.actions.listArtifactsForRepo({
owner: context.repo.owner,
repo: context.repo.repo,
});
return artifacts.data.artifacts.map(artifact => artifact.name);
- name: Filter artifacts
id: filter-artifacts
run: |
echo "Filtered artifacts:" > filtered_artifacts.txt
for artifact in ${{ steps.list-artifacts.outputs.result }}; do
if [[ $artifact =~ .*_AC_.*[0-9]+(\.[0-9]+)? ]]; then
echo $artifact >> filtered_artifacts.txt
fi
done
cat filtered_artifacts.txt
- name: Download filtered artifacts
uses: actions/download-artifact@v4
with:
name: output-ac-*
name: ${{ steps.filter-artifacts.outputs.result }}
path: ${{ needs.setup-s3-path.outputs.s3_path }}

- name: List downloaded files
Expand All @@ -482,5 +504,5 @@ jobs:
uses: actions/upload-artifact@v4
with:
name: zipped-artifacts
path: artifact.zip
path: ${{ needs.setup-s3-path.outputs.s3_path }}.zip
retention-days: 15

0 comments on commit d813af0

Please sign in to comment.