git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Missing ? wildcard character in gitignore documentation
@ 2018-01-29 11:29 Jack F
  2018-01-29 15:47 ` Randall S. Becker
  0 siblings, 1 reply; 6+ messages in thread
From: Jack F @ 2018-01-29 11:29 UTC (permalink / raw)
  To: git

Hello,

I have just noticed that the documentation for gitignore is missing
documentation on using the ? to match any single character. I have
included a example below with git version 2.14.1.

|11:05:09 j ~/Development/ls-ignore [master] $ git status On branch
master Your branch is up-to-date with 'origin/master'. nothing to
commit, working tree clean 11:05:11 j ~/Development/ls-ignore [master] $
cat .gitignore *~ node_modules yarn* 11:05:21 j ~/Development/ls-ignore
[master] $ touch test.swo 11:05:31 j ~/Development/ls-ignore [master]?1
$ git status On branch master Your branch is up-to-date with
'origin/master'. Untracked files: (use "git add <file>..." to include in
what will be committed) test.swo nothing added to commit but untracked
files present (use "git add" to track) 11:05:35 j
~/Development/ls-ignore [master]?1 $ echo "*.sw?" >> .gitignore 11:05:40
j ~/Development/ls-ignore [master]≠1 $ cat .gitignore *~ node_modules
yarn* *.sw? 11:05:51 j ~/Development/ls-ignore [master]≠1 $ git status
On branch master Your branch is up-to-date with 'origin/master'. Changes
not staged for commit: (use "git add <file>..." to update what will be
committed) (use "git checkout -- <file>..." to discard changes in
working directory) modified: .gitignore no changes added to commit (use
"git add" and/or "git commit -a")|



Noticed it when checking an npm package (ignore) that uses the
documentation (https://git-scm.com/docs/gitignore) to determine its
functionality. It is documented in
https://git-scm.com/book/en/v2/Git-Basics-Recording-Changes-to-the-Repository#Ignoring-Files

Cheers.

From,
Jack

https://bytes.nz
https://keybase.io/bytesnz


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2018-01-30 11:33 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-01-29 11:29 Missing ? wildcard character in gitignore documentation Jack F
2018-01-29 15:47 ` Randall S. Becker
2018-01-29 16:07   ` Jack F
2018-01-30 10:13   ` Duy Nguyen
2018-01-30 11:07     ` Ævar Arnfjörð Bjarmason
2018-01-30 11:32       ` Duy Nguyen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).