Skip to content

Commit de3cfd5

Browse files
committed
Add release workflow
1 parent 50b237a commit de3cfd5

File tree

5 files changed

+133
-2
lines changed

5 files changed

+133
-2
lines changed

.github/RELEASE_TEMPLATE.md

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
Module Name: baselibs
2+
Release Tag: $RELEASE_TAG
3+
Origin Release Tag: $PREVIOUS_RELEASE_TAG
4+
Release Commit Hash: $COMMIT_SHA
5+
Release Date: $RELEASE_DATE
6+
7+
Overview
8+
--------
9+
The baselibs module provides a selection of basic C++ utility libraries for common use in the S-CORE project.
10+
11+
12+
Disclaimer
13+
----------
14+
This release is not intended for production use, as it does not include a safety argumentation or a completed safety assessment.
15+
The work products compiled in the safety package are created with care according to the [S-CORE process](https://eclipse-score.github.io/process_description/main/index.html). However, as a non-profit, open-source organization, the project cannot assume any liability for its content.
16+
17+
For details on the features, see https://eclipse-score.github.io/score/main/features/baselibs/index.html
18+
19+
Improvements
20+
------------
21+
22+
23+
Bug Fixes
24+
---------
25+
26+
27+
Compatibility
28+
-------------
29+
- `x86_64-unknown-linux-gnu`, `x86_64-unknown-nto-qnx800` and `aarch64-unknown-nto-qnx800` using [score_toolchains_gcc](https://github.com/eclipse-score/bazel_cpp_toolchains).
30+
31+
Performed Verification
32+
----------------------
33+
- Build for `x86_64-unknown-linux-gnu` and `x86_64-unknown-nto-qnx800`.
34+
- Unit tests executed on `x86_64-unknown-linux-gnu`.
35+
36+
Report: $ACTION_RUN_URL
37+
38+
Known Issues
39+
------------
40+
41+
42+
43+
Upgrade Instructions
44+
--------------------
45+
Backward compatibility with the previous release is not guaranteed.
46+
47+
Contact Information
48+
-------------------
49+
For any questions or support, please contact the Base Libs Feature Team (https://github.com/orgs/eclipse-score/discussions/1223) or raise an issue/discussion.

.github/workflows/build_linux.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ on:
1919
- main
2020
merge_group:
2121
types: [checks_requested]
22+
workflow_call:
2223
jobs:
2324
linux-build-and-test:
2425
runs-on: ubuntu-latest

.github/workflows/build_qnx.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,14 @@ on:
1919
- main
2020
merge_group:
2121
types: [checks_requested]
22+
workflow_call:
2223
jobs:
2324
qnx-build:
2425
strategy:
2526
fail-fast: false
2627
matrix:
2728
bazel-config: [bl-x86_64-qnx, bl-aarch64-qnx]
28-
uses: eclipse-score/cicd-workflows/.github/workflows/qnx-build.yml@main
29+
uses: eclipse-score/cicd-workflows/.github/workflows/qnx-build.yml@fail_qnx_on_empty_secret
2930
permissions:
3031
contents: read
3132
pull-requests: read

.github/workflows/coverage_report.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ on:
1919
- main
2020
merge_group:
2121
types: [checks_requested]
22+
workflow_call:
2223
jobs:
2324
coverage-report:
2425
runs-on: ubuntu-22.04
@@ -40,7 +41,7 @@ jobs:
4041
cache-save: ${{ github.event_name == 'push' }}
4142
- name: Run Bazel Coverage
4243
run: |
43-
bazel coverage --config=bl-x86_64-linux -- //score/... \
44+
bazel coverage --config=bl-x86_64-linux -- //score/result/... \
4445
-//score/language/safecpp/aborts_upon_exception:abortsuponexception_toolchain_test
4546
- name: Generate HTML Coverage Report
4647
run: |

.github/workflows/release.yml

Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
# *******************************************************************************
2+
# Copyright (c) 2026 Contributors to the Eclipse Foundation
3+
#
4+
# See the NOTICE file(s) distributed with this work for additional
5+
# information regarding copyright ownership.
6+
#
7+
# This program and the accompanying materials are made available under the
8+
# terms of the Apache License Version 2.0 which is available at
9+
# https://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# SPDX-License-Identifier: Apache-2.0
12+
# *******************************************************************************
13+
name: Release
14+
run-name: Release ${{ inputs.tag }}
15+
on:
16+
pull_request:
17+
workflow_dispatch:
18+
inputs:
19+
tag:
20+
description: 'Release tag (e.g., v1.0.0)'
21+
required: true
22+
type: string
23+
concurrency:
24+
group: release
25+
jobs:
26+
#build-linux:
27+
# uses: ./.github/workflows/build_linux.yml
28+
#build-qnx:
29+
# uses: ./.github/workflows/build_qnx.yml
30+
# permissions:
31+
# contents: read
32+
# pull-requests: read
33+
# secrets: inherit
34+
coverage-report:
35+
uses: ./.github/workflows/coverage_report.yml
36+
create-release:
37+
#needs: [build-linux, build-qnx, coverage-report]
38+
needs: [coverage-report]
39+
runs-on: ubuntu-latest
40+
permissions:
41+
contents: write
42+
env:
43+
COVERAGE_ARCHIVE: ${{ github.event.repository.name }}-v0.0.0-coverage
44+
steps:
45+
- name: Checkout Repository
46+
uses: actions/checkout@v6
47+
- name: Get Current Date and Previous Release Tag
48+
env:
49+
GH_TOKEN: ${{ github.token }}
50+
run: |
51+
PREVIOUS_TAG=$(gh release view --json tagName --jq '.tagName' 2>/dev/null || echo "N/A")
52+
echo "RELEASE_DATE=$(date --rfc-3339=date)" >> $GITHUB_ENV
53+
echo "PREVIOUS_RELEASE_TAG=$PREVIOUS_TAG" >> $GITHUB_ENV
54+
- name: Generate Release Body
55+
env:
56+
RELEASE_TAG: ${{ inputs.tag }}
57+
COMMIT_SHA: ${{ github.sha }}
58+
ACTION_RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
59+
run: |
60+
envsubst '$RELEASE_TAG $PREVIOUS_RELEASE_TAG $COMMIT_SHA $RELEASE_DATE $ACTION_RUN_URL' < .github/RELEASE_TEMPLATE.md > release_body.md
61+
- name: Download Coverage Report Artifact
62+
uses: actions/download-artifact@v7
63+
with:
64+
name: ${{ github.event.repository.name }}_coverage_report
65+
path: ${{ env.COVERAGE_ARCHIVE }}
66+
- name: Create Coverage Report Archive
67+
run: |
68+
tar --sort=name --owner=0 --group=0 --numeric-owner \
69+
-cJf "$COVERAGE_ARCHIVE.tar.xz" --directory="$COVERAGE_ARCHIVE" .
70+
- name: Create Draft Release
71+
uses: softprops/action-gh-release@v2
72+
with:
73+
tag_name: "v0.0.0" # ${{ inputs.tag }}
74+
body_path: release_body.md
75+
draft: true
76+
generate_release_notes: true
77+
target_commitish: ${{ github.sha }}
78+
files: |
79+
${{ env.COVERAGE_ARCHIVE }}.tar.xz

0 commit comments

Comments
 (0)