We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent eaabe53 commit 2d7bc7fCopy full SHA for 2d7bc7f
check/pytest-changed-files
@@ -33,14 +33,14 @@ topdir="$(git -C "${thisdir}" rev-parse --show-toplevel)" || exit $?
33
cd "${topdir}" || exit $?
34
35
# Figure out which branch to compare against.
36
-rest=$@
+rest=( "$@" )
37
if [ -n "$1" ] && [[ $1 != -* ]]; then
38
if [ "$(git cat-file -t "$1" 2> /dev/null)" != "commit" ]; then
39
echo -e "\033[31mNo revision '$1'.\033[0m" >&2
40
exit 1
41
fi
42
rev=$1
43
- rest=${@:2}
+ rest=( "${@:2}" )
44
elif [ "$(git cat-file -t upstream/master 2> /dev/null)" == "commit" ]; then
45
rev=upstream/master
46
elif [ "$(git cat-file -t origin/master 2> /dev/null)" == "commit" ]; then
@@ -78,4 +78,4 @@ fi
78
79
source dev_tools/pypath
80
81
-pytest ${rest} "${changed[@]}"
+pytest "${rest[@]}" "${changed[@]}"
0 commit comments