diff --git a/Makefile b/Makefile index 755af2c9..cd0f456a 100644 --- a/Makefile +++ b/Makefile @@ -1,26 +1,37 @@ -docker-build: +.PHONY: docker/build +docker/build: docker build -f Dockerfile . -t akhmetov/python-telegram -docker-send-message: +.PHONY: docker/send-message +docker/send-message: docker run -i -t \ -v /tmp/docker-python-telegram/:/tmp/ \ akhmetov/python-telegram \ python3 /app/examples/send_message.py $(API_ID) $(API_HASH) $(PHONE) $(CHAT_ID) $(TEXT) -docker-echo-bot: +.PHONY: docker/echo-bot +docker/echo-bot: docker run -i -t \ -v /tmp/docker-python-telegram/:/tmp/ \ akhmetov/python-telegram \ python3 /app/examples/echo_bot.py $(API_ID) $(API_HASH) $(PHONE) -docker-get-instant-view: +.PHONY: docker/get-instant-view +docker/get-instant-view: docker run -i -t \ -v /tmp/docker-python-telegram/:/tmp/ \ akhmetov/python-telegram \ python3 /app/examples/echo_bot.py $(API_ID) $(API_HASH) $(PHONE) -release-pypi: - test -n "$(VERSION)" - python setup.py sdist - twine upload dist/python-telegram-$(VERSION).tar.gz +.PHONY: clean +clean: + rm -rf dist + +.PHONY: build-pypi +build-pypi: clean + python3 -m build + +.PHONY: release-pypi +release-pypi:build-pypi + twine upload dist/*