diff options
Diffstat (limited to 'src/udev/test/rules-test.sh')
-rwxr-xr-x | src/udev/test/rules-test.sh | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/udev/test/rules-test.sh b/src/udev/test/rules-test.sh new file mode 100755 index 0000000000..5b3acea31f --- /dev/null +++ b/src/udev/test/rules-test.sh @@ -0,0 +1,15 @@ +#!/bin/sh +# Call the udev rule syntax checker on all rules that we ship +# +# (C) 2010 Canonical Ltd. +# Author: Martin Pitt <martin.pitt@ubuntu.com> + +[ -n "$srcdir" ] || srcdir=`dirname $0`/.. + +# skip if we don't have python +type python >/dev/null 2>&1 || { + echo "$0: No python installed, skipping udev rule syntax check" + exit 0 +} + +$srcdir/src/udev/test/rule-syntax-check.py `find $srcdir/rules -name '*.rules'` |