Skip to content
Myr

CICD.yml

This file

Path

.github/workflows/CICD.yml

277 lines · 9.5 KiB · YAML

Last changed by

build(deps): bump softprops/action-gh-release from 3.0.2 to 3.0.3dependabot[bot]before adoption0e01c8c

History of this file

Take it

The walk stopped after 200 commits: lines older than 86d6e2d point at it.

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 1–15why, one step back
1name: CICD
23env:4 CICD_INTERMEDIATES_DIR: "_cicd-intermediates"5 MSRV_FEATURES: "--all-features"67on:8 workflow_dispatch:9 pull_request:10 push:11 branches:12 - master13 tags:14 - '*'15

Merge pull request #1809 from tmccombs/attestationThayne McCombsbefore adoption97b3b04

line 16why, one step back
16permissions:

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

line 17why, one step back
17 contents: read

Merge pull request #1809 from tmccombs/attestationThayne McCombsbefore adoption97b3b04

line 18why, one step back
18

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 19–23why, one step back
19jobs:
20 crate_metadata:21 name: Extract crate metadata22 runs-on: ubuntu-latest23 steps:

Merge pull request #2073 from sharkdp/dependabot/github_actions/actions/checkout-7.0.1Thayne McCombsbefore adoptionca51233

line 24why, one step back
24 - uses: actions/checkout@v7.0.1

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

lines 25–26why, one step back
25 with:
26 persist-credentials: false

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 27–43why, one step back
27 - name: Extract crate information
28 id: crate_metadata29 run: |30 echo "name=fd" | tee -a $GITHUB_OUTPUT31 cargo metadata --no-deps --format-version 1 | jq -r '"version=" + .packages[0].version' | tee -a $GITHUB_OUTPUT32 cargo metadata --no-deps --format-version 1 | jq -r '"maintainer=" + .packages[0].authors[0]' | tee -a $GITHUB_OUTPUT33 cargo metadata --no-deps --format-version 1 | jq -r '"homepage=" + .packages[0].homepage' | tee -a $GITHUB_OUTPUT34 cargo metadata --no-deps --format-version 1 | jq -r '"msrv=" + .packages[0].rust_version' | tee -a $GITHUB_OUTPUT35 outputs:36 name: ${{ steps.crate_metadata.outputs.name }}37 version: ${{ steps.crate_metadata.outputs.version }}38 maintainer: ${{ steps.crate_metadata.outputs.maintainer }}39 homepage: ${{ steps.crate_metadata.outputs.homepage }}40 msrv: ${{ steps.crate_metadata.outputs.msrv }}4142 ensure_cargo_fmt:43 name: Ensure 'cargo fmt' has been run

Merge pull request #1712 from sharkdp/next-backThayne McCombsbefore adoptionabf4e47

line 44why, one step back
44 runs-on: ubuntu-22.04

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 45–48why, one step back
45 steps:
46 - uses: dtolnay/rust-toolchain@stable47 with:48 components: rustfmt

Merge pull request #2073 from sharkdp/dependabot/github_actions/actions/checkout-7.0.1Thayne McCombsbefore adoptionca51233

line 49why, one step back
49 - uses: actions/checkout@v7.0.1

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

lines 50–51why, one step back
50 with:
51 persist-credentials: false

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 52–60why, one step back
52 - run: cargo fmt -- --check
5354 lint_check:55 name: Ensure 'cargo clippy' has no warnings56 runs-on: ubuntu-latest57 steps:58 - uses: dtolnay/rust-toolchain@stable59 with:60 components: clippy

Merge pull request #2073 from sharkdp/dependabot/github_actions/actions/checkout-7.0.1Thayne McCombsbefore adoptionca51233

line 61why, one step back
61 - uses: actions/checkout@v7.0.1

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

lines 62–63why, one step back
62 with:
63 persist-credentials: false

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 64–67why, one step back
64 - run: cargo clippy --all-targets --all-features -- -Dwarnings
6566 min_version:67 name: Minimum supported rust version

Merge pull request #1712 from sharkdp/next-backThayne McCombsbefore adoptionabf4e47

line 68why, one step back
68 runs-on: ubuntu-22.04

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 69–71why, one step back
69 needs: crate_metadata
70 steps:71 - name: Checkout source code

Merge pull request #2073 from sharkdp/dependabot/github_actions/actions/checkout-7.0.1Thayne McCombsbefore adoptionca51233

line 72why, one step back
72 uses: actions/checkout@v7.0.1

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

lines 73–74why, one step back
73 with:
74 persist-credentials: false

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 75–81why, one step back
75
76 - name: Install rust toolchain (v${{ needs.crate_metadata.outputs.msrv }})77 uses: dtolnay/rust-toolchain@master78 with:79 toolchain: ${{ needs.crate_metadata.outputs.msrv }}80 components: clippy81 - name: Run clippy (on minimum supported rust version to prevent warnings we can't fix)

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

line 82why, one step back
82 run: cargo clippy --locked --all-targets "${MSRV_FEATURES}"

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

line 83why, one step back
83 - name: Run tests

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

line 84why, one step back
84 run: cargo test --locked "${MSRV_FEATURES}"

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 85–86why, one step back
85
86 build:

Merge pull request #1833 from tmccombs/build-fixesTavian Barnesbefore adoption15b57b9

line 87why, one step back
87 name: '${{ matrix.job.target }} (${{ matrix.job.os }})'

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 88–89why, one step back
88 runs-on: ${{ matrix.job.os }}
89 needs: crate_metadata

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

lines 90–93why, one step back
90 permissions:
91 id-token: write92 contents: write93 attestations: write

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 94–97why, one step back
94 strategy:
95 fail-fast: false96 matrix:97 job:

Merge pull request #1776 from tmccombs/os-updateTavian Barnesbefore adoptionfd06e69

lines 98–101why, one step back
98 - { target: aarch64-unknown-linux-gnu , os: ubuntu-24.04, use-cross: true }
99 - { target: aarch64-unknown-linux-musl , os: ubuntu-24.04, use-cross: true }100 - { target: arm-unknown-linux-gnueabihf , os: ubuntu-24.04, use-cross: true }101 - { target: arm-unknown-linux-musleabihf, os: ubuntu-24.04, use-cross: true }

Merge pull request #1946 from tmccombs/runner-os-updateTavian Barnesbefore adoptionfdb5534

line 102why, one step back
102 - { target: i686-pc-windows-msvc , os: windows-2025 }

Merge pull request #1776 from tmccombs/os-updateTavian Barnesbefore adoptionfd06e69

lines 103–104why, one step back
103 - { target: i686-unknown-linux-gnu , os: ubuntu-24.04, use-cross: true }
104 - { target: i686-unknown-linux-musl , os: ubuntu-24.04, use-cross: true }

Merge pull request #1946 from tmccombs/runner-os-updateTavian Barnesbefore adoptionfdb5534

lines 105–108why, one step back
105 - { target: x86_64-apple-darwin , os: macos-26-intel }
106 - { target: aarch64-apple-darwin , os: macos-26 }107 - { target: x86_64-pc-windows-gnu , os: windows-2025 }108 - { target: x86_64-pc-windows-msvc , os: windows-2025 }

Merge pull request #1716 from jcotton42/windows-aarch64Thayne McCombsbefore adoptiondbea8a6

line 109why, one step back
109 - { target: aarch64-pc-windows-msvc , os: windows-11-arm }

Merge pull request #1776 from tmccombs/os-updateTavian Barnesbefore adoptionfd06e69

lines 110–111why, one step back
110 - { target: x86_64-unknown-linux-gnu , os: ubuntu-24.04, use-cross: true }
111 - { target: x86_64-unknown-linux-musl , os: ubuntu-24.04, use-cross: true }

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

line 112why, one step back
112 env:

Merge pull request #1833 from tmccombs/build-fixesTavian Barnesbefore adoption15b57b9

line 113why, one step back
113 BUILD_CMD: "${{ matrix.job.use-cross && 'cross' || 'cargo' }}"

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

lines 114–115why, one step back
114 target: ${{ matrix.job.target }}
115 name: ${{ needs.crate_metadata.outputs.name }}

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 116–117why, one step back
116 steps:
117 - name: Checkout source code

Merge pull request #2073 from sharkdp/dependabot/github_actions/actions/checkout-7.0.1Thayne McCombsbefore adoptionca51233

line 118why, one step back
118 uses: actions/checkout@v7.0.1

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

lines 119–120why, one step back
119 with:
120 persist-credentials: false

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 121–124why, one step back
121
122 - name: Install prerequisites123 shell: bash124 run: |

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

line 125why, one step back
125 case ${target} in

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 126–133why, one step back
126 arm-unknown-linux-*) sudo apt-get -y update ; sudo apt-get -y install gcc-arm-linux-gnueabihf ;;
127 aarch64-unknown-linux-gnu) sudo apt-get -y update ; sudo apt-get -y install gcc-aarch64-linux-gnu ;;128 esac129130 - name: Install Rust toolchain131 uses: dtolnay/rust-toolchain@stable132 with:133 targets: ${{ matrix.job.target }}

Merge pull request #1813 from tmccombs/rust-versionThayne McCombsbefore adoptiond23ac06

line 134why, one step back
134 toolchain: "stable"

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 135–137why, one step back
135
136 - name: Install cross137 if: matrix.job.use-cross

Merge pull request #1834 from tmccombs/cross-installThayne McCombsbefore adoption491baaa

lines 138–149why, one step back
138 env:
139 cross_version: "v0.2.5"140 package_name: "cross-x86_64-unknown-linux-gnu.tar.gz"141 GH_TOKEN: "${{ github.token }}"142 run: |143 dir="$HOME/.local/bin/"144 mkdir -p "$dir"145 gh release download --repo cross-rs/cross \146 --pattern "${package_name}" -O - "${cross_version}" \147 | tar -C "$dir" -xz148 echo "$dir" >> $GITHUB_PATH149 echo "Installed cross $cross_version" >> $GITHUB_STEP_SUMMARY

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 150–161why, one step back
150 - name: Show version information (Rust, cargo, GCC)
151 shell: bash152 run: |153 gcc --version || true154 rustup -V155 rustup toolchain list156 rustup default157 cargo -V158 rustc -V159160 - name: Build161 shell: bash

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

line 162why, one step back
162 run: $BUILD_CMD build --locked --release --target="${target}"

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 163–169why, one step back
163
164 - name: Set binary name & path165 id: bin166 shell: bash167 run: |168 # Figure out suffix of binary169 EXE_suffix=""

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

line 170why, one step back
170 case ${target} in

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 171–174why, one step back
171 *-pc-windows-*) EXE_suffix=".exe" ;;
172 esac;173174 # Setup paths

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

lines 175–176why, one step back
175 BIN_NAME="${name}${EXE_suffix}"
176 BIN_PATH="target/${target}/release/${BIN_NAME}"

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 177–187why, one step back
177
178 # Let subsequent steps know where to find the binary179 echo "BIN_PATH=${BIN_PATH}" >> $GITHUB_OUTPUT180 echo "BIN_NAME=${BIN_NAME}" >> $GITHUB_OUTPUT181182 - name: Set testing options183 id: test-options184 shell: bash185 run: |186 # test only library unit tests and binary for arm-type targets187 unset CARGO_TEST_OPTIONS

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

lines 188–189why, one step back
188 case ${target} in
189 arm-* | aarch64-*)

Merge pull request #1833 from tmccombs/build-fixesTavian Barnesbefore adoption15b57b9

line 190why, one step back
190 CARGO_TEST_OPTIONS="--bin=${name}" ;;

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

line 191why, one step back
191 esac

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 192–195why, one step back
192 echo "CARGO_TEST_OPTIONS=${CARGO_TEST_OPTIONS}" >> $GITHUB_OUTPUT
193194 - name: Run tests195 shell: bash

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

lines 196–198why, one step back
196 env:
197 cargo_test_options: ${{ steps.test-options.outputs.CARGO_TEST_OPTIONS}}198 run: $BUILD_CMD test --locked --target="${target}" "${cargo_test_options}"

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 199–207why, one step back
199
200 - name: Generate completions201 id: completions202 shell: bash203 run: make completions204205 - name: Create tarball206 id: package207 shell: bash

Merge pull request #1943 from tmccombs/archive-scriptThayne McCombsbefore adoptioncdea7f5

line 208why, one step back
208 run: bash scripts/create-archive.sh

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

lines 209–210why, one step back
209 env:
210 BIN_PATH: ${{ steps.bin.outputs.BIN_PATH }}

Merge pull request #1943 from tmccombs/archive-scriptThayne McCombsbefore adoptioncdea7f5

lines 211–213why, one step back
211 TARGET: ${{ env.target }}
212 ARCHIVE_NAME: ${{ env.name }}-v${{ needs.crate_metadata.outputs.version }}-${{ env.target }}213 PKG_STAGING: "${{ env.CICD_INTERMEDIATES_DIR }}/package"

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 214–225why, one step back
214
215 - name: Create Debian package216 id: debian-package217 shell: bash218 if: startsWith(matrix.job.os, 'ubuntu')219 run: bash scripts/create-deb.sh220 env:221 TARGET: ${{ matrix.job.target }}222 DPKG_VERSION: ${{ needs.crate_metadata.version }}223 BIN_PATH: ${{ steps.bin.outputs.BIN_PATH }}224225 - name: "Artifact upload: tarball"

Merge pull request #1809 from tmccombs/attestationThayne McCombsbefore adoption97b3b04

line 226why, one step back
226 id: upload-tarball

Merge pull request #1974 from sharkdp/dependabot/github_actions/actions/upload-artifact-7.0.1Tavian Barnesbefore adoption1cfac9f

line 227why, one step back
227 uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 228–230why, one step back
228 with:
229 name: ${{ steps.package.outputs.PKG_NAME }}230 path: ${{ steps.package.outputs.PKG_PATH }}

Merge pull request #1941 from tmccombs/fix-attestThayne McCombsbefore adoption8a7ff7d

line 231why, one step back
231 compression-level: 0 # tarball is already compressed

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 232–233why, one step back
232
233 - name: "Artifact upload: Debian package"

Merge pull request #1809 from tmccombs/attestationThayne McCombsbefore adoption97b3b04

line 234why, one step back
234 id: upload-deb

Merge pull request #1974 from sharkdp/dependabot/github_actions/actions/upload-artifact-7.0.1Tavian Barnesbefore adoption1cfac9f

line 235why, one step back
235 uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 236–239why, one step back
236 if: steps.debian-package.outputs.DPKG_NAME
237 with:238 name: ${{ steps.debian-package.outputs.DPKG_NAME }}239 path: ${{ steps.debian-package.outputs.DPKG_PATH }}

Merge pull request #1941 from tmccombs/fix-attestThayne McCombsbefore adoption8a7ff7d

line 240why, one step back
240 compression-level: 0 # deb files are already compressed

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 241–247why, one step back
241
242 - name: Check for release243 id: is-release244 shell: bash245 run: |246 unset IS_RELEASE ; if [[ $GITHUB_REF =~ ^refs/tags/v[0-9].* ]]; then IS_RELEASE='true' ; fi247 echo "IS_RELEASE=${IS_RELEASE}" >> $GITHUB_OUTPUT

Merge pull request #1809 from tmccombs/attestationThayne McCombsbefore adoption97b3b04

line 248why, one step back
248

Merge pull request #1941 from tmccombs/fix-attestThayne McCombsbefore adoption8a7ff7d

line 249why, one step back
249 - name: "Attest artifacts"

Merge pull request #2091 from sharkdp/dependabot/github_actions/actions/attest-4.2.1Thayne McCombsbefore adoptionee20f42

line 250why, one step back
250 uses: actions/attest@508db95dd578ae2727ebd6217d5ba78e4fbda05d # v4

Merge pull request #1809 from tmccombs/attestationThayne McCombsbefore adoption97b3b04

lines 251–252why, one step back
251 if: steps.is-release.outputs.IS_RELEASE
252 with:

Merge pull request #1941 from tmccombs/fix-attestThayne McCombsbefore adoption8a7ff7d

lines 253–255why, one step back
253 subject-path: |
254 ${{ steps.package.outputs.PKG_PATH }}255 ${{ steps.debian-package.outputs.DPKG_PATH }}

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 256–257why, one step back
256
257 - name: Publish archives and packages

build(deps): bump softprops/action-gh-release from 3.0.2 to 3.0.3dependabot[bot]before adoption0e01c8c

line 258why, one step back
258 uses: softprops/action-gh-release@efb35369e0ad2afab669f228072c1b0d510eae64 # v3.0.3

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 259–272why, one step back
259 if: steps.is-release.outputs.IS_RELEASE
260 with:261 files: |262 ${{ steps.package.outputs.PKG_PATH }}263 ${{ steps.debian-package.outputs.DPKG_PATH }}264 env:265 GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}266267 winget:268 name: Publish to Winget269 runs-on: ubuntu-latest270 needs: build271 if: startsWith(github.ref, 'refs/tags/v')272 steps:

Merge pull request #1828 from HastD/zizmorThayne McCombsbefore adoption2f5ab52

line 273why, one step back
273 - uses: vedantmgoyal9/winget-releaser@4ffc7888bffd451b357355dc214d43bb9f23917e # v2

Merge pull request #1657 from sharkdp/dependabot/cargo/clap-4.5.23Tavian Barnesbefore adoption86d6e2d

lines 274–277why, one step back
274 with:
275 identifier: sharkdp.fd276 installers-regex: '-pc-windows-msvc\.zip$'277 token: ${{ secrets.WINGET_TOKEN }}