Re: Q: Ignore ./foo, but not script/foo

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> How did you come up with this "./" syntax?

It is a Unix thing: "./" or just "." refers to the current directory.

When calling scripts or programs in the current directory from a Unix
command line, it is required to refer to them as, say, "./foo" (not just
"foo") -- unless "." is in your PATH.

Most people do put "." in their PATH for convenience but it is considered a
little unsafe [1].

Personally, I am surprised that gitignore does not understand this
notation. To me, OPs meaning was crystal clear: "./foo" should mean to only
ignore the foo in the repository's root directory.

[1] https://superuser.com/questions/156582/why-is-not-in-the-path-by-default

~ Tim





[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux