Commit b3df8f49 authored by Fabio Utzig's avatar Fabio Utzig Committed by David Brown
Browse files

ci: update imgtool script to to use python/pip



Switch from hard-coded python3/pip to base python/pip. Also install full
imgtool package.

Signed-off-by: default avatarFabio Utzig <utzig@apache.org>
Signed-off-by: default avatarDavid Brown <david.brown@linaro.org>
parent c94591e7
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -19,5 +19,5 @@ if [[ $TRAVIS == "true" ]]; then
    fi
fi

pip3 install setuptools twine packaging wheel
pip3 install --pre imgtool --no-binary :all:
pip install setuptools twine packaging wheel
pip install --pre imgtool
+3 −3
Original line number Diff line number Diff line
@@ -30,10 +30,10 @@ fi

cd scripts/

last_release=$(pip3 show imgtool | grep "Version: " | cut -d" " -f2)
last_release=$(pip show imgtool | grep "Version: " | cut -d" " -f2)
repo_version=$(grep "imgtool_version = " imgtool/__init__.py | sed 's/^.* = "\(.*\)"/\1/g')

python3 ../ci/compare_versions.py --old $last_release --new $repo_version
python ../ci/compare_versions.py --old $last_release --new $repo_version
rc=$?

if [[ $rc -eq 0 ]]; then
@@ -48,6 +48,6 @@ elif [[ $rc -eq 3 ]]; then
fi

rm -rf $DIST_DIR
python3 setup.py sdist bdist_wheel
python setup.py sdist bdist_wheel

twine upload --username __token__ --password "${TWINE_TOKEN}" "${DIST_DIR}/*"