1、通过gerrit-cherry-pick脚本来下载某个change并cherry-pick

gerrit-cherry-pick ssh://wangqingyuan@git.××.com:29418/××/platform/android/framework/××× 726919

FETCH_HEAD:可以查看cat .git/FETCH_HEAD 

获取gerrit-cherry-pick:

$ scp -p -P 29418 john.doe@review.example.com:bin/gerrit-cherry-pick ~/bin/

https://gerrit-documentation.storage.googleapis.com/Documentation/3.1.3/cmd-cherry-pick.html

 

2、gerrit query的用法:

ssh %s gerrit query --format=JSON --comments change:%d'
例子:
ssh -p 29418 user@git.***.com gerrit query --format=JSON --comments change:727174

不能用下面的命令:因为会出现Permission denied (publickey)的问题
ssh -p 29418 ssh://user@git.***.com gerrit query --format=JSON --comments change:727174

 

https://www.cnblogs.com/snow-backup/p/5056963.html

Logo

权威|前沿|技术|干货|国内首个API全生命周期开发者社区

更多推荐