From 3c7cd664224fc3c5bc5617af2d950dec9aee19d8 Mon Sep 17 00:00:00 2001 From: HoJeong Go Date: Sun, 6 Jul 2025 17:09:44 +0900 Subject: [PATCH 1/2] fix(ci): semver sorting --- .github/workflows/sync.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/sync.yml b/.github/workflows/sync.yml index c26f690..5a14447 100644 --- a/.github/workflows/sync.yml +++ b/.github/workflows/sync.yml @@ -23,7 +23,9 @@ jobs: -H 'Accept: application/vnd.github+json' \ -H 'X-GitHub-Api-Version: 2022-11-28' \ 'https://api.github.com/repos/gorhill/ublock/tags' | \ - jq -r '[.[].name | select(test("^[0-9]"))] | sort_by(.) | last')" + jq -r '[.[].name | select(test("^[0-9]"))] | .[]')" | \ + sort -rV | \ + head -1 if [[ "$UPSTREAM_TAG" == 'null' ]]; then echo "ERROR: Failed to retrieve upstream version!" exit 1 From fe4fa145b293f76be6a70510a4255e000d6bce66 Mon Sep 17 00:00:00 2001 From: HoJeong Go Date: Sun, 6 Jul 2025 17:10:58 +0900 Subject: [PATCH 2/2] fix: inline into variable --- .github/workflows/sync.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/sync.yml b/.github/workflows/sync.yml index 5a14447..e5b4b2b 100644 --- a/.github/workflows/sync.yml +++ b/.github/workflows/sync.yml @@ -23,9 +23,9 @@ jobs: -H 'Accept: application/vnd.github+json' \ -H 'X-GitHub-Api-Version: 2022-11-28' \ 'https://api.github.com/repos/gorhill/ublock/tags' | \ - jq -r '[.[].name | select(test("^[0-9]"))] | .[]')" | \ + jq -r '[.[].name | select(test("^[0-9]"))] | .[]' | \ sort -rV | \ - head -1 + head -1)" if [[ "$UPSTREAM_TAG" == 'null' ]]; then echo "ERROR: Failed to retrieve upstream version!" exit 1