contrib/check-code.py
changeset 13012 8b167ee8242f
parent 12964 34034e55424f
child 13026 53391819f195
equal deleted inserted replaced
13011:4936a04b6792 13012:8b167ee8242f
    62     (r'[^\n]\Z', "no trailing newline"),
    62     (r'[^\n]\Z', "no trailing newline"),
    63     (r'export.*=', "don't export and assign at once"),
    63     (r'export.*=', "don't export and assign at once"),
    64     ('^([^"\']|("[^"]*")|(\'[^\']*\'))*\\^', "^ must be quoted"),
    64     ('^([^"\']|("[^"]*")|(\'[^\']*\'))*\\^', "^ must be quoted"),
    65     (r'^source\b', "don't use 'source', use '.'"),
    65     (r'^source\b', "don't use 'source', use '.'"),
    66     (r'touch -d', "don't use 'touch -d', use 'touch -t' instead"),
    66     (r'touch -d', "don't use 'touch -d', use 'touch -t' instead"),
       
    67     (r'ls\s+[^-]+\s+-', "options to 'ls' must come before filenames"),
    67 ]
    68 ]
    68 
    69 
    69 testfilters = [
    70 testfilters = [
    70     (r"( *)(#([^\n]*\S)?)", repcomment),
    71     (r"( *)(#([^\n]*\S)?)", repcomment),
    71     (r"<<(\S+)((.|\n)*?\n\1)", rephere),
    72     (r"<<(\S+)((.|\n)*?\n\1)", rephere),