Custom Search

Thursday, November 26, 2015

How to git cherry-pick fix conflicts and edit commit message

1)
* -e --> to edit commit message
$ git cherry-pick -e ffed960e08b1aa340e020decc7cb5a735e7185ce
error: could not apply ffed960... update to working version of contrail module
hint: after resolving the conflicts, mark the corrected paths
hint: with 'git add ' or 'git rm '
hint: and commit the result with 'git commit'

2)
$git diff
Fix conflict

3)
$ git add Puppetfile

4)
$ git status
On branch kilo_multinode_contv2
You are currently cherry-picking commit ffed960.
  (all conflicts fixed: run "git cherry-pick --continue")
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:

    modified:   Puppetfile
    modified:   manifests/neutron/contrail/fip_pool.pp

5)
$ git cherry-pick -e --continue
[kilo_multinode_contv2 ba0dd5a] [bode] update to working version of contrail module
 Author: Dan Bode
 2 files changed, 7 insertions(+), 2 deletions(-)

6)
abort cherry-pick which has conflict and not required.
$ git cherry-pick --abort



1 comment:

  1. please, can be upload Contrail package on any upload site , because Juniper disapprove because of public mail and not have private mail for download

    Thanks

    ReplyDelete