2019-11-18 16:41:48 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
2019-12-02 17:24:23 +00:00
|
|
|
# configuration management
|
2019-11-18 16:42:30 +00:00
|
|
|
git pull
|
2019-12-02 17:24:23 +00:00
|
|
|
cat pyproject.toml | grep version
|
|
|
|
echo "ready?"
|
2019-11-18 16:41:48 +00:00
|
|
|
read BOOL
|
|
|
|
|
|
|
|
source venv/bin/activate
|
|
|
|
|
|
|
|
# clean
|
|
|
|
rm -rf build/ dist/ .eggs/
|
|
|
|
find . -name '*.egg-info' -exec rm -fr {} +
|
|
|
|
find . -name '*.egg' -exec rm -fr {} +
|
|
|
|
find . -name '*.pyc' -exec rm -f {} +
|
|
|
|
find . -name '*.pyo' -exec rm -f {} +
|
|
|
|
find . -name '*~' -exec rm -f {} +
|
|
|
|
find . -name '__pycache__' -exec rm -fr {} +
|
|
|
|
rm -fr .tox/
|
|
|
|
rm -f .coverage
|
|
|
|
rm -fr htmlcov/
|
|
|
|
rm -fr .pytest_cache
|
|
|
|
|
2019-12-02 17:24:23 +00:00
|
|
|
# tests
|
|
|
|
tox
|
|
|
|
echo "ready to publish to PyPI?"
|
|
|
|
read BOOL
|
2019-11-18 16:41:48 +00:00
|
|
|
|
|
|
|
# package creation
|
2019-12-02 18:43:22 +00:00
|
|
|
poetry build
|
2019-12-02 17:24:23 +00:00
|
|
|
poetry publish
|