Poetry

이지수·2022년 7월 9일
0

설치

curl -sSL https://install.python-poetry.org | python3 -
# 현재 사용 X > 2022-11 기준 이전 방법

curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py | python3 -

프로젝트 시작하기

mkdir <project>
cd <project>

전역 python 버전과 프로젝트에서 사용하려는 python 버전이 다른경우 pyenv로 로컬 설정을 한 후 진행해 주세요.

pyenv local <version>
poetry init

Dependency

poetry add <package>

기존 poetry 사용시

# asdf ^3.10 사용시
asdf shell python 3.10.5
poetry env use 3.10.5
poetry install

0개의 댓글