/srv/irclogs.ubuntu.com/2012/10/17/#bzr.txt

=== yofel_ is now known as yofel
mgzmorning08:15
mgrandihey08:16
=== mmrazik is now known as mmrazik|afk
=== mmrazik|afk is now known as mmrazik
=== AfC1 is now known as AfC
=== AfC1 is now known as AfC
vivekimsitHi! how can I revert my changes to older revisions13:41
jelmervivekimsit: bzr revert -rX13:56
jelmerwhere X is the revision number13:56
venefyxatudoes bzr branch load everything in memory before dumping anything to disk?14:00
venefyxatuand, if yes, is it possible to disable this behaviour?14:02
vivekimsit jelmer: Thanks but let me tell you that my branch is not local i.e. I have co my branch14:03
jelmervivekimsit: you can unbind it14:07
vivekimsitjelmer: Hmm, but when I ran above command it worked fine14:07
vivekimsitbut I think changes will be in my local only14:07
jelmervivekimsit: yes14:08
jelmervivekimsit: if you want the branch to go back, you can use "bzr up -rX"14:08
jelmervenefyxatu: what do you mean?14:08
vivekimsitjelmer: ok! its is for making the changes in the server, right?14:09
mgzvivekimsit: say exactly what you want to do14:09
vivekimsitBut I have already run my command in my local branch: bzr revert -rN can I still use the above command14:09
mgzif by "revert" you mean "back out a set of changes from trunk", that's another thing14:09
vivekimsitmgz: I have my code on a server, I co from it and pushed the changes but now I want to revert my changes in the local as well as server14:10
mgzyou put the changes on the server by mistake? using a checkout probably needlessly confusing for you.14:12
venefyxatujelmer: I'm trying to branch a 568M repo from a remote host - on my local machine (4G RAM) this works fine, on my test server (600M RAM) the process dies eventually. Keeping an eye on ps aux shows me that RSS increases all the way up to +/- 416M on the server, 500something M on my local machine14:12
mgzdo you actually want the branch on the server?14:16
mgzor just to deploy to it?14:16
mgzanyway, for your original question you can either merge the inverse of the changes you want to remove, or just forcably push an old revision on top of the server14:18
vivekimsit mgz: we are a team and in which every person works on the local branch and pushes the code on the central server14:18
vivekimsit mgz: And as told told I already ran the command: bzr revert -rN on my local machine14:19
mgzyou want a central server for a team of people and a 600MB branch, and that server only has 600MB ram?14:19
mgzrevert only changes the tree.14:19
mgznot the branch, local or remote.14:19
vivekimsitmgz: So now what, my local tree is changed, should I push it on the server?14:19
mgzno. I still don't know what you're actually trying to do.14:20
vivekimsit(07:49:19  IST) mgz: revert only changes the tree.14:21
mgzeither you want to commit a change that makes the code the same as a previous revision, or you can just push up an old rev14:21
vivekimsit mgz: push up the older revision14:21
mgzthe first is for cases such as, you implemented a feature, but broke the build, and now want to change back to fix the build while you redo the feature14:22
vivekimsityes14:22
mgzthe second is for when you just messed up a push and can tell everyone else to not pull the mistaken revision14:22
vivekimsitBut the problem is that I reverted the change in my local14:22
vivekimsitSo, my server is at one revision higher than my local now14:23
mgzthat's not a problem, all you do in running `bzr revert` is change the tree14:23
vivekimsit mgz:  you got it14:23
mgzvivekimsit: that was an either/or, I still don't know if you want 1 or 214:23
vivekimsit mgz: Ya! now my next task it sync my tree with the server14:23
mgzregardless, run `bzr revert` and get your local tree back to the current branch state14:24
vivekimsitmgz: My tree: rev2, my branch:rev314:25
mgzsee also <http://doc.bazaar.canonical.com/bzr.2.5/en/user-guide/core_concepts.html> and linked docs from there14:27
mgzyour tree does not have a revision.14:27
mgzrevisions are properties of branches, you just changed the contents of the files to look like they did in the previous rev, and I still don't know if you want to back out the change or just undo it14:28
vivekimsitmgz: Let me summarize once again. I made some changes in my tree pushed it on the server but after some time I got to know that my changes were bad to by mistake I ran the command bzr revert which changed my local tree to the older and correct revision but I wanted to do the same on my server.14:30
mgzvivekimsit: okay, let's do the back out version, as that's most generally applicable14:30
mgzin which case, you should really merge the inverse of the change `bzr merge -r3..2` but for your case `bzr revert -r-2` as you did is okay (as there are no subsequent changes)14:32
mgzthat just changes the tree.14:32
mgzyou then commit that reversion, `bzr commit -m "Revert feature_branch_a which broke the build"` or whatever appropriate commit message14:32
mgzthat creates r4, which is similar to r2 but with different history,14:33
mgzand in your case as you're using a remote branch, there is no `bzr push` step.14:33
vivekimsit mgz: ok! but to let you know when I do bzr diff it shows all the differences that I don't want now will your step work fine with it?. Also I usually do local commit first and then push14:35
mgzthe diff should only show things you want to change back, otherwise something has gone wrong.14:35
mgzso, `bzr diff` should be the inverse of `bzr diff -r2..3` in your case14:36
vivekimsit mgz: whatever I don't want that diff now14:37
mgzvivekimsit: I don't understand14:38
vivekimsit mgz: Sorry you were rigth14:39
vivekimsit mgz: ok! it worked14:40
vivekimsit mgz:  Is there any straightforward solution to it14:40
mgzbuy more ram?14:41
mgzI'm not sure which conversation we're having right now.14:41
vivekimsitI have one more issue, I often work on more than one project at a time. so it becomes diff to write the name of the projects every time. Eg: bzr push lp:~XXXX/my_branch_name. Is there any way by which my current tree name is automatically picked as a branch name during the push14:48
mgzvivekimsit: yes, if you have a consistent local layout14:51
vivekimsitlike14:51
mgzsee <http://doc.bazaar.canonical.com/bzr.2.5/en/user-reference/configuration-help.html#section-options>14:51
=== hazmat is now known as kapilt
=== deryck is now known as deryck[lunch]
=== deryck[lunch] is now known as deryck
ttilleyis there a sane and reasonable method of pulling bzr down to git? maybe not even pushing back. quilt is already in use, so good enough for me, right? i just don't grok branching and merging in bzr, whereas git is dead simple and very familiar.22:27
ttilleyjust need to work on two projects at once, only one of which can be contributed back upstream (but both need to be included in the local product)22:28
ttilleyerr... s/project/branch/22:28
hazmat how can one diff a  branch at a particular non head revision with another branch23:01
hazmateven if the branch is updated to a particular rev, diff seems to use the head when diffing23:01
bob2ttilley, it's pretty simple, it's just that each clone is a branch23:02
bob2ttilley, so you'd: cd master ; bzr merge ../34559-add-bonghits23:02
bob2instead of 'git checkout master ; git merge 34559-add-bonghits'23:03
hazmatah.. bzr dif -r revno  path_to_other_branch does the trick23:03

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!