1)
Open one bug or blueprint
https://review.openstack.org/#/c/115234/
2)
Clone the source code of the project from github (master branch)
For example: Copying the source code of OpenStack Heat project.
#git clone https://github.com/openstack/heat.git
3)
Goto the project directory
#cd heat
4)
Get the changes from https://review.openstack.org/#/c/115234/
4,1)
Get the patch from https://review.openstack.org/#/c/115234/ and apply
a)
Goto https://review.openstack.org/#/c/115234/ and Click on "Patch" tab and copy the link.
Then goto the project directory and append the copied link with command "patch -p0 < " and execute
Example:
#patch -p0 < 'copied_link'
#patch -p0 < `git fetch ssh://sajuptpm@review.openstack.org:29418/openstack/heat refs/changes/34/115234/8 && git format-patch -1 --stdout FETCH_HEAD`
b)
Run "git diff", so you can see the diff
#git diff
4,2)
Checkout the commit (including commit message) from https://review.openstack.org/#/c/115234/
a)
Goto https://review.openstack.org/#/c/115234/ and Click on "checkout" tab and copy the link.
Then goto the project directory and append "-b new_branch" at the end of the copied link and execute. This will create a new branch named "new_branch" and apply the commit there.
Example:
#git fetch ssh://sajuptpm@review.openstack.org:29418/openstack/heat refs/changes/34/115234/8 && git checkout FETCH_HEAD -b new_branch
b)
Confirm the commit. You can see the commit message here.
#git log -n 1
4,3)
cherry-pick the commit (including commit message) from https://review.openstack.org/#/c/115234/
a)
Goto https://review.openstack.org/#/c/115234/ and Click on "cherry-pick" tab and copy the link.
*Then goto the project directory and create a new branch
#git branch new_branch
*Then goto the new_branch
#git checkout new_branch
*Then paste the link and execute it
Example:
#git fetch ssh://sajuptpm@review.openstack.org:29418/openstack/heat refs/changes/34/115234/8 && git cherry-pick FETCH_HEAD
b)
Confirm the commit. You can see the commit message here.
#git log -n 1
Open one bug or blueprint
https://review.openstack.org/#/c/115234/
2)
Clone the source code of the project from github (master branch)
For example: Copying the source code of OpenStack Heat project.
#git clone https://github.com/openstack/heat.git
3)
Goto the project directory
#cd heat
4)
Get the changes from https://review.openstack.org/#/c/115234/
4,1)
Get the patch from https://review.openstack.org/#/c/115234/ and apply
a)
Goto https://review.openstack.org/#/c/115234/ and Click on "Patch" tab and copy the link.
Then goto the project directory and append the copied link with command "patch -p0 < " and execute
Example:
#patch -p0 < 'copied_link'
#patch -p0 < `git fetch ssh://sajuptpm@review.openstack.org:29418/openstack/heat refs/changes/34/115234/8 && git format-patch -1 --stdout FETCH_HEAD`
b)
Run "git diff", so you can see the diff
#git diff
4,2)
Checkout the commit (including commit message) from https://review.openstack.org/#/c/115234/
a)
Goto https://review.openstack.org/#/c/115234/ and Click on "checkout" tab and copy the link.
Then goto the project directory and append "-b new_branch" at the end of the copied link and execute. This will create a new branch named "new_branch" and apply the commit there.
Example:
#git fetch ssh://sajuptpm@review.openstack.org:29418/openstack/heat refs/changes/34/115234/8 && git checkout FETCH_HEAD -b new_branch
b)
Confirm the commit. You can see the commit message here.
#git log -n 1
4,3)
cherry-pick the commit (including commit message) from https://review.openstack.org/#/c/115234/
a)
Goto https://review.openstack.org/#/c/115234/ and Click on "cherry-pick" tab and copy the link.
*Then goto the project directory and create a new branch
#git branch new_branch
*Then goto the new_branch
#git checkout new_branch
*Then paste the link and execute it
Example:
#git fetch ssh://sajuptpm@review.openstack.org:29418/openstack/heat refs/changes/34/115234/8 && git cherry-pick FETCH_HEAD
b)
Confirm the commit. You can see the commit message here.
#git log -n 1
No comments:
Post a Comment