This repository contains snap packaging for opencode-ai.
It builds opencode from source using the Bun runtime. At present only the baseline (no AVX2) binary is compiled and packaged. In the future we will package the AVX2 binary as snap architecture variant.
snapcraft packThe version is determined by selecting the Git tag of opencode. To update to a new upstream release just change that and commit.
Tests in this repository use spread, the multi-machine test runner from the snap core team. To run the tests locally you need a spread environment backed by a LXD image.
Install the image-garden snap, which provides the image management tooling
spread depends on:
sudo snap install image-gardenThe image-garden snap ships a image-garden.spread binary that acts as a
spread backend. Use it to run the tests:
image-garden.spreadThis will pull the necessary virtual machine base images, and execute the test
cases defined under tests/.
See publishing/README.md for details.