mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-22 13:43:22 +00:00
230e267051
- Use `pixie` (the wrapper) rather than `pixie-vm` (the wrappee) - Add `rlwrap` command rather than using `which` Fixes #72129
47 lines
1.1 KiB
Nix
47 lines
1.1 KiB
Nix
{ lib, stdenv, fetchFromGitHub
|
|
, pixie, rlwrap
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "dust";
|
|
version = "0-91";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "pixie-lang";
|
|
repo = "dust";
|
|
rev = "efe469661e749a71e86858fd006f61464810575a";
|
|
sha256 = "09n57b6haxwask9m8vimv42ikczf7lgfc7m9izjrcqgs0padvfzc";
|
|
};
|
|
|
|
buildInputs = [ pixie ];
|
|
|
|
patches = [ ./make-paths-configurable.patch ];
|
|
|
|
configurePhase = ''
|
|
pixiePath="${pixie}/bin/pixie" \
|
|
basePath="$out/share/dust" \
|
|
rlwrapPath="${rlwrap}/bin/rlwrap" \
|
|
substituteAll dust.in dust
|
|
chmod +x dust
|
|
'';
|
|
|
|
# FIXME: AOT for dust
|
|
# buildPhase = ''
|
|
# find . -name "*.pxi" -exec pixie-vm -c {} \;
|
|
# '';
|
|
|
|
installPhase = ''
|
|
mkdir -p $out/bin $out/share/dust
|
|
cp -a src/ run.pxi $out/share/dust
|
|
mv dust $out/bin/dust
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "Provides tooling around pixie, e.g. a nicer repl, running tests and fetching dependencies";
|
|
homepage = src.meta.homepage;
|
|
maintainers = with maintainers; [ ];
|
|
license = licenses.lgpl3;
|
|
platforms = platforms.unix;
|
|
};
|
|
}
|