# requirements.txt
virtualenv
black
pre-commit
# pyproject.toml
[tool.black]
line-length = 80
# .pre-commit-config.yaml
repos:
- repo: https://github.com/psf/black
rev: 23.9.1
hooks:
- id: black
rm -rf .venv
virtualenv .venv
. .venv/bin/activate
pip3 install -r requirements.txt
pre-commit install
https://velog.io/@samnaka/pycharm-vscode-black-%EC%A0%81%EC%9A%A9
pycharm vscode black 적용, pre-commit
pycharm에서 python 가상환경을 생성해주고 pip install poetry로 poetry라는 패키지 관리 도구를 설치한다.poetry init으로 .toml 파일 생성 및 설정을 해준다.poetry add black으로 black을 설치한다.which bla
velog.io
https://dev.to/adamlombard/vscode-setting-line-lengths-in-the-black-python-code-formatter-1g62
VSCode: Setting line lengths in the Black Python code formatter
How to set Black Python code formatter line lengths in VSCode
dev.to
https://www.daleseo.com/python-black/
Black으로 파이썬 코드 스타일 통일하기
Engineering Blog by Dale Seo
www.daleseo.com
Run Pylint for all Python files in a directory and all subdirectories
I have find . -iname "*.py" -exec pylint -E {} ;\ and FILES=$(find . -iname "*.py") pylint -E $FILES If I understand correctly, the first command will run pylint for each of the Python files, ...
stackoverflow.com
'공부 (@Deprecated)' 카테고리의 다른 글
| [python] xor `bool(a) != bool(b)`; not xor `bool(a) == bool(b)` (0) | 2023.09.29 |
|---|---|
| [fastapi] locale i18n; async def asdf(request: Request): accept_language = request.headers.get("Accept-Language") (0) | 2023.09.28 |
| [prometheus] alertmanager (0) | 2023.09.22 |
| [java] for vs stream vs parallelStrem (0) | 2023.09.20 |
| [spring] assertThrows (0) | 2023.09.20 |