1

None of my files pushed are showing up on the remote server, even though it said the push was an success. I'm stumped. Can anyone give me a hand?

Strawberry
  • 1,132
  • 4
  • 15
  • 27

2 Answers2

2

I just spent 1 hour wasting my time to find out that I need to do hg update on the server. There's a hook that belongs in your hgrc. For me, it was in the cgi-bin/hgweb.config

Add:

[hooks]
changegroup = hg update
Strawberry
  • 1,132
  • 4
  • 15
  • 27
  • Do you need a current working copy on the server? Leaving it naked with no working copy whatsoever should work just fine if it's just a push/pull target. – Shane Madden Feb 27 '12 at 01:04
  • I don't understand the question. What do you mean by "working copy"? I'm assuming you mean a work copy of mercurial? Well, I use its web to easily look at things with its GUI. – Strawberry Feb 27 '12 at 01:19
  • 2
    You need to understand the difference between a "bare" repository and a repository that contains a "working copy". Pushing and pulling do not update the working copy of a repository. – daff Feb 27 '12 at 01:53
2

Apparently your remote repository is not bare, but contains a working copy. Pushing and pulling do not update the working copy. This is what you are seeing.

The bigger question is: why do you need your remote repository to contain a working copy in the first place? This is usually neither desired, nor useful. What is your workflow here? I suspect you may want to read this article on publishing Mercurial repositories carefully: http://mercurial.selenic.com/wiki/HgWebDirStepByStep

daff
  • 4,809
  • 2
  • 28
  • 27