-
Notifications
You must be signed in to change notification settings - Fork 1
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
Use nix to create distribution-independent binary releases (or AppImages) #22
Comments
It looks like building AppImages requires a |
I think I can build AppImages now. I am going to test everything to see if it works (AppImages don't work on NixOS by default, I'll have to install some additional scripts to test them) |
I get some strange errors. Still, here's an AppImage for termNote (the executable itself; I can also build an AppImage for noted, but it has strange errors as well). |
Well, I don't know how to fix errors with AppImages, but I've got bundles to be smaller and run faster. Maybe they're good enough for the first couple of releases? |
We can automatically add releases from travis: https://docs.travis-ci.com/user/deployment/releases/ language: nix
script:
- nix-build
- nix-build -A bundles.termNote -o termNote
- nix-build -A bundles.noted -o noted
deploy:
# Other setup here
file:
- noted
- termNote (Although I am not sure script can be a list) |
Verified that bundles work on Tiny Core Linux 64 bit. That probably means that they work practically everywhere. |
Will test on Arch, altho i couldn't get nix itself to work. |
What did you do and what was the problem? Last time I tried to run nix on arch it worked fine (I think that was summer of 2018). |
Anyways, it seems automatic travis deploys are working! https://github.com/balsoft/termNote/releases/tag/v1.2.4 |
How do these work? does it create an automatic release when you push a new tag? also, i don't quite get what you mean with running |
With configuration that I used, it makes a release for every build, but it puts them in drafts so that you can manually un-draft them. You can also make releases when tags are pushed by adding deploy:
on:
tags: true to .travis.yml
|
Will look into it tomorrow. |
Do bundles work for you on arch? They give some strange errors in Virtualbox liveISO.
I don't know if that comes from glibc version mismatch, or some other cause. |
Hmm, it seems to be kind of deliberate - it runs termNote in sandbox essentially, thus limiting it's abilities to read/write. Investigating right now. |
matthewbauer/nix-bundle#33 seems to be the issue here. |
Ah. It looks like it fails because |
matthewbauer/nix-bundle#43 is the solution. |
There is a wonderful project, nix-bundle, which allows to create distribution-independent executables with arx from nix expressions. I have created some sample executables (google drive, 35MB, zip) from
master
, which I encourage you to try and run on your distro. In theory, all it takes to run is to mark them as executable. Unfortunately, they're quite slow and big as they need to carry all the dependencies with them.nix-bundle
also provides some support functions to create AppImages, which would be much faster, but they need additional work to be built.The text was updated successfully, but these errors were encountered: