Skip to content

aMOPel/deno2nix

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 

Repository files navigation

deno2nix

This repo contains 2 implementations for a buildDenoPackage nix build helper.

Both implementations work.

There were multiple futile attempts to get this merged in nixpkgs.

  1. NixOS/nixpkgs#407434
  2. NixOS/nixpkgs#419255
  3. NixOS/nixpkgs#453904

Fetch with deno cli

The first attempt is the simpler implementation.

It uses the deno cli to fetch the dependencies and cleans up the non-reproducible files afterwards.

Since it uses the deno cli, it naturally has all the fetcher features of the deno cli.

WARNING: For newer deno versions, the fetchDenoDeps derivations can become non-reproducible, if deno upstream adds more non-reproducible data to the dependency directories (DENO_DIR, vendir-dir, node_modules)

See deno-cli-fetcher branch

This was merged and later reverted, since this is not good practice in nixpkgs, for complicated technical reasons, that only matter for the nixpkgs repo.

Custom made fetcher

As per request by the nixpkgs maintainers, the second and third attempts use a custom-made fetcher that aims to mimic the functionality of the deno cli fetcher.

The implementation is more complicated and has fewer features.

WARNING: For newer deno versions, the fetcher can break (i.e. not produce usable output anymore), if deno upstream makes breaking changes to:

  • deno.lock
  • their internal formats for DENO_DIR and vendor-dir

See custom-made-fetcher branch

This was never merged, since nobody could be bothered to review that amount of code.

About

buildDenoPackage build helper that is missing from nixpkgs

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors