Skip to content

Commit 96eb972

Browse files
committed
fix: get crate version with user agent
1 parent fef7881 commit 96eb972

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424
CURRENT=$(cargo metadata --no-deps --format-version 1 | jq -r '.packages[0].version')
2525
echo "version=$CURRENT" >> "$GITHUB_OUTPUT"
2626
# Compare against crates.io instead of git history
27-
PUBLISHED=$(curl -s "https://crates.io/api/v1/crates/$CRATE_NAME" | jq -r '.crate.max_version // "0.0.0"')
27+
PUBLISHED=$(curl -s -H "User-Agent: turboquant-ci (github.com/SaschaOnTour/turboquant)" "https://crates.io/api/v1/crates/$CRATE_NAME" | jq -r '.crate.max_version // "0.0.0"')
2828
if [ "$PUBLISHED" = "null" ] || [ "$PUBLISHED" = "0.0.0" ] || [ "$CURRENT" != "$PUBLISHED" ]; then
2929
echo "changed=true" >> "$GITHUB_OUTPUT"
3030
echo "Local $CURRENT vs crates.io $PUBLISHED — publishing"

0 commit comments

Comments
 (0)