Skip to content

Commit

Permalink
Removing whitespace from temporary variable
Browse files Browse the repository at this point in the history
  • Loading branch information
dmaljovec committed Nov 22, 2019
1 parent 69d3314 commit 0712115
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions deploy/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ set -x

# Append the version number with this git commit hash
GIT_HASH=$(git rev-parse --short HEAD)
awk -v hash=$GIT_HASH '/^__version__ = \"/{ sub(/"$/,"-"hash"&") }1' topopy/__init__.py > tmp && mv tmp topopy/__init__.py
TEMP_VERSION=$(grep '__version__ = ' topopy/__init__.py | cut -d = -f 2)
awk -v hash=$GIT_HASH '/^__version__ = \"/{ sub(/"$/,".dev"hash"&") }1' topopy/__init__.py > tmp && mv tmp topopy/__init__.py
TEMP_VERSION=$(grep '__version__ = ' topopy/__init__.py | cut -d = -f 2 | sed "s/\"//g" | sed 's/^[ \t]*//;s/[ \t]*$//')
echo $TEMP_VERSION

# Build the project
Expand All @@ -15,6 +15,6 @@ python setup.py sdist
# Test the upload
TWINE_USERNAME=__twine__
TWINE_PASSWORD=$PYPI_TOKEN
twine upload --repository-url https://test.pypi.org/legacy/ dist/topopy-$TEMP_VERSION.tar.gz
twine upload --repository-url https://test.pypi.org/legacy/ dist/topopy-${TEMP_VERSION}.tar.gz
pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple topopy==TEMP_VERSION
python -c "import topopy"

0 comments on commit 0712115

Please sign in to comment.