Improved dependency detection.

- Made dependency detection terser.
- Improved README.
- Added .gitignore.