Proper way to automate snapcraft command

I am trying to build using Travis CI to track breaking changes, but if something really terrible is done, snapcraft spits a message that an error happened and asks about sending an anonymous report on the error, giving the option yes/no/always.

The problem is since this happens in travis ci, the result is the build is never finished. What is the proper way to run snapcraft so that no questions are never asked, it either should return error or not.

Injecting a ~/.config/snapcraft/cli.cfg file should help

[Sentry]
always_send = true

Is there any documentation on this cli.cfg file anywhere?

1 Like

You mean I can just add the line below in my building script and this will just press yes for whatever questions and my builds won’t hang? Cool :smiley:

printf "[Sentry]\nalways_send = true" >> ~/.config/snapcraft/cli.cfg

Probably only the crash prompt.