Don't update flake.lock when building from a local nixpkgs
This commit is contained in:
parent
74573c6eb0
commit
f3b7697207
2 changed files with 12 additions and 21 deletions
19
flake.lock
generated
19
flake.lock
generated
|
@ -2,11 +2,11 @@
|
||||||
"nodes": {
|
"nodes": {
|
||||||
"flake-utils": {
|
"flake-utils": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1595332686,
|
"lastModified": 1595410516,
|
||||||
"narHash": "sha256-GpzwLOx6fvtsAnjPqG0ob5GXR0e4eWThwgWedo3qeNc=",
|
"narHash": "sha256-8lKGIGTyo1uVfdT0TXEJk9YAR/Tw08sRA/VLOm9ewco=",
|
||||||
"owner": "numtide",
|
"owner": "numtide",
|
||||||
"repo": "flake-utils",
|
"repo": "flake-utils",
|
||||||
"rev": "f99f5970824e210e84f9a766e2ea52d4af770182",
|
"rev": "8e1f14e82dcd87f484a5024a86e52399b1061416",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -39,13 +39,12 @@
|
||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1595402314,
|
"lastModified": 1595486616,
|
||||||
"narHash": "sha256-LEHScTpv+Swf+LoqeaY128N2AC7vhWv7SlDnIJoB6sk=",
|
"narHash": "sha256-36b6SSE1Ef+i7LE2JE6qaq087Bhbrr8VPmcxr+lS2e8=",
|
||||||
"ref": "master",
|
"owner": "charvp",
|
||||||
"rev": "5a687c0410ab6214d1467d535274b26c3f38b4b4",
|
"repo": "nixpkgs",
|
||||||
"revCount": 235540,
|
"rev": "871bc12bf4edd1a099d1fdef771f99a34af0cfad",
|
||||||
"type": "git",
|
"type": "github"
|
||||||
"url": "file:///data/home/charlotte/repos/nixpkgs"
|
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "charvp",
|
"owner": "charvp",
|
||||||
|
|
14
update.sh
14
update.sh
|
@ -4,19 +4,11 @@ set -x
|
||||||
|
|
||||||
nix flake update
|
nix flake update
|
||||||
|
|
||||||
BUILD_ARGS=(
|
BUILD_ARGS=()
|
||||||
"--builders"
|
|
||||||
"ssh://charlotte@sunspear.vanpetegem.me"
|
|
||||||
"--builders-use-substitutes"
|
|
||||||
"--extra-substituters"
|
|
||||||
"ssh://charlotte@sunspear.vanpetegem.me"
|
|
||||||
"--trusted-public-keys"
|
|
||||||
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY= sunspear-nix-cache:4mgL4qS7EweCug1gAFiZKgQK+xuoJMBYThIUE+kPX4s="
|
|
||||||
)
|
|
||||||
|
|
||||||
if [ -d "../nixpkgs" ]
|
if [ -d "../nixpkgs" -a -z "${NO_LOCAL:-}" ]
|
||||||
then
|
then
|
||||||
BUILD_ARGS+=("--override-input" "nixpkgs" "../nixpkgs")
|
BUILD_ARGS+=("--override-input" "nixpkgs" "../nixpkgs" "--no-write-lock-file")
|
||||||
fi
|
fi
|
||||||
|
|
||||||
sudo nix build --profile /nix/var/nix/profiles/system ".#nixosConfigurations.$(hostname).config.system.build.toplevel" --no-link "${BUILD_ARGS[@]}" && \
|
sudo nix build --profile /nix/var/nix/profiles/system ".#nixosConfigurations.$(hostname).config.system.build.toplevel" --no-link "${BUILD_ARGS[@]}" && \
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue