Skip to content

refactor: Allow talon to be overridden to allow beta use #16

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

fidgetingbits
Copy link

Talon has a beta version that uses non-public URLs, so can't be published directly in the flake. Otherwise, the beta versions do work fine in nix. This PR refactors the way the talon packages are built to allow the unwrapped version of talon to be overridden with a beta url, along the lines of this:

      (final: prev: {
        talon-unwrapped = prev.talon-unwrapped.overrideAttrs (oldAttrs: {
          version = "0.4.0-359-g5c35";
          src = builtins.fetchurl {
            url = inputs.nix-secrets.talon-beta-url;
            sha256 = "sha256:07ia3cnr1ayckcffr3zw6l9j3fz8ywxcxjw68ba647994s2n2zfa";
          };
        });

Most Talon nix users I've spoken to are on beta, so I wanted to make this available to everyone.

I also stopped hardcoding x86_64-linux everywhere because I plan to start testing this on aarch64 darwin as well, but will be a follow up.

Formatting is done using nixfmt-rfc-style so also a few changes

@fidgetingbits
Copy link
Author

The way I check for an existing version of talon-unwrapped in overlay.nix before calling callPackage is the only way I could get my overlay to apply from my consuming flake when I was using program.talon.enable = true. I'm not sure if that's the idiomatic way to do it though.

@fidgetingbits
Copy link
Author

@adisbladis any thoughts on this? I've been using it for quite awhile now and it's working been nicely. I know at least a couple other nix users were interesting using the talon beta as well.

@nixos-discourse
Copy link

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/prs-ready-for-review/3032/4834

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

Successfully merging this pull request may close these issues.

3 participants