Skip to content
This repository has been archived by the owner on Sep 13, 2023. It is now read-only.

Add the packaging metadata to build the waltz snap #11

Closed
wants to merge 2 commits into from

Conversation

come-maiz
Copy link

This package will let you publish the latest warp in the Ubuntu store, and from there reach many users on all the supported Ubuntu versions, and more Linux distributions in progress.

@come-maiz
Copy link
Author

Hello @killercup!

Here at ubuntu we are working on a new packaging system. You can read more about it in https://snapcraft.io

We have a rust plugin that simplifies pushing rust tools to the store, and we are eager to get feedback from real rust projects to improve it. I found your project because I need to test our tutorials written in .md, and thought it would be a great addition to the store, and a great opportunity to talk to you.

Once the .yaml file is in your repo, you can just go to https://build.snapcraft.io to enable the automatic build and delivery.

If you want to give this PR a try in Ubuntu 16.04:

$ sudo apt install git snapcraft
$ git clone https://github.com/elopio/waltz
$ cd waltz
$ git checkout snapcraft
$ snapcraft
$ sudo snap install *.snap --dangerous

(--dangerous because the snap you build doesn't come signed from the store. Once you publish it, your users will just have to do sudo snap install waltz).

If you have any questions, please let me know.

pura vida.

@killercup
Copy link
Owner

Hi! Thanks for reaching out. How are you liking waltz? Is there anything I should add? You might be production user number 2 :)

I have to say I'm a bit wary of adding this file, as it suggests that I officially support this method of packaging waltz. Which I don't—as I have never even used snap, I've barely heard of the name before (I use macOS and Fedora on my main machine). I guess snap is similar to flatpak? Thinking about it, in the particular case of waltz, the package format probably does not matter at all; built with musl, you get a single ELF waltz binary that should work on basically every Linux out there. So it's only a question of how to store some metadata (and maybe a man file if I had one).

The config file itself seems rather trivial, though I have no idea what plugs and build-packages are. Nevertheless, it still duplicates at least name, summary, and description from Cargo.toml. Is there maybe a way to automatically generate it? I could imagine a tool similar to cargo deb that retrieves the necessary information from the already existing Cargo.toml file (or, better yet, using cargo metadata --no-deps --format-version=1 as this automatically works with Cargo's workspaces).

@come-maiz
Copy link
Author

After my first initial tests, I am liking it. I will tell you more in a couple of weeks, when I get to implement the actual tests.

snaps are like flatpacks, yes. Of course, I prefer snaps, so I might not be the right person to ask if you want an objective opinion :)

And something like cargo snap might be an interesting project. It would be simple, in most cases.
But currently, you would have to fill the template, we don't have anything like that for rust.
We are adding something similar for go (goreleaser/goreleaser#317), so thanks a lot for mentioning it. That's precisely the type of comments I was looking for.

I would suggest you to give the snap a try. After you click a couple of buttons in build.snapcraft.io, you will get the snap in the edge channel. In there, it won't be visible for user searches, so you can then drop it without problems if you don't like it. You will be able to install it in fedora, too: https://snapcraft.io/docs/core/install-fedora

@killercup
Copy link
Owner

killercup commented Aug 2, 2017

Ah, interesting. Thanks for the explanation. TIL.

I'm not gonna use it right now, though, and I don't want to give a service I don't use access to my private Github account. Similarly, I don't want to add metadata to my repo for things I don't use (and don't want to maintain.)

If there are any more people who want to have this (and it's not possible to generate this without the metadata file), I might reconsider.

@killercup killercup closed this Aug 2, 2017
@come-maiz come-maiz deleted the snapcraft branch August 4, 2017 00:37
@come-maiz
Copy link
Author

I understand. Thanks for reviewing it, and for your comments.
If you change your mind in the future, please ping me.

pura vida.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants