py/switch

This commit is contained in:
Marc Beninca 2024-09-09 00:19:43 +02:00
parent a9e31fd740
commit acec3522fa
Signed by: marc.beninca
GPG key ID: 9C7613450C80C24F

View file

@ -1049,6 +1049,18 @@ SPCD_STEP = ${index}
done done
} }
spcd_f_py_switch() {
spcd_step "Switch"
local name path
name="$(basename "${SPCD_GIT_SPCD}")"
path="$(realpath "${0}")"
echo "\
${path}
${SPCD_PYTHON_ALIAS} / ${name}"
"${SPCD_PYTHON_ALIAS}" -m "${name}"
}
# ╭───┬─────╮ # ╭───┬─────╮
# │ f │ txt │ # │ f │ txt │
# ╰───┴─────╯ # ╰───┴─────╯
@ -1547,18 +1559,6 @@ spcd_step__install_packages() {
spcd_step_out spcd_step_out
} }
spcd_step__python_switch() {
spcd_step "Switch"
local name path
name="$(basename "${SPCD_GIT_SPCD}")"
path="$(realpath "${0}")"
echo "\
${path}
${SPCD_PYTHON_ALIAS} / ${name}"
"${SPCD_PYTHON_ALIAS}" -m "${name}"
}
# ╭──────╮ # ╭──────╮
# │ main │ # │ main │
# ╰──────╯ # ╰──────╯
@ -1617,7 +1617,7 @@ spcd_main() {
spcd_step__python_modules spcd_step__python_modules
spcd_step__install_packages spcd_step__install_packages
spcd_f_py_save spcd_f_py_save
spcd_step__python_switch spcd_f_py_switch
} }
spcd_main spcd_main