From: Rob Herring Date: Thu, 3 Jun 2021 01:28:06 +0000 (-0500) Subject: documentation-file-ref-check: Make git check work for multiple working directories X-Git-Tag: block-5.14-2021-07-08~65^2~24 X-Git-Url: https://git.kernel.dk/?a=commitdiff_plain;h=709dedfdf3daa8719240ecff1c0b70b278005386;p=linux-block.git documentation-file-ref-check: Make git check work for multiple working directories With multiple git working directories, '.git' may also be a text file linking to the actual git tree instead of a directory. Cc: Mauro Carvalho Chehab Cc: Jonathan Corbet Cc: linux-doc@vger.kernel.org Signed-off-by: Rob Herring Reviewed-by: Mauro Carvalho Chehab Tested-by: Mauro Carvalho Chehab Link: https://lore.kernel.org/r/20210603012806.331132-1-robh@kernel.org Signed-off-by: Jonathan Corbet --- diff --git a/scripts/documentation-file-ref-check b/scripts/documentation-file-ref-check index c71832b2312b..7187ea5e5149 100755 --- a/scripts/documentation-file-ref-check +++ b/scripts/documentation-file-ref-check @@ -24,7 +24,7 @@ my $help = 0; my $fix = 0; my $warn = 0; -if (! -d ".git") { +if (! -e ".git") { printf "Warning: can't check if file exists, as this is not a git tree\n"; exit 0; }