mirror of
https://github.com/logos-messaging/logos-delivery.git
synced 2026-04-17 05:33:07 +00:00
18 lines
727 B
Nix
18 lines
727 B
Nix
# Fetches Nimble at the exact revision declared in waku.nimble.
|
|
# Regenerate sha256 with:
|
|
# nix shell nixpkgs#nix-prefetch-git --command \
|
|
# nix-prefetch-git --url https://github.com/nim-lang/nimble --rev v<version> --fetch-submodules
|
|
{ pkgs }:
|
|
let
|
|
lines = pkgs.lib.splitString "\n" (builtins.readFile ../waku.nimble);
|
|
versionLine = builtins.head (builtins.filter
|
|
(l: builtins.match "^const NimbleVersion.*" l != null) lines);
|
|
version = builtins.head (builtins.match ".*\"([0-9]+\\.[0-9]+\\.[0-9]+)\".*" versionLine);
|
|
in
|
|
pkgs.fetchgit {
|
|
url = "https://github.com/nim-lang/nimble";
|
|
rev = "v${version}";
|
|
sha256 = "18cwsjwcgjmnm42kr310hfbw06lym3vaj641i4pla6r8w22xqpqd";
|
|
fetchSubmodules = true;
|
|
}
|