forked from qway/nerfmeshes
-
Notifications
You must be signed in to change notification settings - Fork 0
/
script.sh
36 lines (25 loc) · 834 Bytes
/
script.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/bin/bash
sudo apt-get install libffi-dev
curl https://pyenv.run | bash
# add to path
echo 'export PATH="$HOME/.pyenv/bin:$PATH"' >> ~/.bashrc
echo 'eval "$(pyenv init -)"' >> ~/.bashrc
echo 'eval "$(pyenv virtualenv-init -)"' >> ~/.bashrc
# apply envs
source ~/.bashrc
pyenv install 3.7.7
pyenv global 3.7.7
# set sym link, the arguments may be different
ln -s ../drive/My\ Drive/data data
# install poetry
curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py | python -
# add poetry to path
echo 'export PATH="$HOME/.poetry/bin:$PATH"' >> ~/.bashrc
# apply envs
source ~/.bashrc
# Configure poetry to create virtual environments inside the project's root directory
poetry config virtualenvs.in-project true
# install dependencies
poetry install
# activate env
source .venv/bin/activate