From: Tassilo Horn <tsdh@gnu.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: emacs-devel@gnu.org
Subject: Re: Bzr help
Date: Fri, 20 Dec 2013 19:47:01 +0100 [thread overview]
Message-ID: <87ob4bgy1m.fsf@thinkpad.tsdh.org> (raw)
In-Reply-To: <8338lnbdoe.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 20 Dec 2013 20:05:53 +0200")
Eli Zaretskii <eliz@gnu.org> writes:
>> I've done "bzr pull" and "bzr merge" followed by a "bzr commit".
>
> That was a mistake: "bzr pull" in a diverged branch doesn't do what
> you think it does (bzr is not git). The first line of "bzr help pull"
> says:
>
> Purpose: Turn this branch into a mirror of another branch.
>
> which is not what you want.
>
> What you want is "bzr merge" from the remote branch, followed by "bzr
> commit". _Then_ you should be able to push. IOW, omit the "bzr pull"
> from the sequence of the commands, and you should be fine.
Ok, I see.
> Having said that, I really don't recommend working from an unbound
> branch, it will make things harder for you, due to subtle differences
> in semantics of name-sake commands to which you are used to with git.
Guessed correctly, though I usually just "git pull --rebase".
> Instead, use a bound branch, and the workflow described in
> http://www.emacswiki.org/emacs/BzrForEmacsDevs.
Yes, I'll do so.
> That way, you will have recipes for commands that DTRT. You can use
> local branches (described on that page as well), if you prefer that,
> and merge onto the bound branch immediately prior to committing
> (pushing) upstream.
Yes, that seems to be the best solution for how I'm used to work.
> Btw, is this the first time you did some local commits and tried to
> push? If not, how did your workflow look until now?
No, not the first time. I usually just edit, then review/commit with
`vc-dir', and then "bzr push" in a console. Up to now, I was just lucky
that nobody pushed in between.
>> How do I get back into a good, pushable state, preferably without
>> losing my commit 115645 (or at least the changes)? (I haven't tried
>> pushing in fear of being able to screw things up.)
>
> I think "bzr uncommit" in your branch will be able to remove all the
> mistaken commits you've made, either one by one or all of them at once
> (see "bzr help uncommit"). Then start over, this time correctly. To
> avoid losing your changes, save them first with "bzr diff -c REVNO",
> and then you will be able to reapply them.
I simply uncommitting my 3 top-most commits which left me in a state
where the original change I wanted to do was the only change in my
working copy. So I could just commit them again and push.
Thanks for the help, Eli!
Tassilo
next prev parent reply other threads:[~2013-12-20 18:47 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-12-20 16:53 Bzr help Tassilo Horn
2013-12-20 18:05 ` Eli Zaretskii
2013-12-20 18:47 ` Tassilo Horn [this message]
2013-12-20 20:37 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87ob4bgy1m.fsf@thinkpad.tsdh.org \
--to=tsdh@gnu.org \
--cc=eliz@gnu.org \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.