Skip to content

Commit

Permalink
Fix serverless binary size action. (#28150)
Browse files Browse the repository at this point in the history
  • Loading branch information
purple4reina authored Aug 28, 2024
1 parent 9ac77de commit 01631c7
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/serverless-binary-size.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,14 +82,19 @@ jobs:
id: should
run: |
cd go/src/github.com/DataDog/datadog-agent
git fetch origin $GITHUB_BASE_REF
git fetch origin $GITHUB_HEAD_REF
if test $(
git diff $GITHUB_BASE_REF..$GITHUB_SHA --name-only | grep dependencies_linux_amd64.txt
git diff origin/$GITHUB_BASE_REF...origin/$GITHUB_HEAD_REF --name-only | grep dependencies_linux_amd64.txt
); then
echo "should_run=true" >> $GITHUB_OUTPUT
echo "dependencies list changed"
elif [[ ${{ steps.compare.outputs.diff }} > env.SIZE_ALLOWANCE ]]; then
echo "should_run=true" >> $GITHUB_OUTPUT
echo "binary size changed"
else
echo "should_run=false" >> $GITHUB_OUTPUT
echo "nothing changed"
fi
### Steps below run if size diff > SIZE_ALLOWANCE or file dependencies_linux_amd64.txt changed ###
Expand Down

0 comments on commit 01631c7

Please sign in to comment.