From ee83bf72135bceb703b2b69fb5cf53d5292a8589 Mon Sep 17 00:00:00 2001
From: Piotr Maslanka <piotr.maslanka@henrietta.com.pl>
Date: Sun, 8 Oct 2017 03:46:28 +0200
Subject: [PATCH] travis will upload to pypi

---
 .travis.yml |  1 +
 build.sh    | 10 ++++++++++
 2 files changed, 11 insertions(+)
 create mode 100644 build.sh

diff --git a/.travis.yml b/.travis.yml
index 2fa26c4..f364a4d 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -12,5 +12,6 @@ install:
  - pip install -r requirements.txt
 after_success:
  - CODECLIMATE_REPO_TOKEN=e8e05973a6c49139de5f98013cd285f9238b78d20f053f37f6e7deeab2c2c52f codeclimate-test-reporter
+ - bash build.sh
 services:
  - rabbitmq
diff --git a/build.sh b/build.sh
new file mode 100644
index 0000000..1f9ee20
--- /dev/null
+++ b/build.sh
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+set -x
+set -e
+
+if [ $TRAVIS_BRANCH == "master" ]; then
+    pip install wheel twine
+    python setup.py bdist bdist_wheel
+    twine upload -u $PYPI_USER -p $PYPI_PWD dist/*
+fi
-- 
GitLab