diff --git a/tools/update-swift-syntax.sh b/tools/update-swift-syntax.sh index a9fc624ea2..9a452b538d 100755 --- a/tools/update-swift-syntax.sh +++ b/tools/update-swift-syntax.sh @@ -2,7 +2,7 @@ set -euo pipefail -readonly old_commit="$(grep "apple/swift-syntax" Package.swift | sed -nr 's/.*revision: \"([a-f0-9]{40})\"),$/\1/p')" +readonly old_commit="$(grep "apple/swift-syntax" Package.swift | sed -nr 's/.*revision: \"([a-f0-9]{40})\"\),$/\1/p')" if [ $# -eq 0 ]; then readonly new_commit="$(curl -s -H "Authorization: token $GITHUB_TOKEN" -H "Accept: application/vnd.github.VERSION.sha" "https://api.github.com/repos/apple/swift-syntax/commits/main")" else