Skip to content

Commit

Permalink
ci: remove nodejs lts versions that didn't start yet (#806)
Browse files Browse the repository at this point in the history
  • Loading branch information
rostislav-simonik authored Oct 20, 2023
1 parent aa62b1e commit 42c6c7f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions scripts/get-lts-versions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ json=$(curl -s https://raw.githubusercontent.com/nodejs/Release/master/schedule.

current_date=$(date +%Y-%m-%d)

lts_versions=$(echo "$json" | jq -c "[ to_entries[] | select(.value.lts != null and .value.maintenance >= \"$current_date\" and .value.end >= \"$current_date\") | .key[1:] | tonumber ] | sort ")
last_lts_version=$(echo "$json" | jq -c "[ to_entries[] | select(.value.lts != null and .value.maintenance >= \"$current_date\" and .value.end >= \"$current_date\") | .key[1:] | tonumber ] | sort | .[-1]")
lts_versions=$(echo "$json" | jq -c "[ to_entries[] | select(.value.lts != null and .value.start <= \"$current_date\" and .value.maintenance >= \"$current_date\" and .value.end >= \"$current_date\") | .key[1:] | tonumber ] | sort ")
last_lts_version=$(echo "$json" | jq -c "[ to_entries[] | select(.value.lts != null and .value.start <= \"$current_date\" and .value.maintenance >= \"$current_date\" and .value.end >= \"$current_date\") | .key[1:] | tonumber ] | sort | .[-1]")
echo "matrix_lts_versions=$lts_versions" >> $GITHUB_OUTPUT
echo "matrix_last_lts_version=[$last_lts_version]" >> $GITHUB_OUTPUT
echo "last_lts_version=$last_lts_version" >> $GITHUB_OUTPUT
echo "last_lts_version=$last_lts_version" >> $GITHUB_OUTPUT

0 comments on commit 42c6c7f

Please sign in to comment.