Skip to content

djhshih/nix-interpreter-ts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Nix interpreter in Typescript

Nix is a functional domain-specific language that is useful for package management. This repository aims to implement a prototype interpreter for Nix using Typescript.

Requirement

deno 1.29
typescript 4.9

Pending

  • deep equality for set
  • deep equality for list
  • @ notation for parameter set
  • built-in functions
  • interpolation
  • assert
  • path

See full list of pending items using ripgrep by

rg TODO

Divergence

Nix: equality expression always returns false for functions.
Here: equality on functions is based on reference.

Nix: inherit keyword is used to inherit attributes: { inherit a b; c = 1; }
Here: { a; b; c = 1; }

Usage

Use interactively by

deno run repl.ts

Run tests by

deno run -A eval.ts

About

Nix interpreter in Typescript

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published