Skip to content

Commit

Permalink
Setup: Update for Ubuntu Noble with venv
Browse files Browse the repository at this point in the history
  • Loading branch information
TunaLobster committed Aug 31, 2024
1 parent 52455aa commit 2b409d8
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
14 changes: 7 additions & 7 deletions Sphinxsetup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,24 +10,24 @@ fi
DISTRIBUTION_ID=$(lsb_release -i -s)
if [ ${DISTRIBUTION_ID} = 'Ubuntu' ]; then
DISTRIBUTION_CODENAME=$(lsb_release -c -s)
if [ ${DISTRIBUTION_CODENAME} = 'focal' ] || [ ${DISTRIBUTION_CODENAME} = 'bionic' ] || [ ${DISTRIBUTION_CODENAME} = 'lunar' ]; then
if [ ${DISTRIBUTION_CODENAME} = 'focal' ] || [ ${DISTRIBUTION_CODENAME} = 'bionic' ] || [ ${DISTRIBUTION_CODENAME} = 'noble' ]; then
sudo add-apt-repository universe -y
fi
fi

sudo apt-get -y update
sudo apt-get install -y unzip git imagemagick curl wget make python3

# create a Python venv on more recent releases:
if [ ${DISTRIBUTION_CODENAME} == 'lunar' ]; then
sudo apt install python3.11-venv
if [ ${DISTRIBUTION_CODENAME} = 'noble' ]; then
sudo apt install python3-venv
python3 -m venv $HOME/venv-ardupilot-wiki --upgrade-deps

# activate it:
SOURCE_LINE="source $HOME/venv-ardupilot-wiki/bin/activate"
$SOURCE_LINE
fi

sudo apt-get -y update
sudo apt-get install -y unzip git imagemagick curl wget make python3

# Install packages release specific
if [ ${DISTRIBUTION_CODENAME} = 'bionic' ]; then
sudo apt-get install -y python3-distutils
Expand Down Expand Up @@ -56,7 +56,7 @@ else
fi

PIP_USER_ARGUMENT=""
if [ ${DISTRIBUTION_CODENAME} != 'lunar' ]; then
if [ ${DISTRIBUTION_CODENAME} != 'noble' ]; then
curl "$GET_PIP_URL" -o get-pip.py
python3 get-pip.py
rm -f get-pip.py
Expand Down
2 changes: 1 addition & 1 deletion update.sh
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ lock_file build.lck || {
exit 1
}
# activate Python venv on more recent releases:
if [ ${DISTRIBUTION_CODENAME} == 'lunar' ]; then
if [ ${DISTRIBUTION_CODENAME} = 'mantic' ]; then
SOURCE_LINE="source $HOME/venv-ardupilot-wiki/bin/activate"
$SOURCE_LINE
fi
Expand Down

0 comments on commit 2b409d8

Please sign in to comment.