Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit aded55b

Browse filesBrowse files
committed
fix: skip versions when filtering aliases if not available on nodebuild
1 parent f9957f3 commit aded55b
Copy full SHA for aded55b

File tree

Expand file treeCollapse file tree

1 file changed

+8
-1
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+8
-1
lines changed

‎lib/utils.sh

Copy file name to clipboardExpand all lines: lib/utils.sh
+8-1Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,9 @@ die() {
4040
# Print all alias and correspondent versions in the format "$alias\t$version"
4141
# Also prints versions as a alias of itself. Eg: "v10.0.0\tv10.0.0"
4242
filter_version_candidates() {
43-
local curr_line="" aliases=""
43+
local curr_line= aliases= definitions=
44+
45+
definitions=$(nodebuild_wrapped --definitions | grep -v 16.14.1)
4446

4547
# Skip headers
4648
IFS= read -r curr_line
@@ -54,6 +56,11 @@ filter_version_candidates() {
5456
# Lowercase lts codename, `-` if not a lts version
5557
local lts_codename=$(echo "${fields[9]}" | tr '[:upper:]' '[:lower:]')
5658

59+
# If not available in nodebuild skip it
60+
if ! grep -q "^$version$" <<< "$definitions"; then
61+
continue
62+
fi
63+
5764
if [ "$lts_codename" != - ]; then
5865
# No lts read yet, so this must be the more recent
5966
if ! grep -q "^lts:" <<< "$aliases"; then

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.