add hg support