mirror of
https://github.com/NixOS/nix
synced 2025-07-07 18:31:49 +02:00
tests/function/flakes/relative-paths: Test #13164
(cherry picked from commit eaee0b4740
)
This commit is contained in:
parent
31e19b0a28
commit
82dcbe0510
1 changed files with 43 additions and 0 deletions
|
@ -131,3 +131,46 @@ EOF
|
|||
# would fail:
|
||||
nix eval .#ok
|
||||
)
|
||||
|
||||
# https://github.com/NixOS/nix/issues/13164
|
||||
mkdir -p "$TEST_ROOT/issue-13164/nested-flake1/nested-flake2"
|
||||
(
|
||||
cd "$TEST_ROOT/issue-13164"
|
||||
git init
|
||||
git config --global user.email "you@example.com"
|
||||
git config --global user.name "Your Name"
|
||||
cat >flake.nix <<EOF
|
||||
{
|
||||
inputs.nestedFlake1.url = "path:./nested-flake1";
|
||||
outputs = { self, nestedFlake1 }: {
|
||||
inherit nestedFlake1;
|
||||
};
|
||||
}
|
||||
EOF
|
||||
|
||||
cat >nested-flake1/flake.nix <<EOF
|
||||
{
|
||||
inputs.nestedFlake2.url = "path:./nested-flake2";
|
||||
|
||||
outputs = { self, nestedFlake2 }: {
|
||||
name = "nestedFlake1";
|
||||
inherit nestedFlake2;
|
||||
};
|
||||
}
|
||||
EOF
|
||||
|
||||
cat >nested-flake1/nested-flake2/flake.nix <<EOF
|
||||
{
|
||||
outputs = { self }: {
|
||||
name = "nestedFlake2";
|
||||
};
|
||||
}
|
||||
EOF
|
||||
|
||||
git add .
|
||||
git commit -m "Initial commit"
|
||||
|
||||
# I don't understand why two calls are necessary to reproduce the issue.
|
||||
nix eval --json .#nestedFlake1.nestedFlake2 --no-eval-cache
|
||||
nix eval --json .#nestedFlake1.nestedFlake2 --no-eval-cache
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue