From 7f764dcff227dfee075a8210bc7ed10ae3623d05 Mon Sep 17 00:00:00 2001 From: Mahmoud Mazouz Date: Thu, 11 Jan 2024 18:00:28 +0100 Subject: [PATCH 1/5] chore: Rename Cargo config file --- .cargo/{config => config.toml} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .cargo/{config => config.toml} (100%) diff --git a/.cargo/config b/.cargo/config.toml similarity index 100% rename from .cargo/config rename to .cargo/config.toml From 6cebd1e9acf89972912ef1cee7e2f25ec5576942 Mon Sep 17 00:00:00 2001 From: Mahmoud Mazouz Date: Thu, 11 Jan 2024 18:01:16 +0100 Subject: [PATCH 2/5] chore: Reduce status checks in ci.yml --- .github/workflows/ci.yml | 47 +++++++++++++++++++++++++--------------- 1 file changed, 30 insertions(+), 17 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f3f3986..985e8e0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,16 +16,15 @@ name: CI on: push: branches: - - '**' + - "**" pull_request: branches: - - '**' + - "**" schedule: - - cron: '0 6 * * 1-5' + - cron: "0 6 * * 1-5" jobs: build: - name: Build on ${{ matrix.os }} runs-on: ${{ matrix.os }} strategy: @@ -34,21 +33,35 @@ jobs: os: [ubuntu-latest, macOS-latest, windows-latest] steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v4 + + - name: Install Rust toolchain + run: | + rustup show + rustup component add rustfmt clippy - - name: Install Rust toolchain - run: | - rustup show - rustup component add rustfmt clippy + - name: Code format check + run: cargo fmt --check - - name: Code format check - run: cargo fmt --check + - name: Clippy + run: cargo clippy --all --examples -- -D warnings - - name: Clippy - run: cargo clippy --all --examples -- -D warnings + - name: Build + run: cargo build --verbose --all-targets - - name: Build - run: cargo build --verbose --all-targets + - name: Run tests + run: cargo test --verbose - - name: Run tests - run: cargo test --verbose + # NOTE: In GitHub repository settings, the "Require status checks to pass + # before merging" branch protection rule ensures that commits are only merged + # from branches where specific status checks have passed. These checks are + # specified manually as a list of workflow job names. Thus we use this extra + # job to signal whether all CI checks have passed. + ci: + name: CI status checks + runs-on: ubuntu-latest + needs: build + if: always() + steps: + - name: Check whether all jobs pass + run: echo '${{ toJson(needs) }}' | jq -e 'all(.result == "success")' From 5d52bd2b9ec96d4074179f236d3eff15dd96fb5b Mon Sep 17 00:00:00 2001 From: Mahmoud Mazouz Date: Thu, 11 Jan 2024 18:04:03 +0100 Subject: [PATCH 3/5] fix: Missing .git suffix --- Cargo.toml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index d4d97b7..218106f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -48,9 +48,11 @@ log = "0.4.17" serde = "1.0.154" serde_json = "1.0.94" tide = "0.16.0" -zenoh = { git = "https://github.com/eclipse-zenoh/zenoh", branch = "master", features = ["unstable"] } -zenoh-core = { git = "https://github.com/eclipse-zenoh/zenoh", branch = "master" } -zenoh-plugin-trait = { git = "https://github.com/eclipse-zenoh/zenoh", branch = "master", default-features = false } +zenoh = { git = "https://github.com/eclipse-zenoh/zenoh.git", branch = "master", features = [ + "unstable", +] } +zenoh-core = { git = "https://github.com/eclipse-zenoh/zenoh.git", branch = "master" } +zenoh-plugin-trait = { git = "https://github.com/eclipse-zenoh/zenoh.git", branch = "master", default-features = false } [build-dependencies] rustc_version = "0.4.0" From 34a0baca67ff6dc6384a2da4b4d9f5808e00ba41 Mon Sep 17 00:00:00 2001 From: Mahmoud Mazouz Date: Thu, 11 Jan 2024 18:04:41 +0100 Subject: [PATCH 4/5] fix: Specify zenoh dep version --- Cargo.toml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 218106f..cfb0597 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -48,11 +48,11 @@ log = "0.4.17" serde = "1.0.154" serde_json = "1.0.94" tide = "0.16.0" -zenoh = { git = "https://github.com/eclipse-zenoh/zenoh.git", branch = "master", features = [ +zenoh = { version = "0.11.0-dev", git = "https://github.com/eclipse-zenoh/zenoh.git", branch = "master", features = [ "unstable", ] } -zenoh-core = { git = "https://github.com/eclipse-zenoh/zenoh.git", branch = "master" } -zenoh-plugin-trait = { git = "https://github.com/eclipse-zenoh/zenoh.git", branch = "master", default-features = false } +zenoh-core = { version = "0.11.0-dev", git = "https://github.com/eclipse-zenoh/zenoh.git", branch = "master" } +zenoh-plugin-trait = { version = "0.11.0-dev", git = "https://github.com/eclipse-zenoh/zenoh.git", branch = "master", default-features = false } [build-dependencies] rustc_version = "0.4.0" From f08aa9d40d52abace1c2256bb7b0dc04a150fabe Mon Sep 17 00:00:00 2001 From: Mahmoud Mazouz Date: Thu, 11 Jan 2024 18:05:08 +0100 Subject: [PATCH 5/5] fix: Missing zenohd deb revision --- Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Cargo.toml b/Cargo.toml index cfb0597..8cb590f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -63,4 +63,4 @@ maintainer = "zenoh-dev@eclipse.org" copyright = "2017, 2022 ZettaScale Technology" section = "net" license-file = ["LICENSE", "0"] -depends = "zenohd (=0.11.0-dev)" +depends = "zenohd (=0.11.0-dev-1)"