Improving git shell integration

- Show detached HEAD state
- Get rid of error messages when working inside submodules
- Correcting symbols shown for unmerged files
- Show extra info when working inside the .git directory
- Show extra info when working with bare repositories
- Performance improvements