arduino-cli
arduino-cli copied to clipboard
snap
Includes a snapcraft.yaml to build snap. I still need to make some changes to the snap configuration but here's what i have so far.
Prep
sudo snap install snapcraft --classic sudo snap install multipass --beta --classic
cla signed.
Hi @mikeroyal,
providing the CLI package via Snap is something on the roadmap so this PR is gold, thanks!
There's one thing I'd like to discuss before merging: we were planning to use goreleaser to be able to support multiple distribution channels with one single tool to ease maintenance. Since I'm no snap expert, It'd be great if you could have a look at the Snap specific section of their docs to see if your work can be integrated with it.
Hi @masci, goreleaser is indeed supported for snap. https://goreleaser.com/snapcraft/
@mikeroyal do you think you can take a stab at using gorelaser to make the snap? Otherwise I can start playing with it and we can add snap later.
@masci, I'll work on it over the weekend.
@mikeroyal we merged a working goreleaser config file on master, if you rebase you can add a Snap section to it
Hi @masci, will do and thank you for creating the goreleaser config file with all the requirements it makes adding the snap section a lot easier.
Hi @masci, I tried rebasing and GitHub was giving me an error. I'll again tomorrow but in the mean time here's the snapcraft section for the goreleaser.yml file if you want to take a look at it.
snapcraft:
name_template: '{{ .ProjectName }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}'
summary: CLI for Arduino.
description: |
arduino-cli is an all-in-one solution that provides builder, boards/library manager, uploader, discovery and many other tools needed to use any Arduino compatible board and platforms.
confinement: devmode
base: core18
apps:
audrino-cli:
plugs: ["home", "network", "removable-media"]
publish: true
Hi @mikeroyal , Do you have any update on this?
Please note that we had to change our approach on using goreleaser in the last months (i.e. to support notarization in our CI) so, we do not use goreleaser packaging features anymore.
Hi @rsora, I saw that update so it looks like you are using GitHub Actions? If so that actually works well for snaps. Snaps can now easily integrate with GitHub Actions to automate the whole process.
Hi @mikeroyal, @manchoz already managed to distribute the Arduino CLI as a snap: https://github.com/manchoz/arduino-cli-snap If you are ok with it I think we can close this one.
Hi @mikeroyal as already said, you can collaborate with @manchoz to maintain the arduino-cli snap package.