diff options
author | Johannes Sixt <johannes.sixt@telecom.at> | 2008-01-14 14:05:33 +0100 |
---|---|---|
committer | Johannes Sixt <johannes.sixt@telecom.at> | 2008-06-26 08:47:16 +0200 |
commit | cc3b7a9732f940cb0249a12cb3c02e3d83723eb0 (patch) | |
tree | 2943754e9a0cec2e1853db15e4683a00979f2784 /compat | |
parent | b2f5e2684da060dd821bf90f88df8b6dc9401a40 (diff) | |
download | git-cc3b7a9732f940cb0249a12cb3c02e3d83723eb0.tar.gz |
Windows: Make 'git help -a' work.
git help -a scans the PATH for git commands. On Windows it failed for two
reasons:
- The PATH separator is ';', not ':' on Windows.
- stat() does not set the executable bit.
We now open the file and guess whether it is executable.
The result of the guess is good enough for the list of git commands, but
it is of no use for a general stat() implementation because (1) it is a
guess, (2) the user has no way to influence the outcome (via chmod or
similar), and (3) it would reduce stat() performance by an unacceptable
amount. Therefore, this strategy is a special-case local to help.c.
Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at>
Diffstat (limited to 'compat')
0 files changed, 0 insertions, 0 deletions