summaryrefslogtreecommitdiff
path: root/src/udev/test/rules-test.sh
blob: 5b3acea31fbdec91ede6e4590789229a1229fe6c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
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'`