mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-27 08:04:14 +00:00
runInLinuxVM: refactor vmRunCommand
This makes it simpler to copy more files to xchg for the structuredAttrs case in the next commit.
This commit is contained in:
parent
437e6dbbb0
commit
58570e75d9
@ -230,16 +230,15 @@ rec {
|
||||
|
||||
|
||||
vmRunCommand = qemuCommand: writeText "vm-run" ''
|
||||
export > saved-env
|
||||
${coreutils}/bin/mkdir xchg
|
||||
export > xchg/saved-env
|
||||
PATH=${coreutils}/bin
|
||||
|
||||
if [ -f "''${NIX_ATTRS_SH_FILE-}" ]; then
|
||||
source "$NIX_ATTRS_SH_FILE"
|
||||
fi
|
||||
source $stdenv/setup
|
||||
|
||||
PATH=${coreutils}/bin
|
||||
mkdir xchg
|
||||
mv saved-env xchg/
|
||||
|
||||
eval "$preVM"
|
||||
|
||||
if [ "$enableParallelBuilding" = 1 ]; then
|
||||
|
Loading…
Reference in New Issue
Block a user