How to initialize google-code project in Mercurial
Asked Answered
S

5

8

I have started a Mercurial based project on google code. I have worked in subversion for sometime, but I am confused with what to do what in Hg.

I would like help on the following:

  1. How do I initialize project (first on my local machine) (then from my local copy to google's server)
  2. How do I get my copy of a build from the server
  3. How do I update(merge/sync) my local changes back to the server

My project is in PHP and I am using netbeans

Sigfrid answered 10/11, 2009 at 22:2 Comment(1)
In addition to the replies, you can always change your default path and make it point to google: selenic.com/mercurial/hgrc.5.html#pathsLavation
M
6

Both barkmadley and RC touch on it, but what you're explicitly missing is that your order is wrong in step one. Create the empty repo on google, clone it to local, and then commit locally and push. Don't try to create it locally and then push to google. There's nothing inherently wrong with the idea of doing it that way, but it's not the workflow for which google is set up.

Mastoid answered 10/11, 2009 at 22:36 Comment(1)
The username/password for logging in can be found on your google code settings page (code.google.com/hosting/settings) --this tripped me up, so I thought I'd share.Brocklin
C
6

For what it's worth, I wrote a blog post about Managing a Google Code project with Mercurial

Camphor answered 11/8, 2010 at 17:13 Comment(0)
T
2

Here's some infos:

  • For #1: initialize the project on google-code, then clone the repository locally (hg clone ...), add you files to the directory created by the clone process and commit that (hg commit -m 'your message' then push (hg push).
  • For #2: see #1
  • For #3: to update you local copy (hg pull -u) and to commit your change hg commit followed by hg push

As mentioned by barkmadley, Hg Book is worth reading

Telephotography answered 10/11, 2009 at 22:15 Comment(0)
A
1

Hg Book should help.

when you create a project you can select the version control system used.

from there you should be able to get hg clone instructions from google code on the downloads tab.

this will give you an initial checkout of the system. Then you copy your work into it, and hg push and hg pull to sync between the google repository. To save changesets to your local copy use hg commit

Achates answered 10/11, 2009 at 22:8 Comment(0)
L
0

Try reading this user contributed wiki. It is quite straigtforward I reckon.

Lewellen answered 11/11, 2009 at 0:38 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.