Is-is-old check query now more specific
This commit is contained in:
parent
cb761ad598
commit
163710d6fa
1 changed files with 4 additions and 2 deletions
|
@ -34,8 +34,11 @@ is_it_old() {
|
||||||
upstream_version=$3
|
upstream_version=$3
|
||||||
repo=$4
|
repo=$4
|
||||||
|
|
||||||
|
query="$repo/$name: upgrade to $upstream_version"
|
||||||
|
query="$(echo $query | sed 's| |%20|g' | sed 's|:|%3A|g' | sed 's|/|%2F|g' )"
|
||||||
|
|
||||||
result="$(curl --silent -X 'GET' \
|
result="$(curl --silent -X 'GET' \
|
||||||
"$GITHUB_SERVER_URL/api/v1/repos/$GITHUB_REPOSITORY/issues?state=open&q=$name&type=issues" \
|
"$GITHUB_SERVER_URL/api/v1/repos/$GITHUB_REPOSITORY/issues?state=open&q=$query&type=issues" \
|
||||||
-H 'accept: application/json' \
|
-H 'accept: application/json' \
|
||||||
-H "authorization: Basic $FORGEJO_TOKEN"
|
-H "authorization: Basic $FORGEJO_TOKEN"
|
||||||
)"
|
)"
|
||||||
|
@ -107,7 +110,6 @@ if [ -f out_of_date ]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
id=$(is_it_old $name $downstream_version $upstream_version $repo)
|
id=$(is_it_old $name $downstream_version $upstream_version $repo)
|
||||||
echo $id
|
|
||||||
|
|
||||||
if [ "$id" != "0" ] && [ -n "$id" ]; then
|
if [ "$id" != "0" ] && [ -n "$id" ]; then
|
||||||
echo "Issue for $repo/$name needs updating"
|
echo "Issue for $repo/$name needs updating"
|
||||||
|
|
Loading…
Reference in a new issue