-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: Store project version in version.txt * fix: Remove cargo-deb metadata section in `zenoh-jni` * feat: Add `bump-and-tag.bash` script * chore: Rename release workflow to pre-release * chore: Disable release event on publish workflows * fix: Typo in ci/scripts * feat: Automate Release * chore: Remove enforce-linking-issues workflow * fix: Set permissions for publishing jobs * feat: Add publish-dokka to release workflow * fix: Set release branch in publishing jobs * fix: Make `branch` input unrequired in publishing jobs * style: Uniformize publishing workflow names * fix: Unecessary use of `BOT_TOKEN_WORKFLOW` * fix: Incorrect Cargo manifest/lockfile path * fix: Add missing `live-run` input for publish-dokka job * fix: Typo in pre-release workflow name * fix: Remove `if: always()` in publish-github job * fix: Remove unecessary SSH passphrase/privatekey inputs * chore: Retrigger CI * fix: Support jq 1.6 ubuntu-22.04 runners use jq 1.6 which doesn't recognize a dot for `[]` value iterator. See: jqlang/jq#1168.
- Loading branch information
1 parent
59ce031
commit 1238f92
Showing
11 changed files
with
251 additions
and
78 deletions.
There are no files selected for viewing
This file contains 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
This file was deleted.
Oops, something went wrong.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
name: Pre-Release | ||
|
||
on: | ||
schedule: | ||
- cron: "0 1 * * 1-5" | ||
workflow_dispatch: | ||
|
||
env: | ||
CARGO_TERM_COLOR: always | ||
|
||
jobs: | ||
release: | ||
name: Build on ${{ matrix.os }} | ||
runs-on: ["${{ matrix.os }}"] | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ubuntu-latest, macOS-latest] | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- uses: actions/setup-java@v3 | ||
with: | ||
distribution: temurin | ||
java-version: 11 | ||
|
||
- uses: nttld/setup-ndk@v1 | ||
id: setup-ndk | ||
with: | ||
ndk-version: r26 | ||
add-to-path: false | ||
link-to-sdk: true | ||
|
||
- name: Install Rust toolchain | ||
run: | | ||
rustup show | ||
rustup component add rustfmt clippy | ||
- name: Cargo Format | ||
working-directory: zenoh-jni | ||
run: cargo fmt --all --check | ||
|
||
- name: Clippy Check | ||
working-directory: zenoh-jni | ||
run: cargo clippy --all-targets --all-features -- -D warnings | ||
|
||
- name: Check for feature leaks | ||
working-directory: zenoh-jni | ||
run: cargo test --no-default-features | ||
|
||
- name: Build Zenoh-JNI | ||
working-directory: zenoh-jni | ||
run: cargo build | ||
|
||
- name: Setup Gradle | ||
uses: gradle/gradle-build-action@v2 | ||
|
||
- name: Gradle Test | ||
run: gradle jvmTest --info |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,62 +1,102 @@ | ||
# | ||
# Copyright (c) 2022 ZettaScale Technology | ||
# | ||
# This program and the accompanying materials are made available under the | ||
# terms of the Eclipse Public License 2.0 which is available at | ||
# http://www.eclipse.org/legal/epl-2.0, or the Apache License, Version 2.0 | ||
# which is available at https://www.apache.org/licenses/LICENSE-2.0. | ||
# | ||
# SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 | ||
# | ||
# Contributors: | ||
# ZettaScale Zenoh Team, <[email protected]> | ||
# | ||
name: Release | ||
|
||
on: | ||
release: | ||
types: [published] | ||
schedule: | ||
- cron: "0 1 * * 1-5" | ||
- cron: "0 0 * * 1-5" | ||
workflow_dispatch: | ||
|
||
env: | ||
CARGO_TERM_COLOR: always | ||
inputs: | ||
live-run: | ||
type: boolean | ||
description: Live-run | ||
required: false | ||
version: | ||
type: string | ||
description: Release number | ||
required: false | ||
zenoh-version: | ||
type: string | ||
description: Release number of Zenoh | ||
required: false | ||
|
||
jobs: | ||
release: | ||
name: Build on ${{ matrix.os }} | ||
runs-on: [ "${{ matrix.os }}" ] | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ ubuntu-latest, macOS-latest ] | ||
|
||
tag: | ||
name: Branch, Bump & tag | ||
runs-on: ubuntu-latest | ||
outputs: | ||
version: ${{ steps.create-release-branch.outputs.version }} | ||
branch: ${{ steps.create-release-branch.outputs.branch }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- uses: actions/setup-java@v3 | ||
- id: create-release-branch | ||
uses: eclipse-zenoh/ci/create-release-branch@main | ||
with: | ||
distribution: temurin | ||
java-version: 11 | ||
repo: ${{ github.repository }} | ||
live-run: ${{ inputs.live-run || false }} | ||
version: ${{ inputs.version }} | ||
github-token: ${{ secrets.BOT_TOKEN_WORKFLOW }} | ||
|
||
- uses: nttld/setup-ndk@v1 | ||
id: setup-ndk | ||
- name: Checkout this repository | ||
uses: actions/checkout@v4 | ||
with: | ||
ndk-version: r26 | ||
add-to-path: false | ||
link-to-sdk: true | ||
|
||
- name: Install Rust toolchain | ||
run: | | ||
rustup show | ||
rustup component add rustfmt clippy | ||
ref: ${{ steps.create-release-branch.outputs.branch }} | ||
|
||
- name: Cargo Format | ||
working-directory: zenoh-jni | ||
run: cargo fmt --all --check | ||
- name: Bump and tag project | ||
run: bash ci/scripts/bump-and-tag.bash | ||
env: | ||
VERSION: ${{ steps.create-release-branch.outputs.version }} | ||
BUMP_DEPS_VERSION: ${{ inputs.zenoh-version }} | ||
BUMP_DEPS_PATTERN: ${{ inputs.zenoh-version && 'zenoh.*' || '' }} | ||
BUMP_DEPS_BRANCH: ${{ inputs.zenoh-version && format('release/{0}', inputs.zenoh-version) || '' }} | ||
GIT_USER_NAME: eclipse-zenoh-bot | ||
GIT_USER_EMAIL: [email protected] | ||
|
||
- name: Clippy Check | ||
working-directory: zenoh-jni | ||
run: cargo clippy --all-targets --all-features -- -D warnings | ||
publish-jvm: | ||
name: Publish JVM package | ||
needs: tag | ||
uses: ./.github/workflows/publish-jvm.yml | ||
with: | ||
snapshot: ${{ !(inputs.live-run || false) }} | ||
permissions: | ||
contents: read | ||
packages: write | ||
|
||
- name: Check for feature leaks | ||
working-directory: zenoh-jni | ||
run: cargo test --no-default-features | ||
publish-android: | ||
name: Publish Android package | ||
needs: tag | ||
uses: ./.github/workflows/publish-android.yml | ||
with: | ||
snapshot: ${{ !(inputs.live-run || false) }} | ||
permissions: | ||
contents: read | ||
packages: write | ||
|
||
- name: Build Zenoh-JNI | ||
working-directory: zenoh-jni | ||
run: cargo build | ||
publish-dokka: | ||
name: Publish documentation | ||
needs: tag | ||
uses: ./.github/workflows/publish-dokka.yml | ||
with: | ||
live-run: ${{ inputs.live-run || false }} | ||
|
||
- name: Setup Gradle | ||
uses: gradle/gradle-build-action@v2 | ||
|
||
- name: Gradle Test | ||
run: gradle jvmTest --info | ||
publish-github: | ||
needs: tag | ||
runs-on: macos-latest | ||
steps: | ||
- uses: eclipse-zenoh/ci/publish-crates-github@main | ||
with: | ||
repo: ${{ github.repository }} | ||
live-run: ${{ inputs.live-run || false }} | ||
version: ${{ needs.tag.outputs.version }} | ||
branch: ${{ needs.tag.outputs.branch }} | ||
github-token: ${{ secrets.BOT_TOKEN_WORKFLOW }} |
This file contains 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
Oops, something went wrong.