Skip to content

Can I use Nickel in a Nix expression? #1769

Answered by yannham
akavel asked this question in Q&A
Discussion options

You must be logged in to vote

I think your best bet might be the organist project, which we also develop at Tweag. It's mostly centered around writing development shells, so depending on what you try to do, it might not be the right solution, but it's probably the most advanced example of Nickel-Nix integration today. Organist have mechanisms to pass derivations between Nix and Nickel (of course, there are many restrictions, but using simple packages without overriding shouldn't be an issue), for example.

Even if organist, as it is, doesn't fit your use-case, you might be able to steal ideas and code from its internal library. Organist has a Nix library with functions such as importFromNcl which handle a bunch of task…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@akavel
Comment options

@yannham
Comment options

Answer selected by akavel
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants