'create a modified version of this path. A \'rev\' argument
indicates a new revision.
the following keyword arguments modify various path parts:
http://host.com/repo/path/file.ext
|-----------------------|          dirname
|------| basename
|--|     purebasename
|--| ext'

def new(self, **kw):

    if kw:
        localpath = self.localpath.new(**kw)
    else:
        localpath = self.localpath
    return self.__class__(localpath, auth=self.auth)
