mercurial

Mercurial: pull changes from unversioned copy

I am currently maintaining a Mercurial repository of the project I am working on. The rest of the team, however, doesn't. There is a "good" (unversioned) copy of the code base that I can access by SSH. What I would like to do is be able to do something like an hg pull from that good copy into my master repository whenever it gets updat...

How to list all files in a repository in Mercurial (hg)?

Is there a command in mercurial that will list all files currently under source control? I can do a dir /s to list all files in my folder and subfolders, but I have no idea which have been added to my repository. I have a variety of excluded file types and folders and I want verify that none of them were added before I set them up in...

Mercurial adding new file gives no match found error

I have a strange problem with updating Mercurial. Everytime when I add a file to my repository and then update another location of the repository (for example with in CI process), the error "no match found" occures. Then when I remove to whole folder and clone it again there are no problems and the new added file(s) are there. Updating a...

Bad idea to force creation of Mercurial remote heads (ie. branches)?

I am developing a centralized web application, and I have a centralized Mercurial repository. Locally I created a branch in my repository hg branch my_branch I then made some changes and committed. Then when I try to push, I get abort: push creates new remote branch 'my_branch'! (did you forget to merge? use push -f to force) I've...

How to setup a mercurial mirror?

Hi Guys, Can anybody tell me how to setup a mirror of a mercurial repository? I have a mercurial repo on my laptop, but want to auto mirror the repo on a nas drive as a form of backup. Ideally, it would be cool if the solution checks a known location for a repo, and if one doesn't exist, create it, and from then on mirror any changes. ...

Using Mercurial (hg), how to push just one file or one directory out?

Using Mercurial, we can commit one file by using hg commit file.rb or 1 folder hg commit foldername But how can we push just 1 file or 1 folder out? The whole project can be pushed using hg push ssh://[email protected]//project/code/preliminary but there seems to be no way to push out just 1 file or 1 folder? I tried the fol...

Merging changes to a workspace with uncommitted changes

We've just recently switched over from SVN to Mercurial, but now we are running into problems with our workflow. Example: I have my local clone of the repository which I work on. I'm making some highly experimental changes to our code base, something that I don't want to commit before I'm sure it works the way it is supposed to, I don't ...

Doing without partial commits the "Mercurial way"

Subversion shop considering switching to Mercurial, trying to figure out in advance what all the complaints from developers are going to be. There's one fairly common use case here that I can't see how to handle. I'm working on some largish feature, and I have a significant part of the code -- or possibly several significant parts of t...

Better Version Control (Distributed) - Minimum impact on sources - always possible to update

I am f...fed up with Subversion. Need a version control that: Can be used without affecting the sources with embedded files (like the Subversion .svn-directories), or having to check in and then check out (If you want to version control live web-site files for example). It should always be possible to bring the repository quickly up t...

Getting readable diff displays in Mercurial on Unicode files (MS Windows)

I'm trying to store some Windows PowerShell scripts in a Mercurial repository. It seems the PowerShell editor likes to save files as UTF-16 Unicode. This means that there are lots of \0 bytes, which is what Mercurial uses to distinguish between "text" and "binary" files. I understand that this makes no difference to how Mercurial stores...

mercurial hg - pushing to a cloned repositor via APACHE errors with "repository is unrelated"

Two scenarios, one work one doesn't when they both should: Scenario #1: (DOES NOT work via apache) 2 repos on Server SERVER: Repo "A", Repo "B" cloned from repo A via http://SERVER/HG/A On client: Repo A cloned from http://SERVER/HG/A Repo B cloned from http://SERVER/HG/B Added a file to repo A...

Is it good to commit files often if using Mercurial or Git?

It seems that it is suggested we can commit often to keep track of intermediate changes of code we wrote… such as on hginit.com, when using Mercurial or Git. However, let's say if we work on a project, and we commit files often. Now for one reason or another, the manager wants part of the feature to go out, so we need to do a push, but...

Review Board extension for mercurial not working on a Windows machine

I have installed mercurial and review board extension for mercurial on my Windows XP machine. In review board, I have added a repository say "MyRepo" which is on a central server. I cloned "MyRepo" to my local machine, modified a file for testing and committed to my local repo. I haven't yet pushed it to my central repo. Now I run "hg p...

How to clone a mercurial repository over an ssh connection initiated by fabric when http authorization is required?

I'm attempting to use fabric for the first time and I really like it so far, but at a certain point in my deployment script I want to clone a mercurial repository. When I get to that point I get an error: err: abort: http authorization required My repository requires http authorization and fabric doesn't prompt me for the user and ...

Forgot to include information in mercurial commit description

If you make a commit in mercurial: hg commit -m "an incomplete description of the commit" what are your options for correcting the commit description? Should I just immediately commit again with the complete description? edit Actually, you can't commit without something having changed. ...

Mercurial: Recommended way of sending a whole repository to someone

I have done some programming and I have used Mercurial for source control. I now need to send all of my code to someone else (because they are going to take over). Since all copies of a mercurial repository is a full and real repository my first thought is to first do a clone of my repository without an update and then zipping and email...

On Windows, can we put different folders in 1 Git or Mercurial (hg) repository?

On Windows, can we put different folders in 1 Git or Mercurial (hg) repository? Such as putting c:\ror c:\software projects\ruby c:\js test d:\peter_website all in 1 Git or Mercurial repository called code ? ...

Mercurial repo inside a repo

Is it possible to create a mercurial repository inside an existing mercurial repository? The idea is to handle subdirectories of a repository as different repositories, how do you do that? I'm not talking about subrepos (at least, if I understood the purpose of subrepos...), but if this is how subrepos do exist for, I got it wrong and ...

Keeping third-party libraries under a Mercurial project: Sub-repos or not?

Hello, We are developing a closed-source project, versionned with Mercurial. We are using two libraries in our project : One of those libraries is being developed by a third-party. They are using git, and we usually just pull from their repo once in a week to get the latest changes. The other library is being developed by ourselves, a...

How to expand some version keywords in Mercurial?

Hi there, In CVS I could put $LOG$ into the source file and when the file is checked in $LOG$ will be expanded into true logs in the file. But how to implement this in mercurial? Of course I mean the other keyword such as the latest checkin date and time. Thank you very much. -Stefan- ...