Execute shell commands in separate thread

This brings more complexity to the code, but makes UX better for people
with huge repositories (like me).

Feel free to reject if you are not ready to make that trade-off