File: ci.yml

package info (click to toggle)
rust-async-fs 2.1.3-2
  • links: PTS, VCS
  • area: main
  • in suites: experimental, forky, sid
  • size: 192 kB
  • sloc: makefile: 2; sh: 1
file content (75 lines) | stat: -rw-r--r-- 1,942 bytes parent folder | download
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
name: CI

permissions:
  contents: read

on:
  pull_request:
  push:
    branches:
      - master
  schedule:
    - cron: '0 2 * * 0'

env:
  CARGO_INCREMENTAL: 0
  CARGO_NET_GIT_FETCH_WITH_CLI: true
  CARGO_NET_RETRY: 10
  CARGO_TERM_COLOR: always
  RUST_BACKTRACE: 1
  RUSTFLAGS: -D warnings
  RUSTDOCFLAGS: -D warnings
  RUSTUP_MAX_RETRIES: 10

defaults:
  run:
    shell: bash

jobs:
  fmt:
    uses: smol-rs/.github/.github/workflows/fmt.yml@main
  clippy:
    uses: smol-rs/.github/.github/workflows/clippy.yml@main
    with:
      # Windows for windows module.
      additional-targets: x86_64-pc-windows-msvc
  security_audit:
    uses: smol-rs/.github/.github/workflows/security_audit.yml@main
    permissions:
      checks: write
      contents: read
      issues: write
    secrets: inherit

  test:
    runs-on: ${{ matrix.os }}
    strategy:
      fail-fast: false
      matrix:
        os: [ubuntu-latest, windows-latest, macos-latest]
        rust: [nightly, beta, stable]
    steps:
      - uses: actions/checkout@v4
      - name: Install Rust
        # --no-self-update is necessary because the windows environment cannot self-update rustup.exe.
        run: rustup update ${{ matrix.rust }} --no-self-update && rustup default ${{ matrix.rust }}
      - name: Install cargo-hack and cargo-minimal-versions
        uses: taiki-e/install-action@v2
        with:
          tool: cargo-hack,cargo-minimal-versions
      - run: cargo build --all --all-features --all-targets
      - run: cargo hack build --feature-powerset --no-dev-deps
      - run: cargo minimal-versions build --all --all-features
      - run: cargo test

  msrv:
    runs-on: ${{ matrix.os }}
    strategy:
      fail-fast: false
      matrix:
        os: [ubuntu-latest, windows-latest]
    steps:
      - uses: actions/checkout@v4
      - name: Install cargo-hack
        uses: taiki-e/install-action@cargo-hack
      - run: cargo hack build --rust-version