tags:

views:

26

answers:

1

I am a mercurial noob, and am scratching my head trying to figure this out.

I have added a file to the repository in the past. The repo knows about it:

hg log Purchase.php

changeset:   40:0bb0a5041ae9
parent:      36:b1627cf0f7a3
user:        josh
date:        Wed Jun 30 21:41:07 2010 +0530
summary:     purchase logic

now, if I do a hg pull, Purchase.php is not included. status does not know about it. How do I get this file out?

> hg status Purchase.php

Purchase.php: No such file or directory
+1  A: 

hg pull only pulls remote changesets to your local repo doing nothing to your working directory. You need to update your working directory from your local repo using hg update.

Use the Mercurial Quick Start cheatsheet for getting the visual model of Mercurial operations. The basic concepts are "repository", "working directory", "changeset" and various verbs that stand for Mercurial commands.

Andrey Vlasovskikh
thanks for the reply. Some clarification - the file exists in the central repository (I can browse through the log and see the file there). It does not exist in the local repo or the working directory, and I cannot pull it either. The change was pushed by someone else
Sid
@Sid Is it correct, that the output of `hg log` you have included in your question is from your repo, not the central one? If it is from your repo, then `hg update` should do the job. If it is not, then try to `hg pull` again and check the output of this command, as well as `hg incoming`.
Andrey Vlasovskikh
@Andrey, thanks for your help. But both hg update, hg pull and hg incoming report that 'no changes found' or nothing to update, hence my confusion
Sid