Run git in a thread to avoid UI blocking