-
Notifications
You must be signed in to change notification settings - Fork 228
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
Package bumblebee-status for nixos #821
Comments
Yes, that would be great! Unfortunately, I have never used NixOS, so I have no idea how to package for it. |
https://www.youtube.com/watch?v=jXd-hkP4xnU This is something I've tried to grok, but it's a bit much for me at this time. Maybe it'd help you? |
Nice video 👍 I've also started reading https://nixos.wiki/wiki/Packaging/Tutorial and https://nixos.org/manual/nixpkgs/stable/#chap-quick-start, but frankly, it seems this goes way beyond the time I am - unfortunately - able to dedicate to this right now. I have tagged the issue with "help wanted", so maybe somebody with more NixOS knowledge can jump in. Thanks a lot for raising the issue! |
@tobi-wan-kenobi I have managed to learn enough to stumble through the packaging process, but in the process I had to patch the themes path, is there a reason why you're not using the $XDG_DATA_DIRS convention for the themes? |
The only reason I can bring forth is missing knowledge on my part. Does make a lot of sense to use that convention. I will add that, thanks for raising it! (might take a while though, due to Covid messing up my schedule quite a bit roght now) |
Ironically it was COVID (recovery) that gave me the free time to finally dig into this. Stay safe! |
Recover soon and well ! |
read theme information from $XDG_DATA_DIRS/bumblebee-status/themes see #821
@Deep-Six Does this change work for you? I tested it locally and it seems to do what is intended, but I am not 100% sure the subdirectories (bumblebee-status/themes/ are what you need. |
@tobi-wan-kenobi I can work with it, I need to also patch up the modules path, is there an equivalent to PATHS for modules? |
Yes, there is, but of course, I forgot about it. :) How did you patch the themes, i.e. what would be your preferred solution? |
let me post my code, nix is a bit interesting in that everything ends up as a hashed directory under the /nix/store path a bunch of things go into deriving the hash, (me blanketing over the stuff I don't know) but the calculation is part of the derivation process available as the variable $out. In this case I patch your source (bumblebee_status/core/theme.py with an @out@ template , and then substitute it thereafter, with the result of $out. See https://pastebin.com/TDCnM6yL and https://pastebin.com/hfJwHPzP respectively. |
Ah, I see, so the XDG_DATA_DIRS diesn't actually help, or am I missing something? (still nice, though) Also: bumblebee searches also paths relative to the executable, maybe that would be an ok solution as well? (ie if you can keep the same relative paths as the repo, theme and module lookup should work) Thanks a lot for your work! |
It does, as I think there's native support for XDG_DATA_DIRS so I think it does help, it does seem to preserve relative paths, (see belowe) on my system the build process hashed to this zpsc... directory. Which I think will be true for anyone using an x86-64 arch and running 2.1.5 though, I think I will have to modify my derivation as I suspect I'll need to include all the module dependencies, which will change the hash value. |
@tobi-wan-kenobi looking a little deeper at the code, would it make more sense to patch discovery.py? Adding in the /nix/store path to utility()? I'm not intimately familiar with the code yet though, so if it makes sense to patch core/module.py I presume it'd need to be load() that get's patched. Thanks! |
Hmm, possibly, although I think just adding more paths in the lookup like in the last diff should be sufficient... |
@tobi-wan-kenobi hrmm... can you expand on where I'd need to add the paths? Again, not super familiar with your code yet. |
For modules, I am not sure myself and need to look that up in the code, will probably take a couple of days, since I am still recuperating :) |
@tobi-wan-kenobi how you healing up? I hope you're ok! |
@Deep-Six yes, fully functional again, thanks for asking! And apologies, I completely forgot about this one. You are completely right, adding the Again, sorry for taking so long to simply respond "yup, looks good"! |
@tobi-wan-kenobi not a problem, I had the dreaded C, myself glad to hear you're on the mend. |
@Deep-Six Hope you are also doing well again! Would you be able to walk me through how you are setting up bumblebee-status in nix? If I can reproc it, I might be able to actually fix those issues myself. |
any news in regards to this? asking because i like this package and would love to continue using it on NixOS |
I had it completed, but ultimately lost the work in a hd crash..and haven't had time to re-visit it.
It was pretty straightforward, let me know if you want to collaborate on it!
…________________________________
From: Soul ***@***.***>
Sent: September 7, 2023 2:54 PM
To: tobi-wan-kenobi/bumblebee-status ***@***.***>
Cc: Jayson Henkel ***@***.***>; Mention ***@***.***>
Subject: Re: [tobi-wan-kenobi/bumblebee-status] Package bumblebee-status for nixos (#821)
CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you can confirm the sender and know the content is safe.
any news in regards to this? asking because i like this package and would love to continue using it on NixOS
—
Reply to this email directly, view it on GitHub<#821 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AFR63V5KWGT2UYN72YNLUO3XZI7AVANCNFSM5E6ICSKQ>.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
Hi, I decided to have a go at this myself: NixOS/nixpkgs#254772. Next up is a NixOS/Home-manager module! |
@augustebaum very cool, thanks! i will close this ticket as soon as that PR is merged. |
@tobi-wan-kenobi Do you mind closing the ticket after the PR changes are in nixos-unstable? Due to the way nixpkgs is set up, it takes some time for the changes to propagate into nixos-unstable. Here's the tracker nixos PR Tracker |
sounds good, will do! thanks for the heads up |
This is done in NixOS/nixpkgs#254772! |
Thank you!!! Very cool news! |
Feature Request
It'd be great to have bumblebee-status within the NixOS ecosystem, I'm relatively new to NixOS so am unfortunately familiar enough to support this.
The text was updated successfully, but these errors were encountered: