Ship/Show/Ask
Ship / Show / Ask is a methodology to increase the pace of software teams by not having to block developers for each pull request.
It can easily be implemented with this new solution by specifying policies for teams to allow them to automatically merge certain PRs.
Here’s an example of a Revy configuration file that we use in our team to automate these three processes.
apiVersion: reviewpad.com/v0.0.4
labels:
ask:
description: ask mode
# color is the hexadecimal color code for the label, without the leading #.
color: fd5e53
show:
description: show mode
color: ffd800
ship:
description: ship mode
color: 76dbbe
groups:
juniors:
description: Group of devs that have created less than 10 PRs
kind: developers
type: filter
param: dev
where: $totalCreatedPRs($dev) < 10
rules:
onlyChangesMDFiles:
kind: patch
description: All files with extension .md
spec: $filesExtensions([".md"])
onlyChangesTests:
kind: patch
description: All files with extension .test.ts
spec: $filesExtensions([".test.ts"])
isSmallPatch:
kind: patch
description: Patch has less than 50 lines changed
spec: $size() < 50
isLargePatch:
kind: patch
description: Large patch
spec: $fileCount() > 5
changesMainFile:
kind: patch
description: Main file
spec: $hasFileName("main.js")
authoredByJunior:
kind: patch
description: Authored by junior developer
spec: $isMemberOf($name(), $group("juniors"))
protectionGates:
- name: ask
description: Standard ask process
patchRules:
- rule: changesMainFile
- rule: isLargePatch
- rule: authoredByJunior
actions:
- $addLabel("ask")
- $assignRandomReviewer()
- name: show
description: Show process - auto-merge and later review
patchRules:
- rule: onlyChangesMDFiles
extraActions:
- $assignReviewer($group("seniors"))
- rule: onlyChangesTests
actions:
- $addLabel("show")
- $merge("rebase")
- name: ship
description: Ship process - auto-merge without need for review
patchRules:
- rule: isSmallPatch
actions:
- $addLabel("ship")
- $merge("rebase")
Updated 29 days ago
Did this page help you?