Handle no hit correctly... (#9648)

automerge
This commit is contained in:
Ryo Onodera 2020-04-22 17:23:33 +09:00 committed by GitHub
parent ba58589656
commit 7bf1720a76
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 3 deletions

View File

@ -13,9 +13,11 @@ parsed_update_args="$(
package=$(echo "$parsed_update_args" | awk '{print $2}' | grep -o "^[^:]*")
if [[ -n $parsed_update_args ]]; then
# shellcheck disable=SC2086
_ scripts/cargo-for-all-lock-files.sh \
"$(git grep --files-with-matches "$package" :**/Cargo.lock)" -- \
update $parsed_update_args
for lock in $(git grep --files-with-matches --fixed-strings "$package" :**/Cargo.lock); do
_ scripts/cargo-for-all-lock-files.sh \
"$lock" -- \
update $parsed_update_args
done
fi
echo --- ok