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: Fabio Utzig <utzig@apache.org>
This commit is contained in:
Fabio Utzig 2021-02-11 19:18:43 -03:00 committed by Fabio Utzig
parent d62631af57
commit e58f48f58a
2 changed files with 5 additions and 5 deletions

View File

@ -19,5 +19,5 @@ if [[ $TRAVIS == "true" ]]; then
fi fi
fi fi
pip3 install setuptools twine packaging wheel pip install setuptools twine packaging wheel
pip3 install --pre imgtool --no-binary :all: pip install --pre imgtool

View File

@ -30,10 +30,10 @@ fi
cd scripts/ 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') 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=$? rc=$?
if [[ $rc -eq 0 ]]; then if [[ $rc -eq 0 ]]; then
@ -48,6 +48,6 @@ elif [[ $rc -eq 3 ]]; then
fi fi
rm -rf $DIST_DIR 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}/*" twine upload --username __token__ --password "${TWINE_TOKEN}" "${DIST_DIR}/*"