pygcode/deployment
2017-07-22 00:55:47 +10:00
..
2017-07-22 00:55:47 +10:00

Notes on deployment

How I deploy this package.

For anyone reading, this readme and all files in this folder are mainly just notes for myself; they have little to do with pygcode itself. However, if you're interested in deploying your own PyPi package, then hopefully this can help.

Method based on the articles:

PyPi deployment

Install Required Tools

./deploy.sh setup

PyPi rc

cat ~/.pypirc

[distutils]
index-servers =
  prod
  test

[prod]
repository = https://upload.pypi.org/legacy/
username=FraggaMuffin
password=secret

[test]
repository=https://test.pypi.org/legacy/
username=FraggaMuffin
password=secret

chmod 600 ~/.pypirc

Build and Test sdist and wheel

Build

./deploy.sh build

Test sdist

# Python 2.x
./deploy.sh remkenv py2
./deploy.sh install sdist py2
./deploy.sh test installed py2

# Python 3.x
./deploy.sh remkenv py3
./deploy.sh install sdist py3
./deploy.sh test installed py3

Test wheel

# Python 2.x
./deploy.sh remkenv py2
./deploy.sh install wheel py2
./deploy.sh test installed py2

# Python 3.x
./deploy.sh remkenv py3
./deploy.sh install wheel py3
./deploy.sh test installed py3

Upload to PyPi Test server

./deploy.sh test

Test

# Python 2.x
./deploy.sh remkenv py2
./deploy.sh install pypitest py2
./deploy.sh test installed py2

# Python 3.x
./deploy.sh remkenv py3
./deploy.sh install pypitest py3
./deploy.sh test installed py3

have a look at: https://testpypi.python.org/pypi/pygcode to make sure it's sane

Upload to PyPy server

all good!? sweet 👍 time to upload to 'production'

./deploy.sh prod

Test

# Python 2.x
./deploy.sh remkenv py2
./deploy.sh install pypi py2
./deploy.sh test installed py2

# Python 3.x
./deploy.sh remkenv py3
./deploy.sh install pypi py3
./deploy.sh test installed py3

have a look at: https://pypi.python.org/pypi/pygcode to make sure it's sane

Deployment in Git

merge deployed branch to master

git tag ${version} -m "<change description>"
git push --tags origin master

have a look at the releases page and it should be there.

tadaaaaaa!... go to sleep; it's probably late