diff --git a/re.sh b/re.sh index d852276..8302999 100755 --- a/re.sh +++ b/re.sh @@ -15,13 +15,16 @@ activate() { pip --version } caches() { + local command="${1}" set \ ".cache/pip" \ ".cache/uv" \ ".local/share/pip" \ ".local/share/uv" + echo + echo "caches:" for cache in "${@}"; do - "${1}" "${HOME}/${cache}" + "${command}" "${HOME}/${cache}" done } deactivate() { @@ -33,7 +36,10 @@ deactivate() { } list() { echo - ls -a -l "${1}/bin" + ls -a -l "${1}/${2}" +} +list_venv() { + list "${1}" "bin" } pip_install() { echo @@ -98,10 +104,10 @@ os="${root}/os" remove "${os}" python3 -m "venv" "${os}" activate "${os}" -list "${os}" +list_venv "${os}" pip_install --upgrade "pip" pip_install "uv" -list "${os}" +list_venv "${os}" set \ "3.12" @@ -121,16 +127,16 @@ deactivate for version in "${@}"; do activate "${py}" - list "${py}" + list_venv "${py}" pip_install "uv" - list "${py}" + list_venv "${py}" uv_install for module in "rwx"; do ln --symbolic \ "/rwx/rwx/${module}" \ "${py}/lib/python${version}/site-packages/${module}" done - list "${py}" + list_venv "${py}" done -caches ls +caches list_venv