I’ve been working on adding support for developing Snapcraft projects using the IDE gnome-builder, and have gotten to the point where I’ve got something that other people might be interested in testing.
I have put together a PPA with packages for Ubuntu 17.10 (artful) here:
https://launchpad.net/~jamesh/+archive/ubuntu/gnome-builder-snap-plugin
If there is interest, I can try building packages for older releases. I can’t promise anyting, since I don’t want to go down the dependency backport rabbit hole.
Here’s a list of what currently works:
-
You can open an existing Snapcraft project by selecting Open... and then picking your snapcraft.yaml file in the file chooser.
-
Clicking the “build” button (looks like a stack of bricks) will invoke snapcraft build, with the output displayed at the bottom of the window.
-
If you click on the project name at the top of the window, it will show an overlay with a Clean button, that will invoke snapcraft clean.
-
In the application menu at the top right of the window, selecting Snapcraft -> Export snap package will run the package build to completion. If it succeeds, a file manager window should open pointing at the new snap package.
Here are some things that don’t work, or haven’t been tested:
-
Snapcraft will error out if it tries to install new packages as part of the build. We aren’t invoking it in a terminal, so sudo doesn’t work.
-
I haven’t really tested how the plugin interacts if you are an upstream developer with a snapcraft.yaml checked into your tree, but want to build directly without Snapcraft.
This is fairly bare bones at the moment, so there are a few areas for further development:
- Add a template to allow creating a new Snapcraft project.
- Add support for testing a snap via
snap try.
- Make the “build” button execute more build steps?
If anyone is interested in the source to the plugin, it can be found here:
And here’s a screenshot for anyone curious about what this looks like: