File tree Expand file tree Collapse file tree 2 files changed +8
-3
lines changed Expand file tree Collapse file tree 2 files changed +8
-3
lines changed Original file line number Diff line number Diff line change 55 description : ' Version of python to be installed. Reads from .python-version if unset.'
66 python-version-file :
77 description : ' Version of python to be installed'
8- default : " .python-version"
8+ default : ' .python-version'
99 cache :
1010 description : Used to specify whether caching is needed. Set to true, if you'd like to enable caching.
1111 required : true
Original file line number Diff line number Diff line change @@ -5,10 +5,15 @@ set -euo pipefail
55specified_version=" $1 "
66specified_version_file=" $2 "
77
8+ desired_python_version=" ${specified_version} "
9+ if [ -f " ${specified_version_file} " ]; then
10+ desired_python_version=$( cat " ${specified_version_file} " )
11+ fi
12+
813# This versions map should be kept in sync with
914# - https://www.python.org/downloads/
1015# - https://devguide.python.org/versions/
11- case " ${specified_version } " in
16+ case " ${desired_python_version } " in
1217 " 3" )
1318 echo " 3.12.0"
1419 ;;
@@ -28,6 +33,6 @@ case "${specified_version}" in
2833 echo " 3.8.18"
2934 ;;
3035 * )
31- echo " ${specified_version } "
36+ echo " ${desired_python_version } "
3237 ;;
3338esac
You can’t perform that action at this time.
0 commit comments