Add --no-pager option to git diff in py3k.

This is needed because py3k hangs when a pager opens up.
This commit is contained in:
Eklavya Sharma 2016-04-05 11:58:19 +05:30 committed by Tim Abbott
parent adff674b0e
commit 5e71777975
1 changed files with 2 additions and 2 deletions

View File

@ -67,7 +67,7 @@ done
fixer="libmodernize.fixes.fix_dict_six" fixer="libmodernize.fixes.fix_dict_six"
echo "Running python 3 compatability test $fixer" echo "Running python 3 compatability test $fixer"
echo "$python_files" | xargs python-modernize -f $fixer -j4 -n -w >/dev/null 2>/dev/null echo "$python_files" | xargs python-modernize -f $fixer -j4 -n -w >/dev/null 2>/dev/null
if git diff | grep "^+ " | grep -v '[ ]*for' | grep -v [.]join | grep -v from_iterable; then if git --no-pager diff | grep "^+ " | grep -v '[ ]*for' | grep -v [.]join | grep -v from_iterable; then
echo echo
echo "Error: the above are changes suggested by python-modernize " echo "Error: the above are changes suggested by python-modernize "
echo "to handle the list=>iterator transition in Python 3." echo "to handle the list=>iterator transition in Python 3."
@ -77,7 +77,7 @@ if git diff | grep "^+ " | grep -v '[ ]*for' | grep -v [.]join | grep -v from_it
echo "searching through the (unfortunately very spammy) full output below:" echo "searching through the (unfortunately very spammy) full output below:"
echo echo
# Clear the output # Clear the output
git diff git --no-pager diff
echo echo
echo "That was a lot of text! Read this output from the top for more readable details." echo "That was a lot of text! Read this output from the top for more readable details."
git reset --hard >/dev/null git reset --hard >/dev/null