Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Snap package for sciencefair. #175

Open
SirRujak opened this issue Nov 1, 2018 · 4 comments
Open

Snap package for sciencefair. #175

SirRujak opened this issue Nov 1, 2018 · 4 comments

Comments

@SirRujak
Copy link
Contributor

SirRujak commented Nov 1, 2018

I was trying to give this a try on Solus today and found that there wasn't a terribly easy way to install it. I took a bit of time to familiarize myself with node since I haven't really used it before but from what I can tell it should be pretty simple to build a snap using electron-builder.

After a bit of work getting the current code to build I was then able to get it to produce a functional snap.

Here is the git diff for what I did:

diff --git a/app/package.json b/app/package.json
index be4b496..09b3feb 100644
--- a/app/package.json
+++ b/app/package.json
@@ -39,7 +39,7 @@
     "electron-debug": "^1.2.0",
     "electron-default-menu": "^1.0.1",
     "electron-log": "^2.0.0",
-    "electron-updater": "^2.4.2",
+    "electron-updater": "^3.1.2",
     "end-of-stream": "^1.1.0",
     "findandreplacedomtext": "^0.4.4",
     "folder-walker": "^3.1.0",
diff --git a/electron-builder.yml b/electron-builder.yml
index 3deab1f..3ffac36 100644
--- a/electron-builder.yml
+++ b/electron-builder.yml
@@ -34,6 +34,7 @@ linux:
   target:
     - deb
     - rpm
+    - snap
   maintainer: "Richard Smith-Unna <rik@fathomlabs.io>"
 win:
   icon: "build/icon.ico"

The first is just to get sciencefair to build at all and the second makes it spit out a snap. Would there be any interest in either the project having them automatically built and added to the snapcraft store or would it just be a better idea to add it myself at the moment as a community build?

Thank you for taking a look!

@bencevans
Copy link
Contributor

An official snap would be great. Either a deb where it's pushed to an apt repo or snap anyway. I'd suggest maybe creating a community build anyway under a differing name from what the official may be... snap install sirrujak-sciencefair?

@SirRujak
Copy link
Contributor Author

SirRujak commented Nov 5, 2018

Ok, I went ahead and made sirrujak-sciencefair available as a beta in the snap store. I had to use your pull request @bencevans due to an issue with snapcraft building electron applications prior to electron- 1.8.3 and rename the project so I could upload it to the snapcraft store. Otherwise I only made the change that has electron builder output a snap.

If you would like to test it using snap install sirrujak-sciencefair --beta just to make sure it is properly working on someone else's machine as well I would greatly appreciate it! If it does end up working I'll go ahead and push it to the stable branch pending any complaints of instability.

@bencevans
Copy link
Contributor

Breeze to install! Works great 🎉

@SirRujak
Copy link
Contributor Author

SirRujak commented Nov 5, 2018

Awesome! I'll go ahead and push it into stable then. This means it should be showing up in the Ubuntu software store now and any other distro that has snaps in their gui app finder as well.

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

No branches or pull requests

2 participants