|
| 1 | +# generated by nickel/ci.ncl; do not manually edit |
| 2 | +env: |
| 3 | + CARGO_TERM_COLOR: always |
| 4 | + RUSTDOCFLAGS: --deny warnings |
| 5 | + RUSTFLAGS: --deny warnings |
| 6 | +jobs: |
| 7 | + assert_nickels_synced_: |
| 8 | + name: assert_nickels_synced_ |
| 9 | + runs-on: ubuntu-latest |
| 10 | + steps: |
| 11 | + - name: checkout repo |
| 12 | + uses: actions/checkout@v4 |
| 13 | + with: |
| 14 | + submodules: true |
| 15 | + - name: install nix |
| 16 | + uses: cachix/install-nix-action@v30 |
| 17 | + - name: nickel binary cache |
| 18 | + uses: cachix/cachix-action@v15 |
| 19 | + with: |
| 20 | + name: tweag-nickel |
| 21 | + - name: install nickel |
| 22 | + run: |- |
| 23 | + nix profile install github:tweag/nickel |
| 24 | + echo "$HOME/.nix-profile/bin" >> $GITHUB_PATH |
| 25 | + nickel --version |
| 26 | + - name: install just |
| 27 | + uses: extractions/setup-just@v2 |
| 28 | + - name: assert nickels synced |
| 29 | + run: |- |
| 30 | + just format_nickels sync_nickels |
| 31 | + [[ -n $(git status --porcelain) ]] && echo 'nickels are not synced; run `just format_nickels sync_nickels`' && exit 1 || exit 0 |
| 32 | + check_all_features: |
| 33 | + name: check_all_features |
| 34 | + needs: assert_nickels_synced_ |
| 35 | + runs-on: ubuntu-latest |
| 36 | + steps: |
| 37 | + - name: checkout repo |
| 38 | + uses: actions/checkout@v4 |
| 39 | + with: |
| 40 | + submodules: true |
| 41 | + - name: install rust toolchain |
| 42 | + uses: dtolnay/rust-toolchain@master |
| 43 | + with: |
| 44 | + toolchain: stable |
| 45 | + - name: install bevy dependencies |
| 46 | + run: sudo apt-get update && sudo apt-get install --no-install-recommends libasound2-dev libudev-dev libwayland-dev libxkbcommon-dev |
| 47 | + shell: bash |
| 48 | + - name: populated target directory from cache |
| 49 | + uses: Leafwing-Studios/cargo-cache@v2 |
| 50 | + with: |
| 51 | + sweep-cache: true |
| 52 | + - name: install just |
| 53 | + uses: extractions/setup-just@v2 |
| 54 | + - name: install binstall |
| 55 | + uses: cargo-bins/cargo-binstall@main |
| 56 | + - name: install cargo all features |
| 57 | + run: cargo binstall --no-confirm cargo-all-features |
| 58 | + - name: check all features |
| 59 | + run: just check_all_features |
| 60 | + clippy: |
| 61 | + name: clippy |
| 62 | + needs: assert_nickels_synced_ |
| 63 | + runs-on: ubuntu-latest |
| 64 | + steps: |
| 65 | + - name: checkout repo |
| 66 | + uses: actions/checkout@v4 |
| 67 | + with: |
| 68 | + submodules: true |
| 69 | + - name: install rust toolchain |
| 70 | + uses: dtolnay/rust-toolchain@master |
| 71 | + with: |
| 72 | + components: clippy |
| 73 | + toolchain: stable |
| 74 | + - name: install bevy dependencies |
| 75 | + run: sudo apt-get update && sudo apt-get install --no-install-recommends libasound2-dev libudev-dev libwayland-dev libxkbcommon-dev |
| 76 | + shell: bash |
| 77 | + - name: populated target directory from cache |
| 78 | + uses: Leafwing-Studios/cargo-cache@v2 |
| 79 | + with: |
| 80 | + sweep-cache: true |
| 81 | + - name: install just |
| 82 | + uses: extractions/setup-just@v2 |
| 83 | + - name: run clippy |
| 84 | + run: just clippy |
| 85 | + docs: |
| 86 | + name: docs |
| 87 | + needs: assert_nickels_synced_ |
| 88 | + runs-on: ubuntu-latest |
| 89 | + steps: |
| 90 | + - name: checkout repo |
| 91 | + uses: actions/checkout@v4 |
| 92 | + with: |
| 93 | + submodules: true |
| 94 | + - name: install rust toolchain |
| 95 | + uses: dtolnay/rust-toolchain@master |
| 96 | + with: |
| 97 | + toolchain: nightly |
| 98 | + - name: install bevy dependencies |
| 99 | + run: sudo apt-get update && sudo apt-get install --no-install-recommends libasound2-dev libudev-dev libwayland-dev libxkbcommon-dev |
| 100 | + shell: bash |
| 101 | + - name: populated target directory from cache |
| 102 | + uses: Leafwing-Studios/cargo-cache@v2 |
| 103 | + with: |
| 104 | + sweep-cache: true |
| 105 | + - name: install just |
| 106 | + uses: extractions/setup-just@v2 |
| 107 | + - name: check docs |
| 108 | + run: just doc |
| 109 | + format: |
| 110 | + name: format |
| 111 | + needs: assert_nickels_synced_ |
| 112 | + runs-on: ubuntu-latest |
| 113 | + steps: |
| 114 | + - name: checkout repo |
| 115 | + uses: actions/checkout@v4 |
| 116 | + with: |
| 117 | + submodules: true |
| 118 | + - name: install rust toolchain |
| 119 | + uses: dtolnay/rust-toolchain@master |
| 120 | + with: |
| 121 | + components: rustfmt |
| 122 | + toolchain: nightly |
| 123 | + - name: install just |
| 124 | + uses: extractions/setup-just@v2 |
| 125 | + - name: run format |
| 126 | + run: just format -- --check |
| 127 | + test: |
| 128 | + name: test |
| 129 | + needs: assert_nickels_synced_ |
| 130 | + runs-on: ubuntu-latest |
| 131 | + steps: |
| 132 | + - name: checkout repo |
| 133 | + uses: actions/checkout@v4 |
| 134 | + with: |
| 135 | + submodules: true |
| 136 | + - name: install rust toolchain |
| 137 | + uses: dtolnay/rust-toolchain@master |
| 138 | + with: |
| 139 | + toolchain: stable |
| 140 | + - name: install bevy dependencies |
| 141 | + run: sudo apt-get update && sudo apt-get install --no-install-recommends libasound2-dev libudev-dev libwayland-dev libxkbcommon-dev |
| 142 | + shell: bash |
| 143 | + - name: populated target directory from cache |
| 144 | + uses: Leafwing-Studios/cargo-cache@v2 |
| 145 | + with: |
| 146 | + sweep-cache: true |
| 147 | + - name: install just |
| 148 | + uses: extractions/setup-just@v2 |
| 149 | + - name: run tests |
| 150 | + run: just test |
| 151 | +name: ci |
| 152 | +on: push |
0 commit comments