gitlab-review-bot

module
v0.0.0-...-c09d977 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 27, 2023 License: MIT

README ΒΆ

GitLab Review Bot

A server application that observes GitLab merge requests (MR) and rotates reviews using custom Review&Approve policies.

Go GitHub
gopher-in-glasses

Situation

Have you ever been tagged for an ASAP review during the day? Switching the context of the developer wastes his energy and reduces the entire team's productivity.

Down with @here tagging of whole team for MR review. Let the robot follow Review&Approve policy.

Approach

What if we delegate supervising work to a machine?

  • Reviewers assign on every MR: Why can't the bot randomly pick 2 of 5 developers of a team?
  • Remind every team member about one's distinctive MR list. Right after daily meetings in Slack.
  • Follow review rules: 2 approves move task into next status
  • Gathering statistics: measure team performance over time, search for bottlenecks

Solution

Review bot (written in Go)

  • Easy to start: just list your teammates and projects
  • Flexible: build your own review policy or choose between existing
  • Lightweight: could be run on the cloud or a tiny dedicated server
  • Open for extension: while the bot is written in go, it becomes easier to write custom Review&Approve policies using ready components and examples.

Examples of Review&Approve policy

Policy Reviews Selection Code Approval
TeamLead is always right random pick 2 devs and lead πŸ‘©β€πŸ’»πŸ§‘β€πŸ’» + πŸ§™β€β™‚οΈοΈ 1 lead
Developers riot random pick 2 devs πŸ‘©β€πŸ’»πŸ§‘β€πŸ’» 1 dev
Reinventing Democracy random pick 2 devs πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’» 2 devs

Roadmap

  • Reviewers rotation
  • Action on approved condition
  • Slack reviews reminder
    • Scheduled (e.g., after daily)
    • On user request (/mr command)
  • Statistics gathering
  • Jira task status integration
  • Custom Review&Approve policies without rebuild
  • Day off and vacation accounting

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL