mirror of
https://github.com/status-im/status-react.git
synced 2025-01-11 03:26:31 +00:00
nix: use builtins to not depend on channels
We use `builtins.fetchTarball` to avoid having to first import a `nixpkgs` from existing channels, which breaks if there are no channels. Otherwise new Nix 2.14 version can result in: ``` error: file 'nixpkgs' was not found in the Nix search path (add it using $NIX_PATH or -I) ``` Which happens due to no default `nixpkgs` channel existing: ``` > nix-channel --list ``` Resolves: https://github.com/status-im/status-mobile/issues/16342 Signed-off-by: Jakub Sokołowski <jakub@status.im>
This commit is contained in:
parent
60545a6608
commit
c4b13eb043
13
nix/pkgs.nix
13
nix/pkgs.nix
@ -3,20 +3,13 @@
|
|||||||
{ config ? { } }:
|
{ config ? { } }:
|
||||||
|
|
||||||
let
|
let
|
||||||
inherit (import <nixpkgs> { }) fetchFromGitHub;
|
|
||||||
|
|
||||||
# For testing local version of nixpkgs
|
# For testing local version of nixpkgs
|
||||||
#nixpkgsSrc = (import <nixpkgs> { }).lib.cleanSource "/home/jakubgs/work/nixpkgs";
|
#nixpkgsSrc = (import <nixpkgs> { }).lib.cleanSource "/home/jakubgs/work/nixpkgs";
|
||||||
|
|
||||||
# We follow the master branch of official nixpkgs.
|
# We follow the master branch of official nixpkgs.
|
||||||
nixpkgsSrc = fetchFromGitHub {
|
nixpkgsSrc = builtins.fetchTarball {
|
||||||
name = "nixpkgs-source";
|
url = "https://github.com/NixOS/nixpkgs/archive/e7603eba51f2c7820c0a182c6bbb351181caa8e7.tar.gz";
|
||||||
owner = "NixOS";
|
sha256 = "sha256:0mwck8jyr74wh1b7g6nac1mxy6a0rkppz8n12andsffybsipz5jw";
|
||||||
repo = "nixpkgs";
|
|
||||||
rev = "e7603eba51f2c7820c0a182c6bbb351181caa8e7";
|
|
||||||
sha256 = "sha256-XJZ/o17eOd2sEsGif+/MQBnfa2DKmndWgJyc7CWajFc=";
|
|
||||||
# To get the compressed Nix sha256, use:
|
|
||||||
# nix-prefetch-url --unpack https://github.com/${ORG}/nixpkgs/archive/${REV}.tar.gz
|
|
||||||
};
|
};
|
||||||
|
|
||||||
# Status specific configuration defaults
|
# Status specific configuration defaults
|
||||||
|
Loading…
x
Reference in New Issue
Block a user