Nix Rust | 686 Members | |
| Rust | 155 Servers |
| Sender | Message | Time |
|---|---|---|
| 23 Nov 2021 | ||
| if somebody does have such a setup, I would obviously like them to share it :P | 02:03:37 | |
| it is related to nix because the question is trivial unless you are trying to stay within nix | 02:04:03 | |
| i've got it going with nvim and whatever rust-analzyer is in nixpkgs for a couple of months now | 02:04:30 | |
| isn't it just about pointing emcas to the right LSP? | 02:04:45 | |
| the emacs LSP impl doesn't like the rust-analyzer in stable nixpkgs | 02:05:09 | |
| oh, I always use unstable | 02:05:29 | |
| I am very attached to my editing environment's stability | 02:05:41 | |
| me too but thats what we have rollbacks for | 02:06:04 | |
| I've yet to encounter really deal breaking brekage | 02:06:14 | |
| * I've yet to encounter really deal breaking breakage | 02:06:17 | |
| I'm not using the plugins nor the neovim that is in nixpkgs. I've my own neovim package and pin all my plugins using my niv equivalent. | 02:07:00 | |
| but rust-analzyer comes from nixpkgs | 02:07:12 | |
| good to know that's getting some love at least | 02:07:31 | |
| andi-: pulling RA from unstable seems to have Just Worked with no other changes, thanks! | 03:52:19 | |
| 03:58:45 | ||
| 08:30:16 | ||
| Ralith: I usually use the one from here along with rust: https://github.com/nix-community/fenix | 18:05:56 | |
| ooh, interesting | 18:40:04 | |
| but isn't that just providing patchelf'ed binaries? | 18:49:34 | |
In reply to @mic92:nixos.dev configuring this as an overlay then referencing rust-analyzer-nightly fails with
| 18:49:48 | |
| not a great start | 18:49:52 | |
| 20:29:45 | ||
| Hey folks, I was trying to use carnix to generate a nix definition for a workspace of a few crates I've got, but ran into an unwrap error, and on looking for the carnix repo, found that the links which I can find (on https://crates.io/crates/carnix and https://github.com/nix-community/carnix) both point to https://nest.pijul.com/pmeunier/carnix which shows as "not found" (rather than showing a repo). Is there a new location for the carnix repo? Or should I not be using carnix and instead do something else to have nix build my crates? | 20:32:38 | |
In reply to @codysch:matrix.org I've been pretty happy with naersk and crate2nix though neither are perfect solutions. https://github.com/nix-community/naersk | 20:35:25 | |
In reply to @codysch:matrix.orgFWIW, pmeunier appears to be using crate2nix himself: https://nest.pijul.com/pijul/pijul:main/G734WNM64AR5A.BQAAA | 21:11:46 | |
| I had a good experience with crate2nix recently as well | 22:06:22 | |
In reply to @skamdart:matrix.orgthanks, I'll check those out. | 22:19:48 | |
| I was probably just mislead by https://github.com/NixOS/nixpkgs/blob/master/doc/languages-frameworks/rust.section.md into trying to use carnix, should have looked at the wiki I guess (probably should pr an update to those docs) | 22:52:19 | |
| 24 Nov 2021 | ||
Ok, so I'm trying to use crate2nix, and it looks like it's mostly working. I have noticed that I need to add SystemConfiguration as an extra buildInput for crates that actually link outputs though (this is on macos). Is this expected? Or should defaultCrateOverrides normally handle this? I've done this (which calls the Cargo.nix generated by crate2nix) to handle: https://gist.github.com/jmesmon/bd3d489cdb45ee7daaf025d82a3fe0b9 | 14:56:08 | |
Secondary question: https://github.com/serokell/templates/blob/master/rust-crate2nix/flake.nix appears to be an example of how to have my flake.nix generate the required Cargo.nix internally (so I don't need to actually commit it to the repo). But I'm seeing an error when using that template: error: store path '/nix/store/90ijf9rkd4s4bbm8l0kw9lwqcx4bmbay-remule-crate2nix' is not allowed to have references. This lead me to https://github.com/NixOS/nix/issues/5410 and https://github.com/NixOS/nix/pull/5494 and https://github.com/kolloch/crate2nix/pull/215. If I'm understanding correctly, it looks like nix intended to fix this upstream (assuming this is actually the same error), but I'm pretty sure I'm using a new enough nix (2.4) and still seeing the above error. Any insight/advice on what might let me make this flake.nix work? | 15:04:25 | |