On FreeBSD, when executed by root ls enables the '-A' option:
-A Include directory entries whose names begin with a dot (`.')
except for . and ... Automatically set for the super-user unless
-I is specified.
As a result the .git directory appeared in the output when run as root.
Simulate no-dotfile ls behaviour using a shell glob.
Helped-by: Eric Wong <redacted> Helped-by: Junio C Hamano <redacted> Helped-by: Eric Sunshine <redacted> Signed-off-by: Ed Maste <redacted> Acked-by: Derrick Stolee <redacted> Signed-off-by: Junio C Hamano <redacted>