diff --git a/checks/default.nix b/checks/default.nix index 3c158fcd..05d05b69 100644 --- a/checks/default.nix +++ b/checks/default.nix @@ -237,6 +237,13 @@ in src = ./various-targets; }; + depsOnlyCargoDoc = myLib.buildDepsOnly { + src = ./workspace; + version = "0.0.1"; + pname = "workspace"; + buildPhaseCargoCommand = "cargo doc --workspace"; + }; + devShell = myLib.devShell { checks = { simple = myLib.buildPackage { diff --git a/checks/mkDummySrcTests/custom-dummyrs/expected/src/bin/crane-dummy/main.rs b/checks/mkDummySrcTests/custom-dummyrs/expected/src/bin/crane-dummy-mkDummySrcSimple/main.rs similarity index 100% rename from checks/mkDummySrcTests/custom-dummyrs/expected/src/bin/crane-dummy/main.rs rename to checks/mkDummySrcTests/custom-dummyrs/expected/src/bin/crane-dummy-mkDummySrcSimple/main.rs diff --git a/checks/mkDummySrcTests/customized/expected/src/bin/crane-dummy/main.rs b/checks/mkDummySrcTests/customized/expected/src/bin/crane-dummy-mkDummySrcSimple/main.rs similarity index 100% rename from checks/mkDummySrcTests/customized/expected/src/bin/crane-dummy/main.rs rename to checks/mkDummySrcTests/customized/expected/src/bin/crane-dummy-mkDummySrcSimple/main.rs diff --git a/checks/mkDummySrcTests/single-alt/expected/src/bin/crane-dummy/main.rs b/checks/mkDummySrcTests/single-alt/expected/src/bin/crane-dummy-mkDummySrcSimple/main.rs similarity index 100% rename from checks/mkDummySrcTests/single-alt/expected/src/bin/crane-dummy/main.rs rename to checks/mkDummySrcTests/single-alt/expected/src/bin/crane-dummy-mkDummySrcSimple/main.rs diff --git a/checks/mkDummySrcTests/single/expected/src/bin/crane-dummy/main.rs b/checks/mkDummySrcTests/single/expected/src/bin/crane-dummy-mkDummySrcSimple/main.rs similarity index 100% rename from checks/mkDummySrcTests/single/expected/src/bin/crane-dummy/main.rs rename to checks/mkDummySrcTests/single/expected/src/bin/crane-dummy-mkDummySrcSimple/main.rs diff --git a/checks/mkDummySrcTests/workspace-bindeps/expected/foo/src/bin/crane-dummy/main.rs b/checks/mkDummySrcTests/workspace-bindeps/expected/foo/src/bin/crane-dummy-foo/main.rs similarity index 100% rename from checks/mkDummySrcTests/workspace-bindeps/expected/foo/src/bin/crane-dummy/main.rs rename to checks/mkDummySrcTests/workspace-bindeps/expected/foo/src/bin/crane-dummy-foo/main.rs diff --git a/checks/mkDummySrcTests/workspace-bindeps/expected/src/bin/crane-dummy/main.rs b/checks/mkDummySrcTests/workspace-bindeps/expected/src/bin/crane-dummy-workspace-bindeps/main.rs similarity index 100% rename from checks/mkDummySrcTests/workspace-bindeps/expected/src/bin/crane-dummy/main.rs rename to checks/mkDummySrcTests/workspace-bindeps/expected/src/bin/crane-dummy-workspace-bindeps/main.rs diff --git a/checks/mkDummySrcTests/workspace-inheritance/expected/hello/src/bin/crane-dummy/main.rs b/checks/mkDummySrcTests/workspace-inheritance/expected/hello/src/bin/crane-dummy-hello/main.rs similarity index 100% rename from checks/mkDummySrcTests/workspace-inheritance/expected/hello/src/bin/crane-dummy/main.rs rename to checks/mkDummySrcTests/workspace-inheritance/expected/hello/src/bin/crane-dummy-hello/main.rs diff --git a/checks/mkDummySrcTests/workspace-inheritance/expected/print/src/bin/crane-dummy/main.rs b/checks/mkDummySrcTests/workspace-inheritance/expected/print/src/bin/crane-dummy-print/main.rs similarity index 100% rename from checks/mkDummySrcTests/workspace-inheritance/expected/print/src/bin/crane-dummy/main.rs rename to checks/mkDummySrcTests/workspace-inheritance/expected/print/src/bin/crane-dummy-print/main.rs diff --git a/checks/mkDummySrcTests/workspace-inheritance/expected/world/src/bin/crane-dummy/main.rs b/checks/mkDummySrcTests/workspace-inheritance/expected/world/src/bin/crane-dummy-world/main.rs similarity index 100% rename from checks/mkDummySrcTests/workspace-inheritance/expected/world/src/bin/crane-dummy/main.rs rename to checks/mkDummySrcTests/workspace-inheritance/expected/world/src/bin/crane-dummy-world/main.rs diff --git a/checks/mkDummySrcTests/workspace/expected/member/foo/bar/baz/src/bin/crane-dummy/main.rs b/checks/mkDummySrcTests/workspace/expected/member/foo/bar/baz/src/bin/crane-dummy-bar/main.rs similarity index 100% rename from checks/mkDummySrcTests/workspace/expected/member/foo/bar/baz/src/bin/crane-dummy/main.rs rename to checks/mkDummySrcTests/workspace/expected/member/foo/bar/baz/src/bin/crane-dummy-bar/main.rs diff --git a/checks/mkDummySrcTests/workspace/expected/member/qux/src/bin/crane-dummy/main.rs b/checks/mkDummySrcTests/workspace/expected/member/qux/src/bin/crane-dummy-qux/main.rs similarity index 100% rename from checks/mkDummySrcTests/workspace/expected/member/qux/src/bin/crane-dummy/main.rs rename to checks/mkDummySrcTests/workspace/expected/member/qux/src/bin/crane-dummy-qux/main.rs diff --git a/lib/mkDummySrc.nix b/lib/mkDummySrc.nix index ccdccffe..39b32fbe 100644 --- a/lib/mkDummySrc.nix +++ b/lib/mkDummySrc.nix @@ -196,7 +196,7 @@ let '' + optionalString (trimmedCargoToml ? package) '' # To build regular and dev dependencies (cargo build + cargo test) ${cpDummy parentDir "src/lib.rs"} - ${cpDummy parentDir "src/bin/crane-dummy/main.rs"} + ${cpDummy parentDir "src/bin/crane-dummy-${trimmedCargoToml.package.name or "no-name"}/main.rs"} # Stub all other targets in case they have particular feature combinations ${safeStubLib}