zquestz / s

Open a web search in your terminal.
MIT License
2.34k stars 114 forks source link

Add snapcraft support for building snaps #136

Closed popey closed 5 years ago

popey commented 5 years ago

I recently discovered s and as a Google search God (according to my mum) and committed keyboard warrior in the terminal, I love it. Thanks for making it. <3

I created a snap package of s so it can be featured in the Snap Store, which is a cross-distribution app-store for Linux. The store has a minimum snap name length of 2, which made snapping ‘s’ a challenge ;). I named it ‘ws’ (web search) which seems appropriate, but that can be modified. That does mean internally the application calls itself ‘s’ (in command line help for example) but externally it’s called ‘ws’.

A single snap (built for many architectures) in the Snap Store will be installable on numerous popular Linux distributions with no changes. It’ll also be discoverable via the Snap Store, where releases are under your control.

If you're willing to publish this under the ws project name, you just need to create an account and then register the ws name.

A snap file created by snapcraft (our free software tool for building snaps) can then be released in the Snap Store with snap push --release stable *.snap. You'll want to install snapcraft (brew install snapcraft, snap install snapcraft, or apt install snapcraft) and login (snapcraft login) first, though.

You may also want to consider using https://build.snapcraft.io/ which is a free build service, that can create armhf, amd64, i386, arm64 and other builds of s, and push them to the store automatically. Alternatively it’s possible to integrate publishing the snap via your existing travis CI / release process.

I appreciate you may not be aware of snaps and snapcraft, and I’d of course be happy to answer any questions you may have.

zquestz commented 5 years ago

This is awesome. So to be consistent with places that don't allow 1 letter names, you should use s-search. This is how it was done for brew which had the same issue. Once updated then I will happily merge this PR. =)

zquestz commented 5 years ago

Snap has been made https://snapcraft.io/s-search