-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#14: Add script to release the library.
- Loading branch information
Showing
3 changed files
with
37 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
PATH_ROOT=`readlink -f ..` | ||
PATH_REPO_CURRENT=`readlink -f .` | ||
PATH_SOURCE=`readlink -f src` | ||
|
||
|
||
# packages to generate documentation | ||
echo "Install packages for release." | ||
pip3 install docutils pygments twine | ||
|
||
# Release to PyPi | ||
python3 setup.py sdist | ||
twine upload dist/* -r testpypi | ||
|
||
# Create folder for the documentation | ||
mkdir $PATH_ROOT/httpctrl-gh-pages | ||
cd $PATH_ROOT/httpctrl-gh-pages | ||
|
||
git clone https://github.com/annoviko/robotframework-httpctrl.git . | ||
git checkout hg-pages | ||
|
||
PATH_REPO_GH_PAGES=`readlink -f .` | ||
|
||
# Generate documentation | ||
cd $PATH_REPO_CURRENT | ||
version=`cat config.txt` | ||
|
||
cd $PATH_SOURCE | ||
|
||
python3 -m robot.libdoc -v $version -F reST HttpCtrl.Client $PATH_REPO_GH_PAGES/client.html | ||
python3 -m robot.libdoc -v $version -F reST HttpCtrl.Server $PATH_REPO_GH_PAGES/server.html | ||
python3 -m robot.libdoc -v $version -F reST HttpCtrl.Json $PATH_REPO_GH_PAGES/json.html | ||
|
||
# Commit and push documentation changes | ||
cd $PATH_REPO_GH_PAGES | ||
|
||
git push https://$HTTPCTRL_USERNAME:$HTTPCTRL_PASSWORD@github.com/annoviko/robotframework-httpctrl.git --all | ||
|