As part of our enhanced channels effort, and as a complement to our previous announcement on tracks, let us now introduce 'channel branches'.
<track>/stable channel you can create ephemeral 'branch' channels for hotfixes or other short-term releases. A channel now becomes a tuple of > track/stability[/branch]
Branches can be created directly from snapcraft with a name of your choosing. A branch is created when you first release a revision into it. Branch channels will only live for 30 days, after which they will be automatically closed. Any subsequent releases to the branch will reset the 30 day expiration.
Branches can only be created below the stable risk, in any track. You can think of them as hotfix channels. For example, instead of releasing an update to stable for everybody, you can release to a 'hotfix-1' channel, and then ask affected users to
snap refresh --channel=stable/hotfix-1. When branches close, users subscribed to the branch channel will fallback to the most appropriate channel, stable in this example.
Other than that, branches behave like any other channel: you can release a different revision to it, you can close it, and you can refresh or install from it.
Snapcraft 2.30 and snapd 2.25 have changes to improve the experience using branches, but you can start trying them right now:
snapcraft release <snap> <revision> [<track>/]stable/<branch>
snapcraft release foo 14 stable/hotfix-1
snapcraft release foo 15 2.1/stable/bug-123
To install a snap from a particular branch:
snap install foo --channel=2.1/stable/bug-123
You should let your users know if you have any branches available via your blog or mailing lists since they are not discoverable through the snap command.
Feedback welcome and if you have any questions, please ask!
For more information on Channels, see here.