Extended the p function so it also supports hg and svn