hg.py: add islocal() and defaultdest() functions, refactor
islocal tells if a repo or url is local.
defaultdest returns default path for clone if explicit path not given.
clone can now take repo or url as source
<table class="slogEntry parity#parity#">
<tr>
<td class="age">#date|age#</td>
<td class="author">#author|obfuscate#</td>
<td class="node"><a href="?cs=#node|short#">#desc|strip|firstline|escape#</a></td>
</tr>
</table>