GitHub - terranpro/magit-gerrit: Magit plugin for Gerrit Code Review
source link: https://github.com/terranpro/magit-gerrit
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
This package isn't being maintained anymore.
magit-gerrit
Magit plugin for Gerrit Code Review
Installation
If you have a recent Emacs with package.el
, you can install magit-gerrit
from MELPA.
Otherwise, you'll have to download magit-gerrit.el
and ensure it is in
a directory in your load-path
.
Then:
(require 'magit-gerrit)
;; if remote url is not using the default gerrit port and
;; ssh scheme, need to manually set this variable
(setq-default magit-gerrit-ssh-creds "[email protected]")
;; if necessary, use an alternative remote instead of 'origin'
(setq-default magit-gerrit-remote "gerrit")
;; If necessary, setup alternate baseline push points depending
;; on your local settings. See their respective documentation.
;; Try the default configurations first.
(setq-default magit-gerrit-push-to 'for)
(setq-default magit-gerrit-push-format "refs/%s%s%%topic=%s")
Workflow
- Check out branch, make changes, and commit...
- Gerrit Push Commit for Code Review => R P
- Gerrit Add Reviewer => R A (optional)
- Wait for code review and verification (approvals updated in magit-status)
- Gerrit Submit Review => R S
Magit Gerrit Configuration
For simple setups, it should be enough to set the default value for
magit-gerrit-ssh-creds
and magit-gerrit-remote
as shown above.
For per project configurations, consider using buffer local or directory local variables.
/home/dev/code/prj1/.dir-locals.el
:
((magit-mode .
((magit-gerrit-ssh-creds . "[email protected]")
(magit-gerrit-remote . "gerrit")
(magit-gerrit-push-to . 'for))))
Author
Brian Fransioli ( [email protected] )
Acknowledgements
Thanks for using and improving magit-gerrit! Enjoy!
Please help improve magit-gerrit! Pull requests welcomed!
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK