Is it possible to run Gerrit's commit-msg script standalone, not as hook?
I have no Gerrit hook installed I have simple commit I would like to check the Change-id of the commit Is it possible to get the change id by running some command, for example ./commit-msg xyz ? I don't want to use Eclipse. I don't want to configure hook.
The commit-msg script assumes to be run as Git hook (see example file). Therefore, it makes couple of assumptions. Executing it stand-alone (you just could have tried that, right?) fails with sed: : No such file or directory Thus, no, you cannot run this standalone. You might be able to fix it to work when called manually, but I'm unsure about your motivation. You sound like you don't want to install anything, but git-review is a nice helper.
You don't need to manually install the commit-msg hook in every repository you clone. You can configure Git to do this job for you automatically. When you execute the clone command Git copies a repository template located at: Linux = /usr/share/git-core/templates Windows = C:/Program Files (x86)/Git/share/git-core/templates If you add the commit-msg hook to the template it will be installed automatically for every cloned repository. However, the best thing to do is the following: Create a personal template (e.g. $HOME/.git-templates) Install the commit-msg in $HOME/.git-templates/hooks Configure Git to use your personal template: git config --global init.templatedir $HOME/.git-templates
What is the effect of deleting a branch in gerrit
Right way to resolve gerrit “pending changes” merge conflict
Buck build failing for “events-logs” Gerrit plugin (jar)
Disable direct push and allow Gerrit push
Set “topic” of multiple patches simultaneously in gerrit
Using Gerrit to restrict read access to a git branch
Is it possible to search for commit by Change-Id in Gerrit?
Why is the gerrit change-id commit-hook not a push-hook?
LDAP changed acccount Full Name is not displaying in gerrit web page
Can I change the order of verification and code review in gerrit
Is it possible to make review optional on any particular branch in gerrit?
customize logo on home page gerrit
Failed to start gerrit service
How to get previous patch in gerrit
Integrate Gitolite with Gerrit ACL.
How to display reset password link on gerrit portal?