ci: unify snapshot and release delivery in one CD workflow - #178
Merged
Merged
Conversation
Fold publication into cd.yml, gate firmware and SDK builds on host checks, and ship the API reference with each package and website build instead of restoring historical archives. Signed-off-by: Francesco Pace <francesco.pace@gmail.com>
Comment on lines
31
to
-35
| @@ -68,7 +54,7 @@ runs: | |||
|
|
|||
| - name: Generate SDK API reference | |||
| shell: bash | |||
| run: python3 .github/scripts/generate_sdk_api.py --archive-dir .cache/sdk-api | |||
Comment on lines
-555
to
-566
| --firmware-dir preview-firmware \ | ||
| --output-dir docs/web/artifacts/firmware/preview \ | ||
| --channel preview \ | ||
| --version "$(python3 .github/scripts/detect_git_version.py --from-sdk-dir preview-sdk)" \ | ||
| --release-tag snapshot \ | ||
| --url-prefix /artifacts/firmware/preview \ | ||
| --commit "${{ needs.validate-run.outputs.head_sha }}" | ||
|
|
||
| - name: Stage preview web SDK | ||
| --firmware-dir published-firmware \ | ||
| --output-dir "docs/web/artifacts/firmware/$CHANNEL" \ | ||
| --channel "$CHANNEL" \ | ||
| --version "$VERSION" \ | ||
| --release-tag "$RELEASE_TAG" \ | ||
| --url-prefix "/artifacts/firmware/$CHANNEL" \ | ||
| --commit "${{ fromJSON(needs.release.outputs.metadata).head_sha }}" | ||
|
|
||
| - name: Stage publication web SDK | ||
| run: | | ||
| python .github/scripts/stage_web_sdk.py \ | ||
| --sdk-dir preview-sdk \ |
Comment on lines
573
to
+586
| @@ -534,6 +583,19 @@ jobs: | |||
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |||
| GH_REPO: ${{ github.repository }} | |||
|
|
|||
| - name: Stage published preview channel | |||
| if: fromJSON(needs.release.outputs.metadata).channel != 'preview' | |||
| id: preview-assets | |||
| uses: ./.github/actions/stage-published-web-channel | |||
| with: | |||
| release-tag: snapshot | |||
| channel: preview | |||
| firmware-output-dir: docs/web/artifacts/firmware/preview | |||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fold publication into cd.yml, gate firmware and SDK builds on host checks, and ship the API reference with each package and website build instead of restoring historical archives.
Description
Improve CI/CD
Affected Area
Type of Change
Related Issues
Closes #
Changes Made
Testing
Checklist
Signed-off-bytrailers (git commit -s).github/cla-signatures.json(first PR only; see CLA.md for how to sign)