From ef2a9798cc4751ca069ee0e7f764812b8ed50da9 Mon Sep 17 00:00:00 2001 From: Profpatsch Date: Mon, 29 Jun 2020 00:59:17 +0200 Subject: pkgs/profpatsch: export toNetstring from the toplevel --- pkgs/profpatsch/default.nix | 5 ++++- pkgs/profpatsch/execline/symlink.nix | 7 +------ 2 files changed, 5 insertions(+), 7 deletions(-) (limited to 'pkgs/profpatsch') diff --git a/pkgs/profpatsch/default.nix b/pkgs/profpatsch/default.nix index f39831b2..a9bff57b 100644 --- a/pkgs/profpatsch/default.nix +++ b/pkgs/profpatsch/default.nix @@ -168,13 +168,16 @@ in rec { inherit (import ./execline/e.nix { inherit pkgs writeExecline getBins; }) e; + toNetstring = s: + "${toString (builtins.stringLength s)}:${s},"; + inherit getBins binify; inherit (import ./sandbox.nix {inherit pkgs writeExecline; }) sandbox runInEmptyEnv; symlink = pkgs.callPackage ./execline/symlink.nix { - inherit runExecline; + inherit runExecline toNetstring; }; importer = pkgs.callPackage ./execline/importer.nix { diff --git a/pkgs/profpatsch/execline/symlink.nix b/pkgs/profpatsch/execline/symlink.nix index c6a311d8..30c21ea4 100644 --- a/pkgs/profpatsch/execline/symlink.nix +++ b/pkgs/profpatsch/execline/symlink.nix @@ -1,4 +1,4 @@ -{ lib, s6-portable-utils, coreutils, runExecline }: +{ lib, s6-portable-utils, coreutils, runExecline, toNetstring }: # DrvPath :: path relative to the derivation # AbsPath :: absolute path in the store # Name @@ -6,11 +6,6 @@ # -> Drv name: links: -let - toNetstring = s: - "${toString (builtins.stringLength s)}:${s},"; - -in runExecline name { derivationArgs = { pathTuples = lib.concatMapStrings -- cgit 1.4.1