git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Non-blob .gitmodules and .gitattributes
@ 2024-06-14 12:03 Alexey Pelykh
  2024-06-14 15:35 ` Junio C Hamano
  0 siblings, 1 reply; 17+ messages in thread
From: Alexey Pelykh @ 2024-06-14 12:03 UTC (permalink / raw)
  To: git

Greetings to all!

I've stumbled upon a check that ensures that .gitmodules and .gitattributes must be blobs, yet while I get why they should not be e.g. a symlink, what's the downside of permitting (and ignoring for the actual purpose) e.g. .gitattributes folder?

To better understand my use-case:

$ ls -lA dev/shared
total 8
drwxr-xr-x   3 alexey-pelykh  staff   96 Jun 14 11:53 .editorconfig
drwxr-xr-x   3 alexey-pelykh  staff   96 Jun 14 13:32 .gitattributes
drwxr-xr-x  14 alexey-pelykh  staff  448 Jun 14 11:53 .gitignore
-rwxr-xr-x   1 alexey-pelykh  staff  613 Jun 14 13:33 share

and

$ ls -lA dev/shared/.*
dev/shared/.editorconfig:
total 8
-rw-r--r--  1 alexey-pelykh  staff  377 Jun 14 11:53 shared.editorconfig

dev/shared/.gitattributes:
total 8
-rw-r--r--  1 alexey-pelykh  staff  143 Jun 14 13:32 shared.gitattributes

dev/shared/.gitignore:
total 8
-rw-r--r--  1 alexey-pelykh  staff  4450 Jun 14 11:53 shared.gitignore

Surely, the immediate workaround is use a "_gitattributes" or ".gitattributes_" name for the folder, yet if a directory with .gitignore can exist - why can't .gitmodule or .gitattributes?

Be well,
Alexey

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

end of thread, other threads:[~2024-06-20 16:20 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-06-14 12:03 Non-blob .gitmodules and .gitattributes Alexey Pelykh
2024-06-14 15:35 ` Junio C Hamano
2024-06-14 15:43   ` Alexey Pelykh
2024-06-18 18:31   ` Jeff King
2024-06-18 19:07     ` Alexey Pelykh
2024-06-18 20:14       ` Junio C Hamano
2024-06-18 23:33         ` Jeff King
2024-06-18 23:44           ` [PATCH 0/4] .git{ignore,attributes} directories? Junio C Hamano
2024-06-18 23:44             ` [PATCH 1/4] .gitignore: introduce GITIGNORE_FILE CPP macro Junio C Hamano
2024-06-18 23:44             ` [PATCH 2/4] attr: notice and report read failure of .gitattributes files Junio C Hamano
2024-06-19  0:21               ` Eric Sunshine
2024-06-19  1:18                 ` Junio C Hamano
2024-06-19  2:35                   ` Eric Sunshine
2024-06-19 13:57               ` Jeff King
2024-06-20 16:20                 ` Junio C Hamano
2024-06-18 23:44             ` [PATCH 3/4] exclude: notice and report read failure of .gitignore files Junio C Hamano
2024-06-18 23:44             ` [PATCH 4/4] submodule: ignore .gitmodules that is not a regular file Junio C Hamano

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).