gerrit

Gerrit branch access modification through command line

北城余情 提交于 2019-12-11 07:38:04
问题 I would like to change the access rule for the deactivated branches on gerrit from "ALLOW" to "DENY".. do we have any command line options available for it ? 回答1: You can edit access rights through the Git protocol using the refs/meta/config pseudo-branch. See the docs. You checkout that branch, modify the project.config and push back to the Gerrit server. That's how you can automate this. 来源: https://stackoverflow.com/questions/23194310/gerrit-branch-access-modification-through-command-line

How to configure server side hooks in Gerrit 2.16

大兔子大兔子 提交于 2019-12-11 03:14:23
问题 I have started using Gerrit 2.16 as code review tool and want to configure server side hooks to validate the git commit message when a change is committed/pushed to gerrit. Tried using hooks by copying scripts to $GIT_DIR/hooks (scripts like ref-update, patchset-created, change-merged), gave permission on the gerrit server but nothing works. commit-msg hook can be enabled on local repository by using command give in gerrit UI example: git clone ssh://@:29418/Project1 && scp -p -P 29418 @

manual gerrit review cmd did not update “verified” label value

匆匆过客 提交于 2019-12-11 03:09:46
问题 we are trying to setup jenkins and gerrit for CI framework, gerrit can trigger Jenkins build, but can not update gerrit's verified label after build success, so i tried with manual command, still failed to update gerrit verified label field via following ssh command on jenkins server, but can update code-review label. ssh -p 29418 gfkfcmo@cmgerrit1.com gerrit review -p HiCloud/myProject --label Verified=1 --code-review +1 27263,1 1.Setup: gerrit:2.8.1 Jenkins: 2.60 gerrit trigger:2.27 Gerrit

How to abandon a whole topic on Gerrit?

元气小坏坏 提交于 2019-12-11 03:07:20
问题 So the long and short of the issue is that, in a fit of fanatical adherence to code review principles and user attribution.... I pushed around 834 commits from an upstream branch to a project's gerrit server. I was since then informed me that I ought to have (reasonably) first pushed a squashed commit for testing on gerrit and then pointed them to my repo for a merge... Luckily I had tagged the commits with a topic while uploading them (for ease of testing.... -_-) How can I now mass abandon

Is there a way to force Gerrit to have all commits in a branch be push to code review?

☆樱花仙子☆ 提交于 2019-12-11 03:07:11
问题 Gerrit will merge potentially unreviewed changes that are earlier in the commit history and are in a different 'branch' of the repository. Here's an example: checkout gerrit branch devel create file1.txt, add, commit, push to refs/heads/temp_branch create file2.txt, add, commit, push to refs/for/devel to be code reviewed When file2.txt is accepted and merged then file1.txt, because it's upstream and not in a separate change branch flagged as being under review, also gets merged in. This is

git rebase to remove a commit

家住魔仙堡 提交于 2019-12-11 02:44:33
问题 I have the following change history in my git repository: ---X---Y---Z---A---B---C I began working from a base of code Z and made three changes A, B and C. Each of these changes has been uploaded as separate reviews on Gerrit and each depends on the change before it. Following a review I want to remove change A, so that my change history is: ---X---Y---Z---B---C What is the correct flow of git rebase -i and git commit to get this to work? I assumed the following: Use git rebase -i HEAD~3 to

Gerrit-Plugin to preserve reviews/scores if pushing from Jenkins

空扰寡人 提交于 2019-12-11 02:29:45
问题 We use Jenkins to verify patch sets. Sometimes Jenkins needs to do some minor technical changes to the patch set. So it commit --amend the last patch set and then uploads it back to the Gerrit. It works nicely besides the fact, that all manual reviews made to the original patch set are get erased by the Jenkins push. The question Upload patch set preserving existing reviews showed, that it is possible to copy min/max scores on all pushes using label.LABEL-NAME.copyXXXXX options (Thanks to

Jenkins: settings for Gerrit Trigger problems

匆匆过客 提交于 2019-12-10 20:48:37
问题 I've installed the plugin Gerrit Trigger on Jenkins cos I need to start automatically the building when a developer in the team pushes something on the repository (relative to a specific project). I followed the settings here: https://wiki.jenkins-ci.org/display/JENKINS/Gerrit+Trigger The test connection is ok. Anyway when something is pushed the building doesn't "trigger". The only thing I can see is: Under "Manage Jenkins" -> The connection to Gerrit is down! Check your settings and the

Branch/change not merged, though Gerrit claims, it is

倾然丶 夕夏残阳落幕 提交于 2019-12-10 18:44:02
问题 Each time, I see merged status on my change in Gerrit and I do git pull origin , I can clearly see, that my change/branch hasn't actually been merged into master. Please, review my Gerrit's workflow and tell me, what I'm doing wrong or what am I missing: Create & checkout branch locally. git checkout -b 77-blah Do the magic and comment all changes. git commit -am "changes to 77-blah" Create the same branch using UI and setting its revision to HEAD (this should be automated soon). Push changes

Need to understand Git/Gerrit command (fetch & push)

痞子三分冷 提交于 2019-12-10 14:49:33
问题 I am following an example from our IT department, and I would like to understand what this command is doing exactly: git fetch origin +refs/changes/*:refs/remotes/origin/changes/* To give some frame of reference, this is part of a continuous integration (CI) tool, and this is part of the step to checkout the code to test. The CI build is triggered by pushing to Gerrit with: git push origin HEAD:refs/for/master I secondary question, is if I wanted to push the change into a development branch