diff --git a/.github/workflows/mg.sh b/.github/workflows/mg.sh index 2bb4d68768..1195f8d31c 100755 --- a/.github/workflows/mg.sh +++ b/.github/workflows/mg.sh @@ -12,9 +12,9 @@ if [[ $1 == false ]]; then fi for f in anda-build/rpm/rpms/*; do - n=$(lesspipe.sh $f | grep -E "Name\s*: " | sed "s@Name\s*: @@") - v=$(lesspipe.sh $f | grep -E "Version\s*: " | sed "s@Version\s*: @@") - r=$(lesspipe.sh $f | grep -E "Release\s*: " | sed "s@Release\s*: @@") + n=$(lesspipe.sh $f | grep -E "Name\s*: " | sed "s@Name\s*: @@" | head -n1) + v=$(lesspipe.sh $f | grep -E "Version\s*: " | sed "s@Version\s*: @@" | head -n1) + r=$(lesspipe.sh $f | grep -E "Release\s*: " | sed "s@Release\s*: @@" | head -n1) d=${p/\%v/$v} d=${d/\%r/$r} curl -H "Authorization: Bearer $6" https://madoguchi.fyralabs.com/ci5/terra$3/builds/$n -X PUT -H "Content-Type: application/json" -d $d --fail-with-body