Skip to content

Instantly share code, notes, and snippets.

@moracabanas
Last active November 27, 2023 17:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save moracabanas/db4f4b20a219488979025131630ed888 to your computer and use it in GitHub Desktop.
Save moracabanas/db4f4b20a219488979025131630ed888 to your computer and use it in GitHub Desktop.
install-asdf-python_3.10.13.sh
#!/bin/bash
# Install dependencies
sudo apt update
sudo apt install curl git -y
# install python building dependencies
sudo apt install build-essential libssl-dev zlib1g-dev \
libbz2-dev libreadline-dev libsqlite3-dev curl \
libncursesw5-dev xz-utils tk-dev libxml2-dev libxmlsec1-dev libffi-dev liblzma-dev -y
# Clone asdf repository
git clone https://github.com/asdf-vm/asdf.git ~/.asdf --branch v0.13.1
# Add asdf to bashrc
echo -e '\n. "$HOME/.asdf/asdf.sh"' >> ~/.bashrc
# Add asdf completions to bashrc
echo -e '\n. "$HOME/.asdf/completions/asdf.bash"' >> ~/.bashrc;
# reload terminal
source '$HOME/.bashrc';
# Install Python plugin
asdf plugin add python https://github.com/danhper/asdf-python.git
# Install Python 3.10.13
asdf install python 3.10.13
# Set Python 3.10.13 as the global version
asdf global python 3.10.13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment