Unverified Commit 13f22553 authored by Silvano Cerza's avatar Silvano Cerza Committed by GitHub

Add task to collect proto files and add steps to release them with tester,...

Add task to collect proto files and add steps to release them with tester, nightly and stable builds (#1931)

* Add task to zip all .proto files for release

* Add proto files in nightly released files

* Add proto files in tester released files

* Add proto files in stable released files

* Fix tester build workflow

* Fix checksums.txt creation in tester and stable build releases

* Change build job of tester build workflow to be generic

* Fix Publish Tester Build job dependencies
parent f2397543
......@@ -236,6 +236,15 @@ jobs:
name: ${{ env.ARTIFACT_NAME }}
path: ${{ env.DIST_DIR }}
- name: Install Task
uses: arduino/setup-task@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
version: 3.x
- name: Collect proto files
run: task protoc:collect
- name: Create checksum file
working-directory: ${{ env.DIST_DIR}}
run: |
......
......@@ -71,41 +71,44 @@ jobs:
echo "prefix=$PACKAGE_NAME_PREFIX" >> $GITHUB_OUTPUT
build:
create-artifacts:
needs: package-name-prefix
name: Build ${{ matrix.os.name }}
name: Create artifact ${{ matrix.artifact.name }}
runs-on: ubuntu-latest
strategy:
matrix:
os:
- task: Windows_32bit
artifact:
- task: dist:Windows_32bit
path: "*Windows_32bit.zip"
name: Windows_X86-32
- task: Windows_64bit
- task: dist:Windows_64bit
path: "*Windows_64bit.zip"
name: Windows_X86-64
- task: Linux_32bit
- task: dist:Linux_32bit
path: "*Linux_32bit.tar.gz"
name: Linux_X86-32
- task: Linux_64bit
- task: dist:Linux_64bit
path: "*Linux_64bit.tar.gz"
name: Linux_X86-64
- task: Linux_ARMv6
- task: dist:Linux_ARMv6
path: "*Linux_ARMv6.tar.gz"
name: Linux_ARMv6
- task: Linux_ARMv7
- task: dist:Linux_ARMv7
path: "*Linux_ARMv7.tar.gz"
name: Linux_ARMv7
- task: Linux_ARM64
- task: dist:Linux_ARM64
path: "*Linux_ARM64.tar.gz"
name: Linux_ARM64
- task: macOS_64bit
- task: dist:macOS_64bit
path: "*macOS_64bit.tar.gz"
name: macOS_64
- task: macOS_ARM64
- task: dist:macOS_ARM64
path: "*macOS_ARM64.tar.gz"
name: macOS_ARM64
- task: protoc:collect
path: "*_proto.zip"
name: rpc-protocol-files
steps:
- name: Checkout repository
......@@ -123,18 +126,18 @@ jobs:
run: |
PACKAGE_NAME_PREFIX=${{ needs.package-name-prefix.outputs.prefix }}
export PACKAGE_NAME_PREFIX
task dist:${{ matrix.os.task }}
task ${{ matrix.artifact.task }}
# Transfer builds to artifacts job
- name: Upload build artifact
uses: actions/upload-artifact@v3
with:
path: ${{ env.DIST_DIR }}/${{ matrix.os.path }}
name: ${{ matrix.os.name }}
path: ${{ env.DIST_DIR }}/${{ matrix.artifact.path }}
name: ${{ matrix.artifact.name }}
checksums:
needs:
- build
- create-artifacts
- package-name-prefix
runs-on: ubuntu-latest
......
......@@ -241,6 +241,15 @@ jobs:
name: ${{ env.ARTIFACT_NAME }}
path: ${{ env.DIST_DIR }}
- name: Install Task
uses: arduino/setup-task@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
version: 3.x
- name: Collect proto files
run: task protoc:collect
- name: Create checksum file
working-directory: ${{ env.DIST_DIR}}
run: |
......
......@@ -215,6 +215,13 @@ tasks:
cmds:
- buf lint rpc
protoc:collect:
desc: Create a zip file containing all .proto files in DIST_DIR
dir: rpc
cmds:
- mkdir ../{{.DIST_DIR}}
- zip -r ../{{.DIST_DIR}}/{{.PROJECT_NAME}}_{{.VERSION}}_proto.zip * -i \*.proto
protoc:format:
desc: Perform formatting of the protobuf definitions
cmds:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment