-
Create and Register a user account on testpypi at test pypi
-
Add
<clone_root>
to your PYTHONPATH environment variable:set PYTHONPATH=<clone_root>;%PYTHONPATH%
export PYTHONPATH=<clone_root>:${PYTHONPATH}
-
Install the dependencies:
python <clone_root>/dev_setup.py clean
Versioning schema: {major}.{minor}.{patch}{release}{release_version}
Example: 1.0.0a0
To bump a particular segment of the version, from <clone_root>
execute:
bumpversion major -> 2.0.0a0 bumpversion minor -> 1.1.0a0 bumpversion patch -> 1.0.1a0 bumpversion release -> 1.0.0rc0 bumpversion release_version -> 1.0.0a1
Note: bumpversion does not allow version bumping if your workspace has pending changes.This is to protect against any manual updates that may have been made which can lead to inconsistent versions across files. If you know what you are doing you can override this by appending --allow-dirty
to the bumpversion command.
-
Clean distribution folders:
rmdir /s dist
rm -rf dist
-
Build mssql-scripter platform wheels and verify readme.rst, From
<clone_root>
execute:python build.py
Build a OS-Specific wheel:
python build.py build win32 python build.py build win_amd64 python build.py build macosx_10_11_intel python build.py build manylinux1_x86_64
-
Add a .pypirc configuration file:
-
Create a .pypirc file in your user directory:
Example: C:\Users\bob\.pypirc
Example: /Users/bob/.pypirc
-
Add the following content to the .pypirc file, replace
your_username
andyour_passsword
with your account information created from step 1:[distutils] index-servers= pypitest [pypitest] repository = https://test.pypi.org/legacy/ username = your_username password = your_password
-
-
Upload to pypi test server:
python register_upload.py upload pypitest
-
Test install locally
To install the local mssql-scripter wheel package, from
<clone_root>
execute:sudo pip install --no-index -i ./dist/mssql_scripter-1.0.0a1-py2.py3-none-win32.whl
-
Test install via pypi server:
Note: Specifying the test pypi server as the index to search for, pip will attempt to search for mssql-scripter's dependencies from the same server. This can result in a requirement not found error, but should not be a problem if dev_setup.py was ran during developer setup. If the error does occur, manually pip install the dependencies that are listed in setup.py and ensure the versions are correct.
Install the mssql-scripter package that was just uploaded:
pip install -i https://testpypi.python.org/pypi mssql-scripter
Upgrade to the mssql-scripter that was uploaded:
pip install --upgrade -i https://testpypi.python.org/pypi mssql-scripter