mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-22 05:56:15 +02:00
Add gitSubmodules test to github actions
This commit is contained in:
parent
cd06193d13
commit
1e4f902b28
2 changed files with 19 additions and 3 deletions
2
.github/workflows/ci.yml
vendored
2
.github/workflows/ci.yml
vendored
|
@ -166,4 +166,4 @@ jobs:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
- uses: DeterminateSystems/nix-installer-action@main
|
- uses: DeterminateSystems/nix-installer-action@main
|
||||||
- uses: DeterminateSystems/magic-nix-cache-action@main
|
- uses: DeterminateSystems/magic-nix-cache-action@main
|
||||||
- run: nix build -L .#hydraJobs.tests.githubFlakes .#hydraJobs.tests.tarballFlakes
|
- run: nix build -L .#hydraJobs.tests.githubFlakes .#hydraJobs.tests.tarballFlakes .#hydraJobs.tests.gitSubmodules
|
||||||
|
|
|
@ -46,8 +46,24 @@
|
||||||
remote.wait_for_unit("sshd")
|
remote.wait_for_unit("sshd")
|
||||||
client.succeed(f"ssh -o StrictHostKeyChecking=no {remote.name} 'echo hello world'")
|
client.succeed(f"ssh -o StrictHostKeyChecking=no {remote.name} 'echo hello world'")
|
||||||
|
|
||||||
remote.succeed("git init bar && git -C bar config user.email foobar@example.com && git -C bar config user.name Foobar && echo test >> bar/content && git -C bar add content && git -C bar commit -m 'Initial commit'")
|
remote.succeed("""
|
||||||
client.succeed(f"git init foo && git -C foo config user.email foobar@example.com && git -C foo config user.name Foobar && git -C foo submodule add root@{remote.name}:/tmp/bar sub && git -C foo add sub && git -C foo commit -m 'Add submodule'")
|
git init bar
|
||||||
|
git -C bar config user.email foobar@example.com
|
||||||
|
git -C bar config user.name Foobar
|
||||||
|
echo test >> bar/content
|
||||||
|
git -C bar add content
|
||||||
|
git -C bar commit -m 'Initial commit'
|
||||||
|
""")
|
||||||
|
|
||||||
|
client.succeed(f"""
|
||||||
|
git init foo
|
||||||
|
git -C foo config user.email foobar@example.com
|
||||||
|
git -C foo config user.name Foobar
|
||||||
|
git -C foo submodule add root@{remote.name}:/tmp/bar sub
|
||||||
|
git -C foo add sub
|
||||||
|
git -C foo commit -m 'Add submodule'
|
||||||
|
""")
|
||||||
|
|
||||||
client.succeed("nix --flake-registry \"\" flake prefetch 'git+file:///tmp/foo?submodules=1&ref=master'")
|
client.succeed("nix --flake-registry \"\" flake prefetch 'git+file:///tmp/foo?submodules=1&ref=master'")
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue