paths

Files are matched to scopes using glob patterns.

The glob patterns are case-insensitive, and use:

  • * to match any number of characters except /
  • ** to match any number of characters including /
  • ? to match a single character
  • [...] to match a range of characters
  • [!...] to match any character not in the range
  • \ to escape special characters
  • {...,...} to match any of the comma-separated patterns

The patterns should never start with a /, as they are always matched against the relative path of the CODEREVIEW.toml file.

[[scopes]]
name = "app"
paths = ["app/**/*"]

[[scopes]]
name = "docs"
paths = ["docs/**/*", "**/*.md"]
$ git diff --name-only
app/INSTRUCTIONS.md
app/package.json
docs/README.md

$ git review diff
app/INSTRUCTIONS.md -> docs
app/package.json -> app
docs/README.md -> docs

Note that when files are renamed or moved, both the old and new paths will be used for scope matching.

$ git diff --name-status
R100    app/README.md    docs/README.md

$ git review diff
app/README.md -> app
docs/README.md -> docs