Skip to main content

Example: several packages in one repository

Example: several packages in one repository

Quayside keeps three packages in one repository, quayside/platform: an API, a web front end and a command-line tool. Each package has its own version, and each has its own audience: the API's users do not need to hear about a new web release.

How the team works

Every package is released on its own, with a tag that names the package and its version: [email protected], [email protected], [email protected]. A release on GitHub carries the notes of that one package. Sometimes two or three packages are released within a few minutes of each other.

What appears on GitHub

Releases in one repository whose tags start with the name of a package. To chronik they are all releases of quayside/platform; the name of the tag is the only thing that tells the packages apart, and that is what the patterns of a rule look at.

One rule per package

Create one rule for each package, all for the same repository:

API Web CLI
Which channel? #api-releases #web-releases #cli-releases
Only tags matching api@* web@* cli@*

The other switches as in Example: versions released from main: Published releases on, Pushed tags off, Include pre-releases off.

* stands for any run of characters, so api@* matches [email protected] and [email protected], and nothing of the other two packages. Matching is case-sensitive: api@* does not match [email protected].

One channel for all of them

If all three go into #platform-releases, a single rule is enough: leave Only tags matching empty, and every release of the repository gets through. Except tags matching takes out what should not go there, cli@* for example, if the command-line tool is announced elsewhere.

When the packages are released together, Collect a burst of releases into one message (Slack only) lets them arrive as one message listing every release, instead of three messages within a minute. It waits ten minutes after a release for the next one, and at most an hour in all.

What arrives in the channel

Each channel gets the releases of its package, with their notes. A release that matches no rule is passed over without a message and without an entry in the delivery log: on a repository with three filtered rules every release is passed over by two of them, and a log of that would say nothing.

What can go wrong

  • A pre-release of one package stays out while Include pre-releases is off. A tag is a pre-release when a marker follows its version number, [email protected] for example, and a release when GitHub's pre-release box is ticked. A digit inside the name of a package, like the 3 in [email protected], does not count as a version number.
  • A new package reaches none of the filtered rules until somebody adds a rule for it, and nothing says so. Show the latest releases and tags, under the patterns of a rule, shows which recent releases a rule would leave out.