Show More
@@ -1,62 +1,63 b'' | |||
|
1 | 1 | #!/bin/bash |
|
2 | 2 | set -e |
|
3 | 3 | set -x |
|
4 | 4 | |
|
5 | 5 | echo "Checking tools needed for uploading stuff" |
|
6 | 6 | pip freeze | grep '^Sphinx==' || pip install Sphinx |
|
7 | 7 | pip freeze | grep '^Sphinx-PyPI-upload==' || pip install Sphinx-PyPI-upload |
|
8 | 8 | |
|
9 | 9 | echo "Verifying everything can build" |
|
10 | 10 | hg purge --all dist |
|
11 | 11 | python2 setup.py build_sphinx |
|
12 | 12 | python2 setup.py compile_catalog # TODO: check for errors |
|
13 | 13 | python2 setup.py sdist |
|
14 | 14 | |
|
15 | 15 | echo "Verifying VERSION from kallithea/__init__.py" |
|
16 | 16 | namerel=$(cd dist && echo Kallithea-*.tar.gz) |
|
17 | 17 | namerel=${namerel%.tar.gz} |
|
18 | 18 | version=${namerel#Kallithea-} |
|
19 | 19 | echo "Releasing Kallithea $version in directory $namerel" |
|
20 | 20 | echo "Verifying current revision is tagged for $version" |
|
21 | 21 | hg log -r "'$version'&." | grep . |
|
22 | 22 | |
|
23 | 23 | echo "Cleaning before making release build" |
|
24 | 24 | hg up -c . |
|
25 | 25 | hg revert -a -r null |
|
26 | 26 | hg up -C "'$version'&." |
|
27 | 27 | hg purge --all |
|
28 | 28 | |
|
29 | 29 | echo "Building dist file" |
|
30 | 30 | python2 setup.py compile_catalog |
|
31 | 31 | python2 setup.py sdist |
|
32 | 32 | |
|
33 | 33 | echo "Verifying dist file content" |
|
34 | 34 | tar tf dist/Kallithea-*.tar.gz | sed "s|^$namerel/||" | LANG=C sort > scripts/manifest |
|
35 | 35 | hg diff |
|
36 | 36 | hg up -c . # fail if manifest changed |
|
37 | 37 | |
|
38 | 38 | echo "Now, make sure" |
|
39 | 39 | echo "* the copyright and contributor lists have been updated" |
|
40 | 40 | echo "* all tests are passing" |
|
41 | 41 | echo "* release note is ready" |
|
42 | 42 | echo "* announcement is ready" |
|
43 | 43 | echo "* source has been pushed to https://kallithea-scm.org/repos/kallithea" |
|
44 | 44 | echo |
|
45 | 45 | |
|
46 | 46 | echo -n "Enter \"pypi\" to upload Kallithea $version to pypi: " |
|
47 | 47 | read answer |
|
48 | 48 | [ "$answer" = "pypi" ] |
|
49 | python2 setup.py sdist upload --sign | |
|
49 | extraargs=${EMAIL:+--identity=$EMAIL} | |
|
50 | python2 setup.py sdist upload --sign $extraargs | |
|
50 | 51 | xdg-open https://pypi.python.org/pypi/Kallithea |
|
51 | 52 | |
|
52 | 53 | echo "Uploading docs to pypi" |
|
53 | 54 | # See https://wiki.python.org/moin/PyPiDocumentationHosting |
|
54 | 55 | python2 setup.py build_sphinx upload_sphinx |
|
55 | 56 | xdg-open https://pythonhosted.org/Kallithea/ |
|
56 | 57 | xdg-open http://packages.python.org/Kallithea/installation.html |
|
57 | 58 | |
|
58 | 59 | echo "Rebuilding readthedocs for docs.kallithea-scm.org" |
|
59 | 60 | xdg-open https://readthedocs.org/projects/kallithea/ |
|
60 | 61 | curl -X POST http://readthedocs.org/build/kallithea |
|
61 | 62 | xdg-open https://readthedocs.org/builds/kallithea/ |
|
62 | 63 | xdg-open http://docs.kallithea-scm.org/en/latest/ # or whatever the branch is |
General Comments 0
You need to be logged in to leave comments.
Login now