Thread (6 messages) flat view 6 messages, 3 authors, 2016-06-15

Re: Cherry-picking to remote branches

From: Sean Kelley <hidden>
Date: 2016-06-15 22:43:20

On 7/6/07, Sean Kelley [off-list ref] wrote:
I have been having trouble with the following workflow.  I am trying
to push changes to a remote from a branch that is tracking it.

Is there a better way to do this?  Basically I want to push from the
branch to the remote.  But it doesn't seem to work at least without
pushing the branch itself as a new head to the remote.  Perhaps the
better way to do it is to have two different directories:

1) clone the linux-devel.git and have a read-only remote to
linux-stable to fetch changes and cherry-pick.
2) clone the linux-stable.git and have a read-only remote to
linux-devel to fetch changes and cherry-pick

So you would just cd to the specific one you want to work with.

Sean
git clone git://mysite.com/data/git/linux-devel.git linux-devel

cd linux-devel

git remote add -m master -f linux-stable
git://mysite.com/data/git/linux-stable.git

git branch -r

  linux-stable/HEAD
  linux-stable/master
  origin/HEAD
  origin/master

git checkout -b stable linux-stable/master

git cherry-pick  b3b1eea69a   (a commit from linux-devel)

git push linux-stable

error: remote 'refs/heads/master' is not a strict subset of local ref
'refs/heads/master'. maybe you are not up-to-date and need to pull
first?
error: failed to push to 'git://mysite.com/data/git/linux-stable.git'

Thanks for your help,


Sean
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help