Console interface to Gerrit Code Review
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

262 lines
9.9KB

  1. # This is an example ~/.config/gertty/gertty.yaml with an exhaustive listing of
  2. # options with commentary.
  3. # This section lists the servers that Gertty can talk to. Multiple
  4. # servers may be listed; by default, Gertty will use the first one
  5. # listed. To select another, simply specify its name on the command
  6. # line.
  7. servers:
  8. - name: CHANGEME
  9. url: https://CHANGEME.example.org/
  10. username: CHANGEME
  11. # Your HTTP Password for gerrit. Go to the "HTTP Password" section in your
  12. # account settings to generate/retrieve this password.
  13. password: CHANGEME
  14. git-root: ~/git/
  15. lock-file: ~/.gertty.CHANGEME.lock
  16. # Each server section can have the following fields:
  17. # A name that describes the server, to reference on the command line. [required]
  18. # - name: sample
  19. # The URL of the Gerrit server. HTTPS should be preferred. [required]
  20. # url: https://example.org/
  21. # Your username in Gerrit. [required]
  22. # username: CHANGEME
  23. # Your password in Gerrit (Settings -> HTTP Password). [required]
  24. # password: CHANGEME
  25. # Authentication type required by the Gerrit server. Can be 'basic',
  26. # 'digest', or 'form'. Defaults to 'digest'.
  27. # auth-type: digest
  28. # A location where Gertty should store its git repositories. These
  29. # can be the same git repositories where you do your own work --
  30. # Gertty will not modify them unless you tell it to, and even then the
  31. # normal git protections against losing work remain in place. [required]
  32. # git-root: ~/git/
  33. # The URL to clone git repos. By default, <url>/p/<project> is used. For a list
  34. # of valid URLs, see:
  35. # https://www.kernel.org/pub/software/scm/git/docs/git-clone.html#URLS
  36. # git-url: ssh://user@example.org:29418
  37. # The location of Gertty's sqlite database. If you have more than one
  38. # server, you should specify a dburi for any additional servers.
  39. # By default a SQLite database called ~/.gertty.db is used.
  40. # dburi: sqlite:////home/user/.gertty.db
  41. # If your Gerrit server uses a non-standard certificate chain (e.g. on a test
  42. # server), you can pass a full path to a bundle of CA certificates here:
  43. # ssl-ca-path: ~/.pki/ca-chain.pem
  44. # In case you do not care about security and want to use a sledgehammer
  45. # approach to SSL, you can set this value to false to turn off certificate
  46. # validation.
  47. # verify-ssl: true
  48. # By default Gertty logs errors to a file and truncates that file each
  49. # time it starts (so that it does not grow without bound). If you
  50. # would like to log to a different location, you may specify it here.
  51. # log-file: ~/.gertty.log
  52. # Gertty listens on a unix domain socket for remote commands at
  53. # ~/.gertty.sock. You may change the path here:
  54. # socket: ~/.gertty.sock
  55. # Gertty uses a lock file per server to prevent multiple processes
  56. # from running at the same time. Example:
  57. # lock-file: /run/lockme.lock
  58. # Gertty comes with two palettes defined internally. The default
  59. # palette is suitable for use on a terminal with a dark background.
  60. # The "light" palette is for a terminal with a white or light
  61. # background. You may customize the colors in either of those
  62. # palettes, or define your own palette.
  63. # The following alters two colors in the default palette, one color in
  64. # the light palette, and one color in a custom palette. If any color
  65. # is not defined in a palette, the value from the default palette is
  66. # used. The values are a list of at least two elements describing the
  67. # colors to be use for the foreground and background colors.
  68. # Additional elements can specify (in order) the color to use for
  69. # monochrome terminals, the foreground, and background colors to use
  70. # in high-color terminals.
  71. # For a reference of possible color names, see:
  72. # http://urwid.org/manual/displayattributes.html#foreground-and-background-settings
  73. # To see the list of possible palette entries, run "gertty --print-palette".
  74. palettes:
  75. - name: default
  76. added-line: ['dark green', '']
  77. added-word: ['light green', '']
  78. - name: light
  79. filename: ['dark cyan', '']
  80. - name: custom
  81. filename: ['light yellow', '']
  82. # Palettes may be selected at runtime with the "-p PALETTE" command
  83. # line option, or you may set the default palette here:
  84. # palette: light
  85. # Keymaps work the same way as palettes. Two keymaps are defined
  86. # internally, the 'default' keymap and the 'vi' keymap. Individual
  87. # keys may be overridden and custom keymaps defined and selected in
  88. # the config file or the command line.
  89. # Each keymap contains a mapping of command -> key(s). If a command
  90. # is not specified, Gertty will use the keybinding specified in the
  91. # default map. More than one key can be bound to a command.
  92. # Run "gertty --print-keymap" for a list of commands that can be
  93. # bound.
  94. keymaps:
  95. - name: default
  96. diff: 'd'
  97. - name: custom
  98. review: ['r', 'R']
  99. - name: osx # MacOS blocks ctrl+o
  100. change-search: 'ctrl s'
  101. # To specify a sequence of keys, they must be a list of keystrokes
  102. # within a list of key series. For example:
  103. - name: vi
  104. quit: [[':', 'q']]
  105. # The default keymap may be selected with the '-k KEYMAP' command line
  106. # option, or with the following line:
  107. # keymap: custom
  108. # Commentlinks are regular expressions that are applied to commit and
  109. # review messages. They can be replaced with internal or external
  110. # links, or have colors applied.
  111. commentlinks:
  112. # Match Gerrit change ids, and replace them with a link to an internal
  113. # Gertty search for that change id.
  114. - match: "(?P<id>I[0-9a-fA-F]{40})"
  115. replacements:
  116. - search:
  117. text: "{id}"
  118. query: "change:{id}"
  119. # Any number of commentlink entries may be specified. Start each with
  120. # a "match" key and regex. Named match groups within the regex may be
  121. # used in the replacements section. Any number of replacements may be
  122. # specified. The types of replacement available are:
  123. #
  124. # Text: Plain text whose color may be specified. The color references
  125. # a palette entry.
  126. # - text:
  127. # color: ""
  128. # text: ""
  129. # Link: A hyperlink with the indicated text that when activated will
  130. # open the user's browser with the supplied URL
  131. # - link:
  132. # text: ""
  133. # url: ""
  134. # Search: A hyperlink that will perform a Gertty search when
  135. # activated.
  136. # - search:
  137. # text: "{id}"
  138. # query: "change:{id}"
  139. # This is the query used for the list of changes when a project is
  140. # selected. The default is "status:open".
  141. # change-list-query: "status:open"
  142. # This section defines default sorting options for the change
  143. # list. The "sort-by" key specifies the sort order, which can be
  144. # 'number', 'updated', or 'last-seen'. The 'reverse' key specifies
  145. # ascending (true) or descending (false) order.
  146. # change-list-options:
  147. # sort-by: 'number'
  148. # reverse: false
  149. # Uncomment the following line to disable the navigation breadcrumbs
  150. # at the bottom of the screen:
  151. # breadcrumbs: false
  152. # Uncomment the following line to close a change after saving
  153. # a review.
  154. # close-change-on-review: true
  155. # Uncomment the following line to use a unified diff view instead
  156. # of the default side-by-side:
  157. # diff-view: unified
  158. # Dependent changes are displayed as "threads" in the change list by
  159. # default. To disable this behavior, uncomment the following line:
  160. # thread-changes: false
  161. # Times are displayed in the local timezone by default. To display
  162. # them in UTC instead, uncomment the following line:
  163. # display-times-in-utc: true
  164. # Gertty handles mouse input by default. If you don't want it messing
  165. # with your terminal's mouse handling, uncomment the following line:
  166. # handle-mouse: false
  167. # Closed changes that are older than two months are removed from the
  168. # local database (and their refs are removed from the local git repos
  169. # so that git may garbage collect them). If you would like to change
  170. # the expiration delay or disable it, uncomment the following line.
  171. # The time interval is specified in the same way as the "age:" term in
  172. # Gerrit's search syntax. To disable it altogether, set the value to
  173. # the empty string.
  174. # expire-age: '2 months'
  175. # Uncomment the following lines to Hide comments by default that match
  176. # certain criteria. You can toggle their display with 't'. Currently
  177. # the only supported criterion is "author".
  178. # hide-comments:
  179. # - author: "^(.*CI|Jenkins)$"
  180. # This section defines customized dashboards. You can supply any
  181. # Gertty search string and bind them to any key. They will appear in
  182. # the global help text, and pressing the key anywhere in Gertty will
  183. # run the query and display the results.
  184. #
  185. # NB: "recentlyseen:24 hours" does not just return changes seen in the
  186. # last 24 hours -- it returns changes seen within 24 hours of the most
  187. # recently seen change. So you can take the weekend off and pick up
  188. # where you were.
  189. dashboards:
  190. - name: "My changes"
  191. query: "owner:self status:open"
  192. key: "f2"
  193. - name: "Incoming reviews"
  194. query: "is:open is:reviewer"
  195. key: "f3"
  196. - name: "Starred changes"
  197. query: "is:starred"
  198. key: "f4"
  199. - name: "Recently seen changes"
  200. query: "recentlyseen:24 hours"
  201. sort-by: "last-seen"
  202. reverse: True
  203. key: "f5"
  204. # Reviewkeys are hotkeys that perform immediate reviews within the
  205. # change screen. Any pending comments or review messages will be
  206. # attached to the review; otherwise an empty review will be left. The
  207. # approvals list is exhaustive, so if you specify an empty list,
  208. # Gertty will submit a review that clears any previous approvals. To
  209. # submit the change with the review, include 'submit: True' with the
  210. # reviewkey. Reviewkeys appear in the help text for the change
  211. # screen.
  212. reviewkeys:
  213. - key: 'meta 0'
  214. approvals: []
  215. - key: 'meta 1'
  216. approvals:
  217. - category: 'Code-Review'
  218. value: 1
  219. - key: 'meta 2'
  220. approvals:
  221. - category: 'Code-Review'
  222. value: 2
  223. - key: 'meta 3'
  224. approvals:
  225. - category: 'Code-Review'
  226. value: 2
  227. submit: True
  228. # 'size-column' is a set of customize parameters for the 'Size' column
  229. # on your dashboard.
  230. # 'type' must be 'graph', 'split-graph' or 'number'. Default is 'graph'.
  231. # 'thresholds' is for bar graphs width (when graph) or color styles
  232. # (when number).
  233. # size-column:
  234. # type: 'graph'
  235. # thresholds: [1, 10, 100, 1000]