pyenv-latest: keep the 't' suffix when printing an unresolved prefix back (#3621)

This commit is contained in:
nk-batman21 authored and GitHub committed 2026-11-03 13:11:57 +03:00
1 parent e6669f0a84
commit be94f3539f
2 files changed
+13 -2

No files matched your search

+2 -2
View File
@@ -101,9 +101,9 @@ IFS=$'\n'
echo "$DEFINITION"
else
if [[ -z $BYPASS ]]; then
echo "pyenv: no $([[ -z $FROM_KNOWN ]] && echo installed || echo known) versions match the prefix \`$prefix'" >&2
echo "pyenv: no $([[ -z $FROM_KNOWN ]] && echo installed || echo known) versions match the prefix \`$prefix$suffix'" >&2
else
echo "$prefix"
echo "$prefix$suffix"
fi
if [[ -z $FORCE ]]; then
exitcode=1
+11
View File
@@ -176,3 +176,14 @@ nonexistent
nonexistent
!
}
@test "falls back to a 't' argument unchanged" {
create_stub pyenv-versions <<!
echo 3.14.2
!
run pyenv-latest -f 3.14.2t
assert_success
assert_output <<!
3.14.2t
!
}