mirror of
https://github.com/zulip/zulip.git
synced 2025-11-02 21:13:36 +00:00
Fix shell script list computation to exclude files not in git.
This fixes an issue where the next commit's no-newline-and-end-of-file check was incorrectly firing on tools/phantomjs.
This commit is contained in:
@@ -80,7 +80,7 @@ for filepath in files:
|
|||||||
|
|
||||||
by_lang[exn].append(filepath)
|
by_lang[exn].append(filepath)
|
||||||
|
|
||||||
by_lang['.sh'] = [_f for _f in map(str.strip, subprocess.check_output("grep --files-with-matches '#!.*\(ba\)\?sh' $(find scripts/ tools/ bin/ -type f | grep -v [.])", shell=True).split('\n')) if _f]
|
by_lang['.sh'] = [_f for _f in map(str.strip, subprocess.check_output("grep --files-with-matches '#!.*\(ba\)\?sh' $(git ls-tree --name-only -r HEAD scripts/ tools/ bin/ | grep -v [.])", shell=True).split('\n')) if _f]
|
||||||
|
|
||||||
# Invoke the appropriate lint checker for each language,
|
# Invoke the appropriate lint checker for each language,
|
||||||
# and also check files for extra whitespace.
|
# and also check files for extra whitespace.
|
||||||
|
|||||||
Reference in New Issue
Block a user