How to update the existing cherry pick patch if changes needed in git?

How to update the existing cherry pick patch if changes needed in git?

Let us discuss here to update the existing cherry pick path if any changes need to be done.

First clone the remote project repo with corresponding branch because cherry pick basically gets the changes to particular existing branch from another latest branch.

$ git clone <remote-repo-url> -b <branch>

Pull the existing cherry pick patch to the current local branch which is target remote branch.

$ git review -d <patch-id>

Update the required files in local code.

//update required files file1, file2 etc..
$ vi <file1>

Add the updated files to commit.

// add the updated files
$ git add <file1>,<file2>,...

Do the commit with existing commit message.

//do the commit with existing commit message edit
$ git commit --amend

Update the existing cherry pick patch with latest local code in upstream git.

// update cherry pick patch with new changes
$ git review

Output looks like similar indicates patch is placed successfully.

remote: 
remote: Processing changes: updated: 1, refs: 1
remote: Processing changes: updated: 1, refs: 1
remote: Processing changes: updated: 1, refs: 1, done            
remote: 
remote: Updated Changes:        
remote:   https://<remote-repo-url> <commit-message>        
remote: 
To ssh://<remote-repo-url>/<project-repo>
 * [new branch]          HEAD -> refs/for/<branch>




Python installation

Privacy Policy  |  Copyrightcopyright symbol2020 - All Rights Reserved.  |  Contact us   |  Report website issues in Github   |  Facebook page   |  Google+ page

Email Facebook Google LinkedIn Twitter
^