Reputation
431
Top tag
Next privilege 500 Rep.
Access review queues
Badges
4 6
Newest
 Caucus
Impact
~16k people reached

  • 0 posts edited
  • 0 helpful flags
  • 9 votes cast
Aug
24
awarded  Caucus
Jul
27
awarded  Yearling
Jul
15
awarded  Good Answer
Dec
10
awarded  Nice Answer
Dec
10
awarded  Yearling
Sep
24
awarded  Autobiographer
Mar
9
awarded  Editor
Mar
9
revised How do I prevent apache from serving the .git directory?
grammar
Mar
8
awarded  Necromancer
Oct
5
awarded  Teacher
Aug
3
comment How do I prevent apache from serving the .git directory?
If you're worried that RewriteEngine might be off, just put RewriteEngine On before your RewriteRule. But anyhow it is tautological and redundant because the simpler RedirectMatch suffices on its own. Though even that could be simplified. Basically I am recommending my answer instead. :)
Aug
1
comment How do I prevent apache from serving the .git directory?
Why have both rules? The simpler RedirectMatch suffices on its own. (Also, the regexes don't seem quite right -- why the plus on the end?)
Aug
1
answered How do I prevent apache from serving the .git directory?
Oct
22
awarded  Supporter