Skip to content

Instantly share code, notes, and snippets.

@Psycojoker
Created May 2, 2019 12:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Psycojoker/34b70adcbe91c06064ccf7f10cf6d825 to your computer and use it in GitHub Desktop.
Save Psycojoker/34b70adcbe91c06064ccf7f10cf6d825 to your computer and use it in GitHub Desktop.
checkout outdated dependencies with tox
#!/bin/bash
set -e
outdated_dependencies=$(pip list -o)
number_of_lines="$(echo -e "$outdated_dependencies" | grep "." | wc -l)"
if (( $number_of_lines > 0 ))
then
echo -e "$outdated_dependencies"
exit 1
else
exit 0
fi
[tox]
envlist = ...,pip-outdated
# ...
[testenv:pip-outdated]
whitelist_externals = bash
deps =
-rrequirements.txt
commands =
pip install -e .
bash check_outdated_dependencies.sh
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment