Skip to content

Commit

Permalink
build: tidy up
Browse files Browse the repository at this point in the history
  • Loading branch information
epikhinm committed Mar 31, 2023
1 parent 5b3ba34 commit 0915489
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 11 deletions.
9 changes: 2 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
.DEFAULT_GOAL := help
.PHONY: tox tox-current test lint format test-all-versions help
.PHONY: tox tox-current test lint submodule generate release format help

REPO_ROOT:=$(shell dirname $(realpath $(firstword $(MAKEFILE_LIST))))

BUF_VERSION="1.15.1"
BUF_VERSION="1.16.0"
BIN="venv/bin"

venv: ## install deps (library & development)
Expand Down Expand Up @@ -34,11 +34,6 @@ format:
$(BIN)/python3 -m isort doublecloud setup.py changelog.py examples
$(BIN)/python3 -m black doublecloud setup.py changelog.py examples

test-all-versions: ## run test for multiple python versions using docker
# python 3.10 not provided in image so we skip it
@echo "skip"
# docker run --rm -v $(REPO_ROOT):/src fkrull/multi-python tox -c /src -e py36,py37,py38,py39

submodule: ## retrieve public protospecs
git submodule update --init --recursive --remote

Expand Down
7 changes: 3 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@

[pypi-image]: https://img.shields.io/pypi/v/doublecloud
[pypi-url]: https://pypi.org/project/doublecloud/
[build-image]: https://github.com/doublecloud/python-sdk/actions/workflows/run-tests.yml/badge.svg
[build-url]: https://github.com/doublecloud/python-sdk/actions/workflows/run-tests.yml
[license-image]: https://img.shields.io/github/license/doublecloud/python-sdk.svg
[license-url]: https://github.com/doublecloud/python-sdk/blob/main/LICENSE

Expand Down Expand Up @@ -45,16 +43,17 @@ Check `examples` directory for more examples.
## Contributing
### Dependencies
Use `make venv` command to install library, its production and development dependencies.
Use `make submodule` to fetch proto specifications.
Use `make generate` to generate wrappers for gRPC services.

### Formatting
Use `make format` to autoformat code with black tool.
Use `make format` to autoformat code with various set of tools.

### Tests
- `make test` to run tests for current python version
- `make lint` to run only linters for current python version
- `make tox-current` to run all checks (tests + code style checks + linters + format check) for current python version
- `make tox` to run all checks for all supported (installed in your system) python versions
- `make test-all-versions` to run all checks for all supported python versions in docker container


### Maintaining
Expand Down

0 comments on commit 0915489

Please sign in to comment.