dinedal / textql

Execute SQL against structured text like CSV or TSV
MIT License
9.05k stars 300 forks source link

Add support for building snaps #110

Closed ghost closed 3 years ago

ghost commented 5 years ago

Hi Paul,

Can I ask you to add support for snaps for textql?

I think this would be a nice addition to the Snap Store (snapcraft.io/store), and give you extra exposure to Linux users. Snaps are cross-distro Linux software packages, supported on Ubuntu, Debian, Manjaro, Fedora, OpenSUSE and many others distributions. They also come with automatic updates.

I wrote this PR detailing how to build snaps locally using snapcraft, a command-line tool.

You can also build snaps using a CI system or our free build system (build.snapcraft.io).

Here are the steps to build textql as snap on a stock Ubuntu 18.04:

snap install snapcraft --classic --beta git clone https://github.com/igorljubuncic/textql.git cd textql git checkout add-snapcraft snapcraft

This sequence of commands will create a .snap file, something like textql_1.0_amd64.snap.

This snap can then be installed and tested local with:

snap install textql_1.0_amd64.snap --dangerous

The --dangerous flag is necessary because the app does not come from the store and isn't signed.

After it's installed, you can run the application:

snap run textql

Next, you will need to:

snapcraft login snapcraft register

snapcraft push textql_1.0_amd64.snap --release edge

The store supports multiple risk levels as “channels” with the 'edge' channel typically used to host the latest build from git master. Stable is where stable releases are pushed. Optionally, beta and candidate channels can also be used if needed. After testing, you can push a stable release to the stable channel.

snap install textql --edge

Once your app is in the store, we can help with the store page, and promote the application online.

Thanks, and let me know if you have any questions on this.

dinedal commented 3 years ago

Thanks for your contribution to textql!