-
Notifications
You must be signed in to change notification settings - Fork 0
55 lines (48 loc) · 1.41 KB
/
rust-workflow.yml
File metadata and controls
55 lines (48 loc) · 1.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
# SPDX-FileCopyrightText: 2025 Famedly GmbH (info@famedly.com)
#
# SPDX-License-Identifier: Apache-2.0
name: Rust
# Trigger the CI on any tags, pushes to any branch and PRs to any branch.
on:
push:
branches: [ "main" ]
tags: [ "*" ]
pull_request:
branches: [ "*" ]
# Make sure there is no pipeline running uselessly.
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
# Environment variables for all jobs.
env:
CARGO_TERM_COLOR: always
# Defined CI jobs.
jobs:
compliance:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: REUSE Compliance Check
uses: fsfe/reuse-action@v5
- name: Dependency license check
uses: EmbarkStudios/cargo-deny-action@v2
with:
command: check bans licenses sources
rust:
needs: compliance
uses: famedly/backend-build-workflows/.github/workflows/rust-workflow.yml@v2
secrets: inherit
with:
clippy_args: '--all-features'
test_args: '--all-features'
testcov_args: '--all-features'
ref: v2
publish:
needs: rust
uses: famedly/backend-build-workflows/.github/workflows/publish-crate.yml@v2
with:
registry-name: "crates-io"
registry-index: "https://github.com/rust-lang/crates.io-index"
secrets:
CI_SSH_PRIVATE_KEY: ${{ secrets.CI_SSH_PRIVATE_KEY }}
registry-auth-token: ${{ secrets.CRATES_IO_TOKEN }}