Added dirty repo case + updated comments and docs.
Better conditions logic for $repo_path and $commit.