You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is a continuation of #291 - I finally ran into the issue I had, and it only shows up with some crates.
The crate2nix source add git https://… --rev $rev; crate2nix generate to package an external project mostly works. However, in some cases I can not just .gitignore crate2nix-sources.nix and the crate2nix-sources symlink, as Cargo.nix refers to sources from that symlink:
❯ crate2nix source add git https://github.com/n0-computer/iroh --rev 62ac4d8bb57329bc65cf126fabace882066ddb8a
Prefetching https://github.com/n0-computer/iroh#62ac4d8bb57329bc65cf126fabace882066ddb8a: done.
Added new source: https://github.com/n0-computer/iroh#62ac4d8bb57329bc65cf126fabace882066ddb8a via git: 0f2iyj6r3ymrgdy2vqv2dqixqaqprspyr042sqwibzha18phkxwk
❯ crate2nix generate
Fetching sources.
Generated ./crate2nix-sources.nix successfully.
Fetching sources via ./crate2nix-sources.nix fetchedSources: done.
warning: Could not find configured source for workspace member "/tmp/example/crate2nix-sources/iroh/iroh-base"
warning: Could not find configured source for workspace member "/tmp/example/crate2nix-sources/iroh/iroh-bytes"
warning: Could not find configured source for workspace member "/tmp/example/crate2nix-sources/iroh/iroh-gossip"
warning: Could not find configured source for workspace member "/tmp/example/crate2nix-sources/iroh/iroh-metrics"
warning: Could not find configured source for workspace member "/tmp/example/crate2nix-sources/iroh/iroh-net"
warning: Could not find configured source for workspace member "/tmp/example/crate2nix-sources/iroh/iroh-net/bench"
warning: Could not find configured source for workspace member "/tmp/example/crate2nix-sources/iroh/iroh-sync"
warning: Could not find configured source for workspace member "/tmp/example/crate2nix-sources/iroh/iroh-test"
Generated ./Cargo.nix successfully.
❯ ag crate2nix-sources Cargo.nix
6986: then lib.cleanSourceWith { filter = sourceFilter; src = ./crate2nix-sources/iroh/iroh-base; }
6987: else ./crate2nix-sources/iroh/iroh-base;
7119: then lib.cleanSourceWith { filter = sourceFilter; src = ./crate2nix-sources/iroh/iroh-bytes; }
7120: else ./crate2nix-sources/iroh/iroh-bytes;
7294: then lib.cleanSourceWith { filter = sourceFilter; src = ./crate2nix-sources/iroh/iroh-gossip; }
7295: else ./crate2nix-sources/iroh/iroh-gossip;
7498: then lib.cleanSourceWith { filter = sourceFilter; src = ./crate2nix-sources/iroh/iroh-metrics; }
7499: else ./crate2nix-sources/iroh/iroh-metrics;
7595: then lib.cleanSourceWith { filter = sourceFilter; src = ./crate2nix-sources/iroh/iroh-net; }
7596: else ./crate2nix-sources/iroh/iroh-net;
8010: then lib.cleanSourceWith { filter = sourceFilter; src = ./crate2nix-sources/iroh/iroh-net/bench; }
8011: else ./crate2nix-sources/iroh/iroh-net/bench;
8074: then lib.cleanSourceWith { filter = sourceFilter; src = ./crate2nix-sources/iroh/iroh-sync; }
8075: else ./crate2nix-sources/iroh/iroh-sync;
8270: then lib.cleanSourceWith { filter = sourceFilter; src = ./crate2nix-sources/iroh/iroh-test; }
8271: else ./crate2nix-sources/iroh/iroh-test;
flokli
changed the title
Cargo.nix sometimes includes references to ./crate2nix-sources
Cargo.nix includes references to ./crate2nix-sources with cargo workspaces
Dec 14, 2023
This is a continuation of #291 - I finally ran into the issue I had, and it only shows up with some crates.
The
crate2nix source add git https://… --rev $rev; crate2nix generate
to package an external project mostly works. However, in some cases I can not just .gitignorecrate2nix-sources.nix
and thecrate2nix-sources
symlink, asCargo.nix
refers to sources from that symlink:This is with crate2nix master, 252ca6b.
The text was updated successfully, but these errors were encountered: