Different Google Code projects for the same user do not have the same prefix, so you cannot use the prefix attribute in the auth hgrc section.
But you can do it differently. Write ~ / .hgrc as follows:
[auth] gc.username = google code username gc.password = google code password
And then for each project, create PROJECTDIR / hgrc / .hgrc that looks like this:
[paths] default = https://PROJECTNAME.googlecode.com/hg/ [auth] gc.username = https://PROJECTNAME.googlecode.com/hg/
It is important that the entry name (gc in this case) be the same between the project .hgrc and hgrc.
source share