build: sort coreutils entries at build time #7351
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Benchmarks | |
| # spell-checker:ignore codspeed dtolnay Swatinem sccache | |
| on: | |
| pull_request: | |
| push: | |
| branches: | |
| - '*' | |
| permissions: | |
| contents: read # to fetch code (actions/checkout) | |
| # End the current execution if there is a new changeset in the PR. | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} | |
| jobs: | |
| benchmarks: | |
| name: Run ${{ matrix.type }} benchmarks for ${{ matrix.package }} (CodSpeed) | |
| runs-on: ubuntu-latest | |
| env: | |
| RUSTC_WRAPPER: sccache | |
| CARGO_INCREMENTAL: 0 | |
| SCCACHE_GHA_ENABLED: "true" | |
| strategy: | |
| matrix: | |
| type: [simulation, memory] | |
| package: [ | |
| uu_base64, | |
| uu_cksum, | |
| uu_cp, | |
| uu_cut, | |
| uu_dd, | |
| uu_df, | |
| uu_du, | |
| uu_expand, | |
| uu_fold, | |
| uu_join, | |
| uu_ls, | |
| uu_mv, | |
| uu_nl, | |
| uu_numfmt, | |
| uu_rm, | |
| uu_seq, | |
| uu_shuf, | |
| uu_sort, | |
| uu_split, | |
| uu_tsort, | |
| uu_unexpand, | |
| uu_uniq, | |
| uu_wc, | |
| uu_factor, | |
| uu_date | |
| ] | |
| steps: | |
| - uses: actions/checkout@v6 | |
| with: | |
| persist-credentials: false | |
| - uses: dtolnay/rust-toolchain@stable | |
| - uses: Swatinem/rust-cache@v2 | |
| - name: Run sccache-cache | |
| uses: mozilla-actions/sccache-action@v0.0.9 | |
| - name: Install locales | |
| shell: bash | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y locales | |
| sudo locale-gen fr_FR.UTF-8 | |
| sudo update-locale | |
| - name: Install cargo-codspeed | |
| shell: bash | |
| run: cargo install cargo-codspeed --locked | |
| - name: Build benchmarks for ${{ matrix.package }} (${{ matrix.type }}) | |
| shell: bash | |
| run: | | |
| echo "Building ${{ matrix.type }} benchmarks for ${{ matrix.package }}" | |
| cargo codspeed build -m ${{ matrix.type }} -p ${{ matrix.package }} | |
| - name: Run ${{ matrix.type }} benchmarks for ${{ matrix.package }} | |
| uses: CodSpeedHQ/action@v4 | |
| env: | |
| CODSPEED_LOG: debug | |
| with: | |
| mode: ${{ matrix.type }} | |
| run: | | |
| echo "Running ${{ matrix.type }} benchmarks for ${{ matrix.package }}" | |
| cargo codspeed run -p ${{ matrix.package }} > /dev/null | |
| token: ${{ secrets.CODSPEED_TOKEN }} |