Snapcraft corner: Staying on track

by Igor Ljubuncic on 27 August 2020

Snapcraft channels and, consequently, tracks are an important, highly useful element of the snap ecosystem. Tracks enable snap developers to publish multiple supported releases of their application under the same snap name. All snaps must have a default track – called latest, but there can be many others, giving both developers flexibility in how they release their applications to end users.

So far, track management was only possible through the Snap Store Web interface, which we have extensively reviewed last week. Now, you can view tracks, and very shortly, you will also be able set the default track using the snapcraft command line. We wanted to use this opportunity to showcase this upcoming set of features.

Ready, snap, set

The first thing you may want to do is check the availability of existing tracks for a given snaps. This can be done using the snapcraft list-tracks command (snapcraft 4.2 onwards), for instance:

snapcraft list-tracks node
Name    Status    Creation-Date         Version-Pattern
latest  active    -                     -
6       active    2018-02-27T13:25:05Z  -
8       active    2018-02-27T13:26:02Z  -
9       active    2018-02-27T13:26:08Z  -
10      active    2018-02-27T13:26:19Z  -
11      active    2018-10-31T16:25:48Z  -
12      default   2019-04-26T13:15:26Z  -
13      active    2019-10-18T13:34:01Z  -
14      active    2020-04-23T10:45:32Z  -

Now, as a publisher, if you want to change the default track of your application (snapcraft 4.3 onwards), you can also accomplish this on the command line – the specified default track must already exist, though.

snapcraft set-default-track “snap” “track”
snapcraft set-default-track kompozer legacy
Default track for 'kompozer' set to 'legacy'.

This can be quite useful if you’re managing multiple (supported) releases of your applications, or if you want to automate the functionality through a CI/CD system. Furthermore, publishers with a large number of snaps should also find this of value.


Snapcraft is constantly gaining new capabilities, designed to simplify and accelerate the process of snap publication. The elegance of the tool is that it provides both application development and Snap Store features, allowing you to accomplish a significant portion of your snap journey right there, in the terminal window. Default tracks are just the latest example. More good things are coming, so stay tuned. Meanwhile, if you have any requests or suggestions on what snapcraft ought to do, please join our forum for a discussion.

Photo by Borna Bevanda on Unsplash.

Newsletter Signup

Related posts

Compact and Bijou

Snaps are designed to be self-contained packages of binaries, libraries and other assets. A snap might end up being quite bulky if the primary application it contains has many additional dependencies. This is a by-product of the snap needing to run on any Linux distribution where dependencies cannot always be expected to be installed. Thi […]

Productivity corner: editors, editors, editors

Text editors are a curious product. On one hand, they are simple, no-nonsense digital pads for taking notes, without any embellishments or visual styling. On the other, they are powerful code and data toolboxes, allowing for a great deal of flexibility and innovation. Indeed, software developers, Web developers and entrepreneuring nerds w […]

Time to Branch Out

Branches are an under-used but important feature of the Snap Store publishing capabilities. Indeed as I’m writing this post, I’ve never had a need to use the feature, and I’ve been publishing snaps for four and a half years. Let’s fix that! Start with acorns The rationale for branches is simple. Each snap in the […]