Skip to content

Commit

Permalink
ci: Fix fuzzer listing
Browse files Browse the repository at this point in the history
The fuzzer tests in CI were broken in CI by a change to the file-listing
action. This change fixes fuzzer building.
  • Loading branch information
olix0r committed Nov 10, 2023
1 parent dd64109 commit c2e5efe
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 9 deletions.
4 changes: 3 additions & 1 deletion .github/fuzzers-list.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
#!/usr/bin/env bash

set -euo pipefail

## Lists the fuzzers that should be run given a set of changed files.

# Find the nearest fuzzer crate, or nothing.
find_fuzz_dir() {
d=${1%/*}
if [ "$d" = . ]; then
if ! [[ "$d" =~ / ]]; then
return
elif [ -d "$d" ] && [[ "$d" = */fuzz ]]; then
echo "$d"
Expand Down
12 changes: 4 additions & 8 deletions justfile
Original file line number Diff line number Diff line change
Expand Up @@ -159,14 +159,10 @@ fuzzers:
echo "fuzzers must be run with nightly" >&2
exit 1
fi
for dir in $(find . -type d -name fuzz); do
echo "cd $dir && {{ _cargo }} fuzz build"
(
cd $dir
@{{ _cargo }} fuzz build \
{{ if profile == "release" { "--release" } else { "" } }}
)
for dir in $(find ./linkerd -type d -name fuzz); do
echo "cd $dir && cargo +nightly fuzz build"
( cd $dir ; cargo +nightly fuzz build \
{{ if profile == "release" { "--release" } else { "" } }} )
done
export DOCKER_BUILDX_CACHE_DIR := env_var_or_default('DOCKER_BUILDX_CACHE_DIR', '')
Expand Down

0 comments on commit c2e5efe

Please sign in to comment.