mirror of
https://github.com/justinwoo/nix-shorts.git
synced 2024-09-11 18:57:54 +03:00
Merge pull request #15 from waxlamp/fix-perms-error
Avoid perms error by using `cp` instead of `ln`
This commit is contained in:
commit
08be1564e7
@ -37,8 +37,10 @@ pkgs.stdenv.mkDerivation {
|
|||||||
# $src is defined as the location of our `src` attribute above
|
# $src is defined as the location of our `src` attribute above
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
# $out is an automatically generated filepath by nix,
|
# $out is an automatically generated filepath by nix,
|
||||||
# but it's up to you to make it what you need
|
# but it's up to you to make it what you need. We'll create a directory at
|
||||||
ln -s $src $out
|
# that filepath, then copy our sources into it.
|
||||||
|
mkdir $out
|
||||||
|
cp -rv $src/* $out
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
@ -90,9 +92,6 @@ $ nix-build
|
|||||||
$ readlink result
|
$ readlink result
|
||||||
/nix/store/kgjcq77210jkjppc8628vcl27i6f22k8-basic-derivation
|
/nix/store/kgjcq77210jkjppc8628vcl27i6f22k8-basic-derivation
|
||||||
|
|
||||||
$ readlink -f result
|
|
||||||
/nix/store/54992nknd3av7j4p7fmsh96ja5hp1vli-src
|
|
||||||
|
|
||||||
$ ls result
|
$ ls result
|
||||||
hi.txt
|
hi.txt
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user