I find using hg revert -r REV is a much easier approach that using histedit. Don't do this if you have already pushed your changes. Observe that the changesets that are being merged are all 'draft' phases. Update to parent of the first changeset in set of changes you want...
If you clone a mercurial repo without any additional arguments, you make a copy of a repository this includes all branches http://selenic.com/hg/help/clone hg clone [OPTION]... SOURCE [DEST] make a copy of an existing repository Create a copy of an existing repository in a new directory. ...
I've finally fixed the error. I used the script present in /usr/share/doc/mercurial/examples/hgweb.wsgi Then the 404 error went away....
You need hg identify to answer your question and use -n to report back the local revision id: hg identify -n -r <hash> To make it really simple, most hg commands take both the local id or the global hash as valid identifiers so you could just use hg revert...
When you modify your code, you are creating changes to a text file. The text file has non memory of when and how you made your changes, it always reflects the latest version. When you tell git that you want to commit changes, git analyses the differences between the text...
mercurialserver.access: access denied It looks like your server is running mercurial-server, an extension that manages users and rights and.. that you have the right to clone/pull this repo but not to push. You should contact your server admin and ask him to give you the necessary rights....
You must have path to C:\Program Files\TortoiseHg\ in your PATH variable Open Control Panel -> System -> Advanced System Settings -> Advanced Tab -> Environment Variables Make sure that under PATH variable you have C:\Program Files\TortoiseHg\ included...
You can resolve this issue by making MQ changesets secret. The easiest way to do this is by adding the appropriate setting to your .hgrc, i.e.: [mq] secret = true This will automatically make all mq patches secret. With them secret, you should be able to push the remaining commits...
You can use the pre-commit hook to display the results of hg status --unknown - and either fail when there are unknown files or simply display files and use its output to hg add and hg commit --amend to add them to the previous commit when needed.
linux,shell,terminal,mercurial
The only workaround I have found is [extdiff] # add new command that runs GNU diff(1) in 'side-by-side' mode cmd.sdiff = sh opts.sdiff = -c 'diff -dbB --left-column -y -W `tput cols` $0 $1 | less -FRX' I also remove sdiff from the [pager] section. This looks like a Mercurial...
mercurial,atlassian-sourcetree
The error message tells you everything you need to know, provided you know what it means. A "public" changeset is one that you've either pulled from another repository, or pushed to another repository (or forcibly switched to the public phase but that's not a typical reason). Basically, is it available/shared...
What you have should work. If you're using git 1.8.5 or higher, a simpler alternative is to use the -C flag, like this: git -C "$a" diff From the man page: -C <path> Run as if git was started in <path> instead of the current working directory. When multiple -C...
Find a solution - just used :revision=>'tip': pod 'Common', :hg => "http://bitbucket.com/username/Common", :revision=>'tip'. Update: Following @Ry4an's tip, I ended up using: pod 'Common', :hg => "http://bitbucket.com/username/Common", :branch =>'default'....
mercurial,repository,tortoisehg
To create a bare repo when cloning use the no update flag when cloning i.e. hg clone --noupdate ... To convert to a bare repo update to the "null" branch use hg update null...
The simplest solution is to make a "temporary" commit: # Possibly: git add any untracked new files git commit -am "INTERIM commit - WIP" # need "rebase" here, because we want to discard # our temporary commit later git pull --rebase # resolve any possible conflicts git reset HEAD~1 #...
mercurial,command-line-arguments,tortoisehg
A file in Hg doesn't have a specific revision number associated with it ("the most recent revision in which this file was changed") A single file can have multiple "most recent versions" in different branches. This command lists all files in a certain revision: hg Manifest hg manifest [-r REV]...
It looks like your installation crashed towards the very end, when creating the mercurial directory in the system-wide dist-packages. Everything else before that looks like it worked, which would explain why you can run hg. Since you don't have sudo permissions, you can try to install the module in your...
I'm sorry I'm afraid you can't. If you had committed them, you could have used hg revert to restore the files to their checkout state. But as Mercurial has never heard of these files, it cannot help you.
Due to a critical security patch, the fix is to do the following; Preferences -> mercurial -> extensions -> uncheck hgsubversion This is explained by Atlassian as per this article. Credits to Pedro Campos for the heads up...
In short, Mercurial is already giving you the hint. You can pull in remote changes anytime. But you can't merge them with your changes, if you have uncommitted changes in your working directory. So just commit those (or shelve them, if you're not done yet), do a merge, resolve any...
If you want to see all modified files, you could just run hg diff without arguments. More generally, you could use something like hg status -mn0 | xargs -0 hg diff Here hg status -mn0 prints the file names of modified files delimited by a null byte, which is a...
As I mentioned in my question that I recently changed repository url. The issue was that new server's key was not cached in the registry where jenkins was hosted. Resolution: I logged in to the administrator account(same account used by jenkins) on my server through RDP and on the other...
If you have a Mercurial repo, you will need to have full and complete access to the entire history of the working directory. However, you can hg clone a repo and only include certain branches in the clone and as long as you are careful about how those branches interact,...
mercurial,tortoisehg,file-search
I can very much advise using the hg help system for this. The most useful pages to look at (in my view): hg help revsets hg help filesets hg help patterns In the page about patterns, you can find about 'path:': To use a plain path name without any pattern...
version-control,mercurial,branch,branching-and-merging
You cannot pull them in another branch in a sense how mercurial uses branch (as in named branch created by hg branch). However, you simply can continue to work on top of your latest commit and later merge your head and the head created by the pull request, thus both,...
Simply use hg lfconvert --to-normal <old> <new> This will convert the repository in directory <old> to a repository in directory <new> with all large files turned back into normal files. Revision hashes will change, but otherwise, the revision history should remain intact. If you actually want to first strip all...
version-control,mercurial,branch,tortoisehg,branching-and-merging
With TortoiseHg, enable either the strip or mq extension via File, Settings, global settings tab, Extensions. Then right-click the obsolete changeset, Modify History, Strip... will remove the changeset, assuming it hasn't been pushed yet.
android,android-studio,mercurial,continuous-integration,teamcity
Finally managed to get an answer to my own question.Some files were kept in the .hgignore folder as a result of which it did not get checked out during TeamCity build.Removing those from the .hgignore folder solved the problem for me.
git,mercurial,bitbucket,release
Not currently (Q4 2014/Q1 2015). Any feed issue is managed in "notifications". The closest you have from feeds (for release or anyhting else) is: the dashboard newsfeed for commits The event sources API (to help you detect events, and make your own feed) Original answer, regarding the possibility to upload...
mercurial,atlassian-sourcetree
hg rollback is deprecated. The current recommendation is to use hg commit --amend. From http://www.selenic.com/mercurial/hg.1.html#commit: The --amend flag can be used to amend the parent of the working directory with a new commit that contains the changes in the parent in addition to those currently reported by hg status, if...
java,eclipse,mercurial,atlassian-sourcetree,jrebel
you should just add the .metadata folder to your mercurial ignore list. If you've already committed the file to your repo, then you need to do something like this: hg remove -Af .project Stop tracking from the context menu I think does the same thing....
One command that is particularly suited for this is: hg commit --amend It allows you to create a commit and keep improving it (amending it). Every time you do 'hg commit --amend', all additional changes in the working directory are added to it. I know this does not sound 'shelve-like',...
django,apache,mercurial,django-rest-framework,avahi
Turns out the culprit was not having the djangorestframework package installed for the correct version of Python on the server!? Hopefully this helps someone later down the line.
There is some missing information here, so I'm not sure I know what your problem is. I'll try to take some educated guesses and cover a number of possibilities. Feel free to ask back if I failed to address your problem adequately. First, you can definitely just create new branches...
I think you'll need: hg log --branch <branchname> See hg help log for more information...
python,osx,path,mercurial,homebrew
By default the formula only uses system Python. You can bypass Superenv (which sanitizes PATH) and it should pick up whatever is in PATH when building from source: $ brew reinstall mercurial --build-from-source --env=std $ head -n 1 /usr/local/bin/hg #!/usr/local/opt/python/bin/python2.7 ...
Here's what I think you want: hg revert -r GOOD_REVISION_NUMBER --all hg commit -A -m "reverting back to revision GOOD_REVISION_NUMBER" Once that is committed, as soon as someone pulls from you (or you push to them) they will get the most recent revision containing only the good stuff. If they...
You almost certainly have another mercurial package or module in your path somewhere. Since you use sys.path.append() the library.zip file is searched last for the module. Your best bet is to add library zipfile to the Python module search path at the start: sys.path.insert(0, r'C:\Program Files (x86)\Mercurial\library.zip') ...
hg addremove is usually not needed during merges. Except when you manually add or remove a file during a merge with conflices where the merge is not automatically handled. However personally I don't recommend to use hg addremove anyway, especially in merge cases, as I consider it wiser to add...
hg clone http://localhost:8000/ . Specifying the destination viz.current working directory(.) solved it. ...
git,mercurial,docker,dockerfile
It's not possible yet because docker build doesn't support build-time parameters, although I think this feature may be coming soon. You'll have to do a build using the docker context for now. For example, if you look at the way hub.docker.com auto-build works, you have to add a deploy key...
version-control,mercurial,symlink,symlink-traversal
You can't. For security reasons, Mercurial never traverses symbolic links.
version-control,merge,mercurial,tortoisehg
Doing the merge vice versa (your changes into v3.6 might work better. Also make sure that you have selected a reasonable merge tool (internal works, but there are possibly more convenient ones out there, I use kdiff3 myself): I assume you have a repository with v3.5 and on top of...
Steps 1-5 leave the main and first repositories in the following state, assuming a r1-r3 was the original state of main: Main: r1--r2--r3 First: r1--r2--r3--r4 Steps 6-11 copy first to second, commit something to second, and push it back to main: Main: r1--r2--r3--r4--r5 First: r1--r2--r3--r4 Second: r1--r2--r3--r4--r5 Steps 12-15 go...
android-studio,gradle,mercurial
To use PROJECTB in PROJECTA you have to do following: Modify your PROJECTA settings.gradle to include PROJECTB and define PROJECTB path include ':app', ':PROJECTB' project(':PROJECTB').projectDir = new File(settingsDir, '../PROJECTB') and then add PROJECTB as dependency to your PROJECTA build.gradle dependencies { ... compile project(':PROJECTB') } ...
jenkins,mercurial,mercurial-extension,maven-scm-plugin,mercurial-keyring
Found the solution: Even when the user (jenkins) had valid WRITE access on the target RhodeCode/Merurial repository and either ~/.hgrc or mercurial_keyring setup wsa configured successfully (i.e. username/password less hg operations after one time manual entry), Maven SCM plugin scm:checkin and scm:tag operation were still failing. The reason for that...
version-control,mercurial,tortoisehg,revert
To see the current branch: hg branch (From TortoiseHg Workbench, you see the current branch next to "* Working Directory *" at the top.) To update the working directory to the default branch: hg update default (From TortoiseHg, use Repository --> Update...) Now that you are in the default branch,...
version-control,merge,mercurial,commit,tortoisehg
You can use the 'histedit' extension for this. To activate it, add the following to your hgrc: [extensions] histedit = If these are the only unpushed changesets, you can use hg histedit --outgoing. Once in the histedit interface, 'fold' will be a useful action for you (it allows combining your...
Mercurial offers the commands hg rebase (~ git rebase) and hg histedit (~ git rebase --interactive). As you haven't pushed any of your changes yet, I recommend to simply use rebase: hg rebase -sXXX -dYYY where XXX is the first changeset to move and YYY the changeset on top of...
You probably want some combination of hg status -mad to list all Modified, Added and Deleted files, and hg diff <filename> to show the changes in a particular file....
I would recommend fixing your recent history. This is somewhat messy, but once finished, Mercurial's merges should work correctly out of the box. First, find the most recent point at which the feature and main branches were exactly the same. Merge the equivalent commits (merge main into feature). This should...
A new head can be created in three ways: * when you need to use --force on the push command, a new head is created on the repository you push to. Hint: Do never use --force (or its equivalent -f) with push when you do not have to * when...
Depends on whether you committed the deletion of the files, but I assume you didn't and it doesn't seem so. Then you can simply revert them in order to restore them to your working dir: hg revert file.txt. After that you can update to the previous revision without this question...
version-control,merge,mercurial,branch,tortoisehg
You can't. When merging you always merge the complete branch up to that point, not just a single changeset. You got two options. You can "graft" or "transplant" (depending on the version of Mercurial you're using) the single changeset from one branch to another. This will effectively (try to) apply...
Basic prod-test-dev flow would look like this: Create new repository (or start with existing one). For start you have to create three named branches with following commands: hg branch prod hg commit -m"prod branch" hg branch test hg commit -m"test branch" hg branch dev hg commit -m"dev branch" After you...
git,mercurial,workflow,branch,rebase
OK so this is the workaround I came to. Maybe there is a proper solution. Anyway, this works. $ # Create branch develop at rev 0. $ hg up -r 0 $ hg branch develop $ hg ci -m 'creating branch develop' $ $ # Rebase all commits into the...
You can use regular expressions and the sub() function to accomplish that. For example: hg log --template '{sub("^(.{0,50})(.|\n)*","\\1",desc)}\n' The sub() function takes three arguments, the pattern, the replacement, and the string to be processed. In this example, we use a group that captures anywhere from 0 to 50 characters (except...
According to Hooks wiki-page Hooks can be implemented as either external programs, or internal python calls. i,e you can't write hg COMMAND directly in [hooks] section, but can write yjis command in shell-script, which in called in hook. Something like [hooks] update = updatehook with updatehook.sh | updatehook.bat in...
My solution was to use Linux with cvs2hg python script and a copy of the repository.
git read-tree -um @ $thatcommit will do it. That's "transition the index and worktree from the HEAD aka @ commit to $thatcommit, as for checkout (but without touching HEAD)". When what you're doing isn't a good match for any of the convenience commands, the core commands have your back :-)...
According to Hooks doc, hook must be executable in given environment program, it haven't predefined location, but have to be found by OS. Thus: For pure Windows, hook must be named precommithook.bat It must be placed into dir in $PATH or full path used in hook definition As result, with...
That's... not what revsets are for. You want to do something rather different: hg log --rev [changeset] --template "{branch}\n" See hg help templates....
A general advice when using Maven is to use a Maven Repository Manager such as Nexus. In this case Nexus has the addtional benefit that it can host your jars. So I advice to do the following: Configure a CI (e.g. Jenkins) job to build projectA and deploy the JAR...
None. From the Understanding Mercurial page: When you commit, the state of the working directory relative to its parents is recorded as a new changeset (also called a new "revision")... and further down the page: Mercurial groups related changes to multiple files into single atomic changesets, which are revisions of...
The following steps solved the problems for me: Use hg debugsetparents to replace the corrupted parent revision number 893e15ecb5b4 with the correct one I had updated to before using unshelve Because the above had left me in a state where Mercurial had forgotten all local changes, I had to use...
Your question reveals an illuminating misconception. When one says that Mercurial is a Distributed Version Control System (DVCS), it means that there is no ‘master‘ repository. When you type hg push <repo> or hg pull <repo>, then Mercurial compares the changesets in the current repository with those in <repo>, and...
android,mercurial,android-studio,hgignore
I suggest you add all the files listed above to .hgignore except for the build.gradle and settings.gradle. The files in .idea directory are generated automatically by Android Studio and you shouldn't track them, or manually edit. I don't think you will ever need to edit gradlew or gradlew.bat so you...
Information from where repository is cloned is written in .hg/hgrc file in your repository. Create that file (if it does not exist) and add following lines [paths] default = https://my.parent.repository Similary, if you want repository to think it is not clone of any repository, just remove those lines if they...
In general, source control is for human output not build artifacts. Consider have the build artifacts go into a dedicated artifact repository or separate repo. If that's not workable maybe have the build merge default into a ci branch, do the build, and commit to ci. Then you'll always have...
Since you stated the files were only changed locally, the following assumes the files were new files: hg add fileone.java filetwo.java hg commit -m "mini-feature" hg push This will leave filethree.java uncommitted in the working directory. Instead, if you made modifications to files already committed to the repository: hg commit...
Finally, I knew what was wrong here. I need to build the NuGet solution first and then continue with NuGet packaging and publishing in TeamCity. I hope this answer will save somebody's time in the future....
You want to use: [paths] default = file:///home/user/myscript/ default-push = file:///home/user/myscript/ ...
Unfortunately the answer seems to be no. I just debugged into the hook mechanism of hg 3.1, and the information about which command was issued is not propagated into the hook function. The only way I can think of is to hack something ugly with the debugger api to extract...
matlab,version-control,mercurial
Thanks to everyone who commented and to those who took the time to read my question. I am loathe to ask questions, since I never think my queries are so novel as to be previously un-asked. But in this case, I was finding it hard to come up with the...
I can reproduce this. It seems to be a bug in 3.3. If you change the Shell in File, Settings, TortoiseHg and use the same command with forward slashes, or double backslashes, it works: c:/windows/system32/cmd.exe /k title %(reponame)s or c:\\windows\\system32\\cmd.exe /k title %(reponame)s It also works with the following since...
version-control,mercurial,repository,tortoisehg,hgignore
I believe this should work fine if you change the syntax to syntax: regexp. Glob syntax doesn't support rooting. Per hg help hgignore: Neither glob nor regexp patterns are rooted. A glob-syntax pattern of the form *.c will match a file ending in .c in any directory, and a regexp...
git,merge,mercurial,nopcommerce
You probably guessed right about the source of your problem. Git sees two completely separate histories and has no idea what to do with them. You can solve this using git replace: Find the latest common ancestor between your history and theirs (=the latest commit that has a copy in...
android-studio,mercurial,bitbucket
No, there isn't one. Both the Git and the Mercurial plugin for Android Studio require the installation of the corresponding command-line tool for working with version control (Git or Mercurial). You don't need to install any additional GUI tools such as SourceTree....
You can revert those files. hg revert fileyouwanttorevert otherfileyouwanttorevert
It sounds like you only committed to your local clone of the repository. You have to hg push the commit to the remote repository you originally cloned, if that is the repository the teammate is cloning.
For access-protocols, which Mercurial's and Git's repositories can share (http/s/ + ssh), in order to uniquely identify remote side's type, special type of protocol used - git+real-protocol:// Sample for SSH-repo on GiHub (I just haven't https-URL in hands) >hg clone git+ssh://[email protected]/lazybadger/Fiver-l10n.git destination directory: Fiver-l10n importing git objects into hg updating...
mercurial,clone,config,tortoisehg
Set the hostfingerprint in your global config file, then do a normal clone. --insecure will no longer be needed. From the hgrc docs: On Unix, the following files are consulted: /.hg/hgrc (per-repository) $HOME/.hgrc (per-user) /etc/mercurial/hgrc (per-installation) /etc/mercurial/hgrc.d/*.rc (per-installation) /etc/mercurial/hgrc (per-system) /etc/mercurial/hgrc.d/*.rc (per-system) On Windows, the following files are consulted: /.hg/hgrc...
I'm not entirely clear whether you want to squash C and D, creating a new commit C', or whether you want to squash B, C, and D, creating a new commit B', which will keep the original bookmark. For the first: hg rebase -s 'children(bookmark)' -d bookmark --collapse -m <msg>...
You should have a look at the possibilities of the Mercurial revsets domain specific language: hg help revsets For instance, if you want to print only the changesets of branch "default" which are merges, you would specify "merge() and ancestors('default')". Now you can ask for the parents of these merges...
You can use hgtk log to reorder patches like this: ...
commit --amend command creates a backup in the .hg/strip-backup directory. So what you need to do now is to perform hg unbundle .hg/strip-backup/<your-backup-name> Where <your-backup-name> is the name of backup is the one that was told you when you performed amend. After you do that - the original changes are...
I see two possible solutions, you can either overwrite the uwsgi_param or use $remote_user a default value for the variable $ssl_client_s_dn_cn. To overwrite the uwsgi_param (this should also work with fastcgi_param), use the map directive as you suggested (just remove the ";" after "}"), and use the if_not_empty parameter for...
Is that an expected behavior and I am just missing something? Yes, this is normal behavior. You need to do hg addremove (or manually hg add and hg rm the individual files) if you want Mercurial to track file creation and deletion. Renaming should be done with hg mv....
Yes, it's documented in the project's source code: Replacing the Mercurial version is fairly trivial. Just replace the version of Mercurial in MacHg/LocalMercurial. Ie replace MacHg/LocalMercurial/mercurial MacHg/LocalMercurial/hgext MacHg/LocalMercurial/mercurial-<version>-py2.6.egg-info With the new version. Be careful to maintain the extensions in hgext which are not in the new version hgext. Eg histedit,...
hg reports a "head" for every named branch. In your screenshot, you are needing to push rev 154, which is the head of your kjeld branch. It is an outgoing changeset because you are pushing rev 155 and you must therefore push 155's entire history as well. Others will get...
Do you use 'vi' as symlink to vim? That can apparently cause issues. Try adding the following (or use a more recent vim) and see if this fixes it: [ui] editor = vim ...
ubuntu,installation,mercurial,tortoisehg
You can find out where in your path an application exists using the type command like this (when using bash): [email protected]:~$ type -a hg hg is /usr/local/bin/hg It's possible it was installed as a python package in which case the command would be: pip uninstall mercurial but it might just...
Preface You must to know 2 things: all files|directories exist in all changesets of repository only one active point (parent of working directory) may exist in one repository Partial Solution: Mercurial If RO changeset as set of static objects, unrelated to repo, is sufficient for you, you can hg archive...
You need to push via ssh, meaning you need to push via: hg push git+ssh://[email protected]/<login>/<repo> Note the usage of [email protected] instead of your login in the first part of the URL. This actually matters; the server will figure out your credentials via the supplied SSH key. You may also have...
You can view the contents of a file by using hg cat <file> command with the optional revision option: hg cat -r [rev] [filename] You could then pipe that output to a temp file for review. For example on Windows you could do: hg cat -r [rev] [filename] > C:\temp\tempfile.txt...
Yes they do run for these operations: they run for every commit created on the local repo. You can convince yourself that they run with a simple test like: hg graft 10 --config hooks.precommit="echo 'hook ran'" It will print hook ran when the hook is called...
The following is a part of hg help log: Note: for performance reasons, log FILE may omit duplicate changes made on branches and will not show removals or mode changes. To see all such changes, use the --removed switch. So you should be able to see both changesets this way....