summaryrefslogtreecommitdiff
path: root/.gitignore
diff options
context:
space:
mode:
authorMasahiro Yamada <masahiroy@kernel.org>2022-12-29 10:43:09 +0300
committerMasahiro Yamada <masahiroy@kernel.org>2023-01-22 17:43:32 +0300
commitb8a9ddcafc1a7ed071a44c1e9937d68e7efc8f70 (patch)
treeedde5ba7a81d5623bd2c094b51a7e9adbed91f26 /.gitignore
parent8f99eb857a96d474bfbb715ff9073b276b87ad2d (diff)
downloadlinux-b8a9ddcafc1a7ed071a44c1e9937d68e7efc8f70.tar.xz
.gitignore: update the command to check tracked files being ignored
Recent git versions do not accept the noted command. $ git ls-files -i --exclude-standard fatal: ls-files -i must be used with either -o or -c The -c was implied before, but we need to make it explicit since git commit b338e9f66873 ("ls-files: error out on -i unless -o or -c are specified"). Also, replace --exclude-standard with --exclude-per-directory=.gitignore so that everyone will get consistent results. git-ls-files(1) says: --exclude-standard Add the standard Git exclusions: .git/info/exclude, .gitignore in each directory, and the user's global exclusion file. We cannot predict what is locally added to .git/info/exclude or the user's global exclusion file. We can only manage .gitignore files committed to the repository. Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> Reviewed-by: Miguel Ojeda <ojeda@kernel.org>
Diffstat (limited to '.gitignore')
-rw-r--r--.gitignore2
1 files changed, 1 insertions, 1 deletions
diff --git a/.gitignore b/.gitignore
index 20dce5c3b9e0..22984d22d29e 100644
--- a/.gitignore
+++ b/.gitignore
@@ -4,7 +4,7 @@
# subdirectories here. Add them in the ".gitignore" file
# in that subdirectory instead.
#
-# NOTE! Please use 'git ls-files -i --exclude-standard'
+# NOTE! Please use 'git ls-files -i -c --exclude-per-directory=.gitignore'
# command after changing this file, to see if there are
# any tracked files which get ignored after the change.
#