Adding hg support