In Git, you can check in a file either with 644 or 755 permissions. I would like to enforce that all .sh files would be always stored as 755 permissions so they can be immediately executed. Especially on windows environment it is easy to lose permissions accidentally.
So, is there a way to configure it, preferrably like file handling is configured with .gitattributes? It can probably be done with a hook, but is there a more clean way of doing it?