Verify .gitignore entries
This change adds a make target 'vcscheck' which scans the git workspace for new, untracked files missing from the .gitignore configuration; this is done to help prevent adding unwanted build artifacts to the source tree during development. Reviewed-by: Neal Gompa <ngompa@datto.com> Reviewed-by: Giuseppe Di Natale <dinatale2@llnl.gov> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: loli10K <ezomori.nozomu@gmail.com> Closes #8281
This commit is contained in:
parent
9b626c126e
commit
7b02fae7a6
|
@ -60,3 +60,4 @@ cscope.*
|
||||||
*.tar.gz
|
*.tar.gz
|
||||||
*.patch
|
*.patch
|
||||||
*.orig
|
*.orig
|
||||||
|
*.log
|
||||||
|
|
|
@ -75,7 +75,7 @@ install-data-hook:
|
||||||
ln -fs zfs.release spl.release
|
ln -fs zfs.release spl.release
|
||||||
endif
|
endif
|
||||||
|
|
||||||
codecheck: cstyle shellcheck flake8 mancheck testscheck
|
codecheck: cstyle shellcheck flake8 mancheck testscheck vcscheck
|
||||||
|
|
||||||
checkstyle: codecheck commitcheck
|
checkstyle: codecheck commitcheck
|
||||||
|
|
||||||
|
@ -117,6 +117,12 @@ testscheck:
|
||||||
xargs -r stat -c '%A %n' | \
|
xargs -r stat -c '%A %n' | \
|
||||||
awk '{c++; print} END {if(c>0) exit 1}'
|
awk '{c++; print} END {if(c>0) exit 1}'
|
||||||
|
|
||||||
|
vcscheck:
|
||||||
|
@if git rev-parse --git-dir > /dev/null 2>&1; then \
|
||||||
|
git ls-files . --exclude-standard --others | \
|
||||||
|
awk '{c++; print} END {if(c>0) exit 1}' ; \
|
||||||
|
fi
|
||||||
|
|
||||||
lint: cppcheck paxcheck
|
lint: cppcheck paxcheck
|
||||||
|
|
||||||
cppcheck:
|
cppcheck:
|
||||||
|
|
Loading…
Reference in New Issue