Monorepo snaps

Hi there,

I recently added a snapcraft.yml for the new entropic package manager, specifically the client (situated in the cli/ subdirectory of the repo), and was guiding a project maintainer through added this to build.snapcraft.io, only to hit the wall that the snapcraft yaml isn’t in the top directory (or a snap/ subdirectory), as this is purely a snap for the CLI client (entropic-ds).

I am loathe to move this to the top directory, as it would imply the snap also includes the microservices for the package registry side of the project (which is should not), and besides it is likely this would be a snap added later (e.g. entropic-server).

I have also considered creating a separate repo for the snapcraft config which pulls in the entropic repo, but then this separates it from the code base and also means it won’t be triggered on commits to master of entropic-dev/entropic.

Any ideas?

Build with Travis and Docker.

See

Or push (e.g. via Travis) an update into your packaging repo on commit. That is probably quite easy too.

Thanks for the suggestion - I was avoiding doing this from travis runs on master as I wanted to take advantage of launchpad multi-arch builds.

It is indeed a rather tedious solution for multiple architectures.
If you want to do it quick & not so dirty, maybe something like this is a good start:

You can have a snapcraft.yaml on a different branch or repo entirely when using https://build.snapcraft.io as it does track the source entries in each part. In your case I suspect a combination of source and source-subdir would do.