mirror of
https://github.com/asdf-community/asdf-python
synced 2024-10-06 08:32:06 +08:00
14 lines
315 B
Plaintext
14 lines
315 B
Plaintext
|
#!/usr/bin/env bash
|
||
|
|
||
|
get_legacy_version() {
|
||
|
current_directory=$1
|
||
|
python_version_file="$current_directory/.python-version"
|
||
|
|
||
|
# Get version from .python-version file. .python-version is used by pyenv
|
||
|
if [ -f $python_version_file ]; then
|
||
|
cat $python_version_file
|
||
|
fi
|
||
|
}
|
||
|
|
||
|
get_legacy_version $1
|