Change regexp for better matching and replace https url with ssh url for repository