[Nix-dev] use builtins.readFile and strip trailing newline

Vladimír Čunát vcunat at gmail.com
Thu Jun 9 16:32:27 CEST 2016


On 06/09/2016 04:24 PM, 4levels wrote:
> 'd like to know if there's an easy way to strip off the trailing newline
> from a file read with builtins.readFile.

lib.removeSuffix "\n"

--Vladimir


-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 3771 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://lists.science.uu.nl/pipermail/nix-dev/attachments/20160609/c3fd8c02/attachment.p7s>


More information about the nix-dev mailing list