|
1 | 1 | # Developer Documentation |
2 | | -This file primarily contains useful information for developers of `ScalaFunctional` |
3 | 2 |
|
4 | 3 | ## Release Process |
5 | 4 | For every release, the following process is used. |
6 | 5 |
|
| 6 | +### Before Release |
7 | 7 | 1. From the project directory, run `./run-tests.sh` to insure unit tests pass (on python 2 and 3), |
8 | 8 | and that pylint succeeds |
9 | 9 | 2. Push commit which is the candidate release to Github master |
10 | | -3. Wait for tests to pass on [TravisCI](https://travis-ci.org/EntilZha/ScalaFunctional) |
11 | | -4. Wait for coverage to complete at 100% on [Coveralls](https://coveralls.io/github/EntilZha/ScalaFunctional) |
12 | | -5. Wait for docs to complete building successfully at [scalafunctional.readthedocs.org/en/latest](http://scalafunctional.readthedocs.org/en/latest/) |
13 | | -6. Create an empty `virtualenv` by running `virtualenv env_directory` and activate it by running |
14 | | -`source env_directory/bin/activate` |
15 | | -7. Install `ScalaFunctional` into the virtualenv by running `python setup.py install` |
16 | | -8. Run a python terminal session and insure that `import functional` returns with no errors |
17 | | -9. Deactivate the `virtualenv` by running `deactivate` |
18 | | -10. Repeat steps 6-9 but instead use a python3 interpreter |
19 | | -11. Build the source distribution using `python setup.py sdist` |
20 | | -12. Build the wheel distribution using `python bdist_wheel` |
21 | | -13. Assuming a `.pypirc` file like below, double check that `dist/` has the source and wheel |
| 10 | +3. Wait for tests to pass on [TravisCI](https://travis-ci.org/EntilZha/PyFunctional) |
| 11 | +4. Wait for coverage to complete at 100% on [Coveralls](https://coveralls.io/github/EntilZha/PyFunctional) |
| 12 | +5. Wait for docs to complete building successfully at [docs.pyfunctional.org/en/latest](http://docs.pyfunctional.org/en/latest/) |
| 13 | + |
| 14 | +### Testing Local Release |
| 15 | +1. Run `docker run -it python bash` for clean python installation |
| 16 | +2. Clone and install `PyFunctional` with `python setup.py install` |
| 17 | +3. Run a python terminal session and insure that `import functional` returns with no errors |
| 18 | +4. Repeat steps 6-9 but instead use a python3 docker image |
| 19 | + |
| 20 | +### Building Release |
| 21 | +1. Build the source distribution using `python setup.py sdist` |
| 22 | +2. Build the wheel distribution using `python bdist_wheel` |
| 23 | +3. Assuming a `.pypirc` file like below, double check that `dist/` has the source and wheel |
22 | 24 | distributions |
23 | | -14. Run `twine upload -r test dist/*` to upload `ScalaFunctional` to the test PyPi server |
24 | | -15. Browse to the [pypi test server](testpypi.python.org) and insure the webpage looks correct and |
| 25 | + |
| 26 | +### Testing on Test PyPI |
| 27 | +1. Run `twine upload -r test dist/*` to upload `PyFunctional` to the test PyPi server |
| 28 | +2. Browse to the [pypi test server](testpypi.python.org) and insure the webpage looks correct and |
25 | 29 | that the upload was done correctly. |
26 | | -16. Create a new `virtualenv` and install the package using `pip install -i https://testpypi.python.org/pypi scalafunctional`. |
27 | | -Test that the install completes correctly and that `functional` is importable. This may require |
28 | | -installing dependencies from regular `pip` which are not on the test servers like `future`, `six`, |
29 | | -and `enum34` if running python 2. |
30 | | -17. Repeat step 16 using python 3. |
31 | | -18. If all these steps run, than the candidate release commit will become the new release which |
32 | | -means uploading to live pypi and tagging the commit as a release |
33 | | -19. Run `twine upload -r pypi dist/*` to publish `ScalaFunctional` to the live PyPi server. |
34 | | -20. Repeat steps 16 and 17 using the live pip repositories |
35 | | -21. Tag the release on git with `git tag -a vX.X.X`. Then run `git push` and `git push --tags` |
36 | | -22. On Github, create/edit the release page to match the changelog and add discussion |
37 | | -23. Celebrate! |
| 30 | +3. Run `docker run -it python bash` and install the package using `pip install -i https://testpypi.python.org/pypi pyfunctional`. |
| 31 | +4. Install dependencies not on the test PyPI instance: `future`, `six`, `dill`, and `backports.lzma` |
| 32 | +5. Test that `functional` is importable |
| 33 | +6. Repeat using python 3. |
| 34 | + |
| 35 | +If all these steps run, than the candidate release commit will become the new release which |
| 36 | +means uploading to live pypi and tagging the commit as a release. |
| 37 | + |
| 38 | +### Publishing Release on Production PyPI |
| 39 | +1. Run `twine upload -r pypi dist/*` to publish `PyFunctional` to the live PyPi server. |
| 40 | +2. Repeat install tests from Test PyPI testing |
| 41 | +3. Tag the release on git with `git tag -a vX.X.X`. Then run `git push` and `git push --tags` |
| 42 | +4. On Github, create/edit the release page to match the changelog and add discussion |
| 43 | +5. Celebrate! |
38 | 44 |
|
39 | 45 |
|
40 | 46 | ### `.pypirc` file |
|
0 commit comments