mercurial

How to keep mercurial graph “flat”

梦想的初衷 提交于 2019-12-10 10:28:20
问题 I have a "main" repository, I clone it and make some changes in the clone. In the meantime, there are other changes in "main", so I pull them and merge them in my clone. I make more changes in the clone, and merge any other new changes from "main". This gives me this graph: When I finish my work in the clone, I push to the main repository and now the graph in "main" looks like this: I know they're topologically the same, but to me the first one is clearer (this one is a very simple case, but

In mercurial, how to setup and use per-user platform-dependent hgrc?

折月煮酒 提交于 2019-12-10 10:15:26
问题 System-level hgrc files (in /etc/mercurial and <install-root>/etc/mercurial ) are obviously platform-dependent, but how I can use platform-dependent hgrc on a per user basis? The use case is to override a system config on a specific platform. For example, we have hg on linux and solaris with different merge tools. How do I override just the solaris merge tool, when hgrc doesn't allow any control logic (like if os.uname()[0] == 'SunOS' )? 回答1: Keep a set of .<platform>.hgrc files with whatever

Unification of DVCS commands

孤人 提交于 2019-12-10 10:09:17
问题 When working on multiple (open source) projects, multiple version controll systems start to be problematic. While they share common operations, I often make mistakes by typing hg add instead git add . I remember seeing project some time ago that made access to different source control software in uniform way by providing basic commands commit/ci add etc. in shell. Depending on repository it would in turn call hg add or git add etc. I've seen Amp: http://amp.carboni.ca/ (which seems to be down

How to keep a Mercurial repository small?

本小妞迷上赌 提交于 2019-12-10 09:27:36
问题 My central repository is stored on an 8GB USB stick. I accidentally committed some big files, so the repository doesn't fit on the stick anymore. Is there a way to correct this situation? 回答1: I voted up catchyifyoutry's answer since he's got the steps you'll probably use, but here's a handy list. First, though, a reminder. If you've already pushed this repository somewhere semi-public, and people have pulled the repository, then none of the tips below will work. When next they push and you

Is it possible to pull from multiple Mercurial repositories at the same time?

大兔子大兔子 提交于 2019-12-10 08:21:06
问题 I'd like to be able to do something like this: hg pull http://server/repo1 http://server/repo2 http://otherserver/repo and have all of the changesets come down at once, with the "added x changesets with y changes to z files" message aggregating the results of all of the pulls. I'm currently doing this with a (marginally complex) bash script, but is there a way to do it with a single mercurial command (or an already-existing plugin) that I've missed? 回答1: As @James noted, if your repository

How to get revision number from Mercurial repository and paste it to NetBeans resource bundle?

只愿长相守 提交于 2019-12-10 07:25:56
问题 I have a java project in NetBeans and im using Mercurial for version controlling. I want to see my project version number in about box and i want it to be updated according to Mercurial revision number. Any ideas how to do it? :) 回答1: Following 'Version numbering for auto builds with Mercurial', you can record in a VERSION.TXT file (that you about dialog would display) the result of: hg log -r . --template '{latesttag}-{latesttagdistance}-{node|short}' Lazy Badger comments: log will be a lot

How do I get mercurial to show the diff during `hg com`?

守給你的承諾、 提交于 2019-12-10 04:17:20
问题 Is there a way to configure hg com so that in the commit message file that pops up in the external editor, instead of just showing which files were changed (in the HG: lines) it actually shows the full diff? I'd rather view the output and compose my commit message simultaneously from the comfort of my text editor as opposed to doing hg diff on the command line separately beforehand. 回答1: TortoiseHg does this out of the box: a top panel for the commit message and below that, a left pane

What is the tortoisehg gui equivalent of doing “hg push -r”

*爱你&永不变心* 提交于 2019-12-10 03:59:43
问题 I don't see the options to accomplish this. I want to only push changesets related to my default branch, not any other local branches I have. I thought I could do this by using the Repository Explorer like so: On the toolbar below the repository address, the first combo box allows me to select a branch. I set this to default. However once I push outgoing, it wants to flag local changesets not in default. Any ideas? 回答1: Aufter you determine the outgoing revisions with the green up-arrow, the

Mercurial and TortoiseHG - Update remote repository after pushing changes

安稳与你 提交于 2019-12-10 03:52:26
问题 When pushing changes to a remote repository, is it not possible to automatically run update there so the changes/files are available? 回答1: Use changegroup hook on the remote side, as described in the Mercurial FAQ. 回答2: Edit .hg/hgrc on the remote repository and add: [hooks] changegroup.UpdateOnPush = hg update 来源: https://stackoverflow.com/questions/6924143/mercurial-and-tortoisehg-update-remote-repository-after-pushing-changes

What's the best way to version control graphical assets on Windows?

[亡魂溺海] 提交于 2019-12-10 03:15:05
问题 I'm a web developer / designer, and I want to be able to version control graphic files (Photoshop / Fireworks / Illustrator / Stock Photos / etc). This would normally be fine but some of the files I have tip the scales at around 800MB, which TortoiseHG chokes on. I currently have a server I put all my files on so all my computers can access (it's my work computer and I have some flexibility as to installing some linux packages). Any advice on the best way to go about this would be appreciated